diff options
author | Razi Alavizadeh <s.r.alavizadeh@gmail.com> | 2018-06-14 13:37:09 +0430 |
---|---|---|
committer | Razi Alavizadeh <s.r.alavizadeh@gmail.com> | 2018-06-22 18:04:54 +0000 |
commit | f009d5f151c5ed2e306ffd1b179d500684073a87 (patch) | |
tree | 7088a75240ea1840a98ec4ac0832c37a40c47e81 /src/plugins/coreplugin/mainwindow.cpp | |
parent | ffc651d54ee619c8779a79c6f430efbf106ee61b (diff) | |
download | qt-creator-f009d5f151c5ed2e306ffd1b179d500684073a87.tar.gz |
CorePlugin: Switch split if remote command tries to open an already opened file
It seems more natural that remote commands
don't change current editor of active view if file
is already opened in another view.
Change-Id: Ie27de0d159cae6e63fa1d477fab59887a0e6d198
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Diffstat (limited to 'src/plugins/coreplugin/mainwindow.cpp')
-rw-r--r-- | src/plugins/coreplugin/mainwindow.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/plugins/coreplugin/mainwindow.cpp b/src/plugins/coreplugin/mainwindow.cpp index cd76507098..c8ad39bea0 100644 --- a/src/plugins/coreplugin/mainwindow.cpp +++ b/src/plugins/coreplugin/mainwindow.cpp @@ -845,6 +845,8 @@ IDocument *MainWindow::openFiles(const QStringList &fileNames, QFlags<EditorManager::OpenEditorFlag> emFlags; if (flags & ICore::CanContainLineAndColumnNumbers) emFlags |= EditorManager::CanContainLineAndColumnNumber; + if (flags & ICore::SwitchSplitIfAlreadyVisible) + emFlags |= EditorManager::SwitchSplitIfAlreadyVisible; IEditor *editor = EditorManager::openEditor(absoluteFilePath, Id(), emFlags); if (!editor) { if (flags & ICore::StopOnLoadFail) |