forked from qt-creator/qt-creator
Git: Fix Instant Blame for files with only one line
As we don't show blame annotations for the trailing (empty) lines, the following could happen for single line files: 1. Cursor is in the first line, annotation is shown 2. Cursor is moved to the last line, the annotation is cleared 3. Cursor is moved back to the first line, but now no annotation is shown Fix this by resetting the last visited line when the annotation is cleared in step 2. Change-Id: I1ea5dc339f57c94bc1835dcbccd7a9d93f79ffe5 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
committed by
André Hartmann
parent
d1ac2fe45a
commit
e944a26435
@@ -1577,6 +1577,7 @@ void GitPluginPrivate::instantBlame()
|
||||
|
||||
if (line >= lines) {
|
||||
m_blameMark.reset();
|
||||
m_lastVisitedEditorLine = -1;
|
||||
return;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user