diff options
author | dt <qtc-committer@nokia.com> | 2010-09-03 11:57:46 +0200 |
---|---|---|
committer | dt <qtc-committer@nokia.com> | 2010-09-06 13:56:53 +0200 |
commit | bde1ebaaea85e460f0cba7240af06e714b387acb (patch) | |
tree | a4fde6f8253462ad7facba22147a16677387df83 /src/plugins/cpptools/cpptoolsplugin.cpp | |
parent | 0e2a7608f2da6e32fdfe3e12ea1af164bb28807e (diff) | |
download | qt-creator-bde1ebaaea85e460f0cba7240af06e714b387acb.tar.gz |
Remove EditorManager::ensureEditorManagerVisible()
The function always switched to Edit Mode, which was the cause for
several bugs. Since openEditor() already does switch to the right mode,
the function is not really needed.
The following actions now respect the prefered mode of the editor:
"f file"-locator
The Open Documents list
Editor history navigation
Diffstat (limited to 'src/plugins/cpptools/cpptoolsplugin.cpp')
-rw-r--r-- | src/plugins/cpptools/cpptoolsplugin.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/plugins/cpptools/cpptoolsplugin.cpp b/src/plugins/cpptools/cpptoolsplugin.cpp index 1595fd231c..90d234560b 100644 --- a/src/plugins/cpptools/cpptoolsplugin.cpp +++ b/src/plugins/cpptools/cpptoolsplugin.cpp @@ -170,10 +170,8 @@ void CppToolsPlugin::switchHeaderSource() Core::EditorManager *editorManager = Core::EditorManager::instance(); Core::IEditor *editor = editorManager->currentEditor(); QString otherFile = correspondingHeaderOrSource(editor->file()->fileName()); - if (!otherFile.isEmpty()) { + if (!otherFile.isEmpty()) editorManager->openEditor(otherFile); - editorManager->ensureEditorManagerVisible(); - } } QFileInfo CppToolsPlugin::findFile(const QDir &dir, const QString &name, |