Git - added ability to launch git gui

Change-Id: I65ed3e0408e43e354a289bbbd385aec2e254746c
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
Petar Perisin
2013-07-04 01:03:53 +02:00
parent 24d1e54490
commit 6312cc18e2
4 changed files with 28 additions and 0 deletions

View File

@@ -2576,6 +2576,19 @@ bool GitClient::tryLauchingGitK(const QProcessEnvironment &env,
return success;
}
bool GitClient::launchGitGui(const QString &workingDirectory) {
bool success;
QString gitBinary = gitBinaryPath(&success);
if (success)
success = QProcess::startDetached(gitBinary, QStringList(QLatin1String("gui")),
workingDirectory);
if (!success)
outputWindow()->appendError(tr("Cannot launch git gui"));
return success;
}
QString GitClient::gitBinaryPath(bool *ok, QString *errorMessage) const
{
return settings()->gitBinaryPath(ok, errorMessage);