diff options
author | Oswald Buddenhagen <[email protected]> | 2011-05-06 12:48:44 +0200 |
---|---|---|
committer | Oswald Buddenhagen <[email protected]> | 2011-05-12 20:10:02 +0200 |
commit | 882e34ee284731f9edb3a89c23fb7a0897c8da3a (patch) | |
tree | eb7e4018f1acc36b03ae071e0c435eb56dd064f6 /src/plugins/cmakeprojectmanager/cmakeproject.cpp | |
parent | 46c09e77cd73cfb54ef328799a287bf37191fc01 (diff) |
rewrite editor info bar handling
the info about the bars is now stored in the IFile, not in the
EditorView. this is somewhat more expensive for the bars which
identically apply to all editors of one type, but fixes consistency
issues between views.
additionally, it is now possible to set several simultaneous
info bars per file, which ensures that no information is lost.
Co-authored-by: mae
Diffstat (limited to 'src/plugins/cmakeprojectmanager/cmakeproject.cpp')
-rw-r--r-- | src/plugins/cmakeprojectmanager/cmakeproject.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/plugins/cmakeprojectmanager/cmakeproject.cpp b/src/plugins/cmakeprojectmanager/cmakeproject.cpp index 332d538f043..d61b326049a 100644 --- a/src/plugins/cmakeprojectmanager/cmakeproject.cpp +++ b/src/plugins/cmakeprojectmanager/cmakeproject.cpp @@ -51,6 +51,7 @@ #include <extensionsystem/pluginmanager.h> #include <utils/qtcassert.h> #include <coreplugin/icore.h> +#include <coreplugin/infobar.h> #include <coreplugin/editormanager/editormanager.h> #include <QtCore/QMap> @@ -195,7 +196,9 @@ bool CMakeProject::parseCMakeLists() !activeTarget()->activeBuildConfiguration()) return false; - Core::EditorManager::instance()->hideEditorInfoBar("CMakeEditor.RunCMake"); + foreach (Core::IEditor *editor, Core::EditorManager::instance()->openedEditors()) + if (isProjectFile(editor->file()->fileName())) + editor->file()->infoBar()->removeInfo(QLatin1String("CMakeEditor.RunCMake")); // Find cbp file CMakeBuildConfiguration *activeBC = activeTarget()->activeBuildConfiguration(); |