Changeset View
Changeset View
Standalone View
Standalone View
plugins/patchreview/patchreview.cpp
Show First 20 Lines • Show All 211 Lines • ▼ Show 20 Line(s) | 210 | if (m_patch) { | |||
---|---|---|---|---|---|
212 | m_updateKompareTimer->start( 500 ); | 212 | m_updateKompareTimer->start( 500 ); | ||
213 | } else { | 213 | } else { | ||
214 | m_updateKompareTimer->stop(); | 214 | m_updateKompareTimer->stop(); | ||
215 | } | 215 | } | ||
216 | } | 216 | } | ||
217 | 217 | | |||
218 | void PatchReviewPlugin::forceUpdate() { | 218 | void PatchReviewPlugin::forceUpdate() { | ||
219 | if( m_patch ) { | 219 | if( m_patch ) { | ||
220 | // don't trigger an update if we know the plugin cannot update itself | ||||
221 | VCSDiffPatchSource *vcsPatch = dynamic_cast<VCSDiffPatchSource*>(m_patch.data()); | ||||
222 | if (!vcsPatch || vcsPatch->m_updater) { | ||||
220 | m_patch->update(); | 223 | m_patch->update(); | ||
221 | | ||||
222 | notifyPatchChanged(); | 224 | notifyPatchChanged(); | ||
223 | } | 225 | } | ||
224 | } | 226 | } | ||
227 | } | ||||
225 | 228 | | |||
226 | void PatchReviewPlugin::updateKompareModel() { | 229 | void PatchReviewPlugin::updateKompareModel() { | ||
227 | if ( !m_patch ) { | 230 | if ( !m_patch ) { | ||
228 | ///TODO: this method should be cleaned up, it can be called by the timer and | 231 | ///TODO: this method should be cleaned up, it can be called by the timer and | ||
229 | /// e.g. https://bugs.kde.org/show_bug.cgi?id=267187 shows how it could | 232 | /// e.g. https://bugs.kde.org/show_bug.cgi?id=267187 shows how it could | ||
230 | /// lead to asserts before... | 233 | /// lead to asserts before... | ||
231 | return; | 234 | return; | ||
232 | } | 235 | } | ||
▲ Show 20 Lines • Show All 395 Lines • Show Last 20 Lines |