VcsCommand: Change the default logic for fully sync

Remove VcsCommand::FullySynchronous flag.
Rename VcsCommand::NoFullySync into UseEventLoop.
By default the command will run fully synchronous
(i.e. without nested event loop). Only when
UseEventLoop is specified, and the command runs in
main thread, the nested event loop will be used.

This change should preserve the current behavior
on all code paths.

Change-Id: Id4bbaf68402ceed5e3fcc6f294521e87eb0b8d4d
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
Jarek Kobus
2022-10-05 11:14:41 +02:00
parent 3e69ea863f
commit f4233a1c22
5 changed files with 37 additions and 38 deletions

View File

@@ -2967,7 +2967,7 @@ bool GitClient::addAndCommit(const FilePath &repositoryDirectory,
}
const CommandResult result = vcsSynchronousExec(repositoryDirectory, arguments,
VcsCommand::NoFullySync);
VcsCommand::UseEventLoop);
if (result.result() == ProcessResult::FinishedWithSuccess) {
VcsOutputWindow::appendMessage(msgCommitted(amendSHA1, commitCount));
GitPlugin::updateCurrentBranch();