Commit 53cbc9d3 authored by Orgad Shaneh's avatar Orgad Shaneh Committed by Orgad Shaneh

Git: Save silently on undo actions

If the user wants to undo, first save the file silently. Then the user is
still able to cancel the undo operation.

Task-number: QTCREATORBUG-16647
Change-Id: I61ac42ff41f3f7758d662692bc92850766beab8e
Reviewed-by: default avatarAndré Hartmann <aha_1980@gmx.de>
Reviewed-by: Tobias Hunger's avatarTobias Hunger <tobias.hunger@qt.io>
parent 516161c8
......@@ -718,7 +718,7 @@ void GitPlugin::logRepository()
void GitPlugin::undoFileChanges(bool revertStaging)
{
if (IDocument *document = EditorManager::currentDocument()) {
if (!DocumentManager::saveModifiedDocument(document))
if (!DocumentManager::saveModifiedDocumentSilently(document))
return;
}
const VcsBasePluginState state = currentState();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment