forked from qt-creator/qt-creator
Cut off the forward navigation history to avoid messing it up.
There are cases like when editing, or when jumping to a line, where we shouldn't cut it though (so we don't). Task-number: QTCREATORBUG-1535
This commit is contained in:
@@ -1791,6 +1791,7 @@ bool CPPEditor::openCppEditorAt(const Link &link)
|
||||
|
||||
if (baseTextDocument()->fileName() == link.fileName) {
|
||||
Core::EditorManager *editorManager = Core::EditorManager::instance();
|
||||
editorManager->cutForwardNavigationHistory();
|
||||
editorManager->addCurrentPositionToNavigationHistory();
|
||||
gotoLine(link.line, link.column);
|
||||
setFocus();
|
||||
|
||||
Reference in New Issue
Block a user