diff --git a/src/plugins/coreplugin/filemanager.cpp b/src/plugins/coreplugin/filemanager.cpp index 3831d1a0791..e8114c709c7 100644 --- a/src/plugins/coreplugin/filemanager.cpp +++ b/src/plugins/coreplugin/filemanager.cpp @@ -866,6 +866,10 @@ void FileManager::checkForReload() changedIFiles.insert(file); } + // clean up. do this before we may enter the main loop, otherwise we would + // lose consecutive notifications. + d->m_changedFiles.clear(); + // collect information about "expected" file names // we can't do the "resolving" already in expectFileChange, because // if the resolved names are different when unexpectFileChange is called @@ -1006,9 +1010,6 @@ void FileManager::checkForReload() d->m_blockedIFile = 0; } - // clean up - d->m_changedFiles.clear(); - // handle deleted files EditorManager::instance()->closeEditors(editorsToClose, false); QMapIterator it(filesToSave);