forked from qt-creator/qt-creator
Git: InstantBlame: Simplify lambda when settings changed
setupBlameForEditor() already contains the needed code to stop instant blame when it was disabled. Change-Id: Iffe7dd08707f89c0f2e67890991d394bd0fe82f7 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
committed by
André Hartmann
parent
2ee382046e
commit
d0cf207a0c
@@ -186,11 +186,8 @@ void InstantBlame::setup()
|
|||||||
force();
|
force();
|
||||||
};
|
};
|
||||||
|
|
||||||
connect(&settings().instantBlame, &BaseAspect::changed, this, [this, setupBlameForEditor] {
|
connect(&settings().instantBlame, &BaseAspect::changed, this, [setupBlameForEditor] {
|
||||||
if (settings().instantBlame())
|
setupBlameForEditor(EditorManager::currentEditor());
|
||||||
setupBlameForEditor(EditorManager::currentEditor());
|
|
||||||
else
|
|
||||||
stop();
|
|
||||||
});
|
});
|
||||||
|
|
||||||
connect(EditorManager::instance(), &EditorManager::currentEditorChanged,
|
connect(EditorManager::instance(), &EditorManager::currentEditorChanged,
|
||||||
|
Reference in New Issue
Block a user