| 85 | } |
| 86 | |
| 87 | bool |
| 88 | Monitor::MonitorData::removeRepo( const QString& ior) |
| 89 | { |
| 90 | if( !this->enabled_) { |
| 91 | return false; |
| 92 | } |
| 93 | |
| 94 | // Replace call to toStdString() with toLocal8Bit().constData() |
| 95 | // to avoid QString-related aborts under windows. |
| 96 | QByteArray ior_arr = ior.toLocal8Bit(); |
| 97 | const char* ior_str = ior_arr.constData(); |
| 98 | |
| 99 | // Check if this is the currently monitored repository, and clear its |
| 100 | // data if it is in the view. |
| 101 | if( this->storage_->activeIor() == ior_str) { |
| 102 | this->clearData(); |
| 103 | } |
| 104 | |
| 105 | // Look up the index for this IOR and remove it from the service. |
| 106 | return true; |
| 107 | } |
| 108 | |
| 109 | bool |
| 110 | Monitor::MonitorData::clearData() |