diff options
author | Orgad Shaneh <orgad.shaneh@audiocodes.com> | 2013-08-11 22:35:49 +0300 |
---|---|---|
committer | Orgad Shaneh <orgads@gmail.com> | 2013-08-12 12:42:11 +0200 |
commit | b0d14c79fe5a08f4a2ba8af7c9dee3007b2a3d39 (patch) | |
tree | b722749e4bc1307ec05a68b1198058a169a5268d | |
parent | e2aa5b53cf3afb8abddc1d7a5a99971349f18a2d (diff) | |
download | qt-creator-b0d14c79fe5a08f4a2ba8af7c9dee3007b2a3d39.tar.gz |
VCS: Use correct output style
Change-Id: I95ea8078ae53e7339213765fbb8a79bff33f899c
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
-rw-r--r-- | src/plugins/bazaar/bazaarplugin.cpp | 2 | ||||
-rw-r--r-- | src/plugins/clearcase/clearcaseplugin.cpp | 2 | ||||
-rw-r--r-- | src/plugins/cvs/cvsplugin.cpp | 2 | ||||
-rw-r--r-- | src/plugins/git/gitclient.cpp | 32 | ||||
-rw-r--r-- | src/plugins/git/gitplugin.cpp | 6 | ||||
-rw-r--r-- | src/plugins/git/gitsubmiteditor.cpp | 2 | ||||
-rw-r--r-- | src/plugins/git/mergetool.cpp | 3 | ||||
-rw-r--r-- | src/plugins/mercurial/mercurialplugin.cpp | 2 | ||||
-rw-r--r-- | src/plugins/perforce/perforceplugin.cpp | 2 | ||||
-rw-r--r-- | src/plugins/vcsbase/vcsbaseclient.cpp | 2 | ||||
-rw-r--r-- | src/plugins/vcsbase/vcsbaseplugin.cpp | 2 |
11 files changed, 29 insertions, 28 deletions
diff --git a/src/plugins/bazaar/bazaarplugin.cpp b/src/plugins/bazaar/bazaarplugin.cpp index b5c0dda3ad..137764f9f4 100644 --- a/src/plugins/bazaar/bazaarplugin.cpp +++ b/src/plugins/bazaar/bazaarplugin.cpp @@ -536,7 +536,7 @@ void BazaarPlugin::showCommitWidget(const QList<VcsBase::VcsBaseClient::StatusIt // Keep the file alive, else it removes self and forgets its name saver.setAutoRemove(false); if (!saver.finalize()) { - VcsBase::VcsBaseOutputWindow::instance()->append(saver.errorString()); + VcsBase::VcsBaseOutputWindow::instance()->appendError(saver.errorString()); return; } diff --git a/src/plugins/clearcase/clearcaseplugin.cpp b/src/plugins/clearcase/clearcaseplugin.cpp index baf323a54b..571d94fe00 100644 --- a/src/plugins/clearcase/clearcaseplugin.cpp +++ b/src/plugins/clearcase/clearcaseplugin.cpp @@ -1513,7 +1513,7 @@ bool ClearCasePlugin::vcsOpen(const QString &workingDir, const QString &fileName } else { VcsBase::VcsBaseOutputWindow *outputWindow = VcsBase::VcsBaseOutputWindow::instance(); outputWindow->append(response.stdOut); - outputWindow->append(response.stdErr); + outputWindow->appendError(response.stdErr); } } diff --git a/src/plugins/cvs/cvsplugin.cpp b/src/plugins/cvs/cvsplugin.cpp index fbaeb0fdd0..06a54fa683 100644 --- a/src/plugins/cvs/cvsplugin.cpp +++ b/src/plugins/cvs/cvsplugin.cpp @@ -781,7 +781,7 @@ void CvsPlugin::startCommit(const QString &workingDir, const QString &file) } } if (statusOutput.empty()) { - VcsBaseOutputWindow::instance()->append(tr("There are no modified files.")); + VcsBaseOutputWindow::instance()->appendWarning(tr("There are no modified files.")); return; } m_commitRepository = workingDir; diff --git a/src/plugins/git/gitclient.cpp b/src/plugins/git/gitclient.cpp index e5c3202d85..84f3b8c0c6 100644 --- a/src/plugins/git/gitclient.cpp +++ b/src/plugins/git/gitclient.cpp @@ -1170,7 +1170,7 @@ void GitClient::show(const QString &source, const QString &id, const QStringList &args, const QString &name) { if (!canShow(id)) { - outputWindow()->append(msgCannotShow(id)); + outputWindow()->appendError(msgCannotShow(id)); return; } @@ -1550,9 +1550,9 @@ bool GitClient::synchronousRevListCmd(const QString &workingDirectory, const QSt if (errorMessage) *errorMessage = commandOutputFromLocal8Bit(errorText); else - outputWindow()->append(tr("Cannot execute \"git %1\" in \"%2\": %3").arg( - args.join(QLatin1String(" ")), workingDirectory, - commandOutputFromLocal8Bit(errorText))); + outputWindow()->appendError(tr("Cannot execute \"git %1\" in \"%2\": %3").arg( + args.join(QLatin1String(" ")), workingDirectory, + commandOutputFromLocal8Bit(errorText))); return false; } *output = commandOutputFromLocal8Bit(outputTextData); @@ -1656,7 +1656,7 @@ bool GitClient::synchronousHeadRefs(const QString &workingDirectory, QStringList if (errorMessage) *errorMessage = message; else - outputWindow()->append(message); + outputWindow()->appendError(message); return false; } @@ -1885,10 +1885,10 @@ QString GitClient::synchronousStash(const QString &workingDirectory, const QStri if (unchanged) *unchanged = true; if (!(flags & StashIgnoreUnchanged)) - outputWindow()->append(msgNoChangedFiles()); + outputWindow()->appendWarning(msgNoChangedFiles()); break; case StatusFailed: - outputWindow()->append(errorMessage); + outputWindow()->appendError(errorMessage); break; } if (!success) @@ -1946,7 +1946,7 @@ bool GitClient::stashNameFromMessage(const QString &workingDirectory, if (errorMessage) *errorMessage = msg; else - outputWindow()->append(msg); + outputWindow()->appendError(msg); return false; } @@ -2027,7 +2027,7 @@ QMap<QString,QString> GitClient::synchronousRemotesList(const QString &workingDi if (errorMessage) *errorMessage = error; else - outputWindow()->append(error); + outputWindow()->appendError(error); return result; } QStringList remotes = output.split(QLatin1String("\n")); @@ -2062,7 +2062,7 @@ QStringList GitClient::synchronousSubmoduleStatus(const QString &workingDirector if (errorMessage) *errorMessage = error; else - outputWindow()->append(error); + outputWindow()->appendError(error); return QStringList(); } @@ -2985,11 +2985,11 @@ void GitClient::revert(const QStringList &files, bool revertStaging) break; case RevertUnchanged: { const QString msg = (isDirectory || files.size() > 1) ? msgNoChangedFiles() : tr("The file is not modified."); - outputWindow()->append(msg); + outputWindow()->appendWarning(msg); } break; case RevertFailed: - outputWindow()->append(errorMessage); + outputWindow()->appendError(errorMessage); break; } } @@ -3308,7 +3308,7 @@ bool GitClient::synchronousStashRestore(const QString &workingDirectory, if (errorMessage) *errorMessage = msg; else - outputWindow()->append(msg); + outputWindow()->appendError(msg); return false; } QString output = commandOutputFromLocal8Bit(outputText); @@ -3340,7 +3340,7 @@ bool GitClient::synchronousStashRemove(const QString &workingDirectory, if (errorMessage) *errorMessage = msg; else - outputWindow()->append(msg); + outputWindow()->appendError(msg); return false; } QString output = commandOutputFromLocal8Bit(outputText); @@ -3380,7 +3380,7 @@ bool GitClient::synchronousStashList(const QString &workingDirectory, if (errorMessage) *errorMessage = msg; else - outputWindow()->append(msg); + outputWindow()->appendError(msg); return false; } Stash stash; @@ -3510,7 +3510,7 @@ unsigned GitClient::synchronousGitVersion(QString *errorMessage) const if (errorMessage) *errorMessage = msg; else - outputWindow()->append(msg); + outputWindow()->appendError(msg); return 0; } // cut 'git version 1.6.5.1.sha' diff --git a/src/plugins/git/gitplugin.cpp b/src/plugins/git/gitplugin.cpp index 2df9f0b087..32b8c66f09 100644 --- a/src/plugins/git/gitplugin.cpp +++ b/src/plugins/git/gitplugin.cpp @@ -969,7 +969,7 @@ void GitPlugin::startCommit(CommitType commitType) QString errorMessage, commitTemplate; CommitData data(commitType); if (!m_gitClient->getCommitData(state.topLevel(), &commitTemplate, data, &errorMessage)) { - VcsBase::VcsBaseOutputWindow::instance()->append(errorMessage); + VcsBase::VcsBaseOutputWindow::instance()->appendError(errorMessage); return; } @@ -983,7 +983,7 @@ void GitPlugin::startCommit(CommitType commitType) saver.setAutoRemove(false); saver.write(commitTemplate.toLocal8Bit()); if (!saver.finalize()) { - VcsBase::VcsBaseOutputWindow::instance()->append(saver.errorString()); + VcsBase::VcsBaseOutputWindow::instance()->appendError(saver.errorString()); return; } m_commitMessageFileName = saver.fileName(); @@ -1300,7 +1300,7 @@ void GitPlugin::applyPatch(const QString &workingDirectory, QString file) if (errorMessage.isEmpty()) outwin->append(tr("Patch %1 successfully applied to %2").arg(file, workingDirectory)); else - outwin->append(errorMessage); + outwin->appendError(errorMessage); } else { outwin->appendError(errorMessage); } diff --git a/src/plugins/git/gitsubmiteditor.cpp b/src/plugins/git/gitsubmiteditor.cpp index 5eb0d5f9f0..44c95d5d05 100644 --- a/src/plugins/git/gitsubmiteditor.cpp +++ b/src/plugins/git/gitsubmiteditor.cpp @@ -179,7 +179,7 @@ void GitSubmitEditor::updateFileModel() setCommitData(data); submitEditorWidget()->refreshLog(m_workingDirectory); } else { - VcsBase::VcsBaseOutputWindow::instance()->append(errorMessage); + VcsBase::VcsBaseOutputWindow::instance()->appendError(errorMessage); m_forceClose = true; Core::EditorManager::instance()->closeEditor(this); } diff --git a/src/plugins/git/mergetool.cpp b/src/plugins/git/mergetool.cpp index 05704c5413..bb30245bae 100644 --- a/src/plugins/git/mergetool.cpp +++ b/src/plugins/git/mergetool.cpp @@ -265,7 +265,8 @@ void MergeTool::done() outputWindow->append(tr("Merge tool process finished successully.")); m_gitClient->continueCommandIfNeeded(workingDirectory); } else { - outputWindow->append(tr("Merge tool process terminated with exit code %1").arg(exitCode)); + outputWindow->appendError(tr("Merge tool process terminated with exit code %1") + .arg(exitCode)); } GitPlugin::instance()->gitVersionControl()->emitRepositoryChanged(workingDirectory); deleteLater(); diff --git a/src/plugins/mercurial/mercurialplugin.cpp b/src/plugins/mercurial/mercurialplugin.cpp index 1f572518d7..e9abc55f2f 100644 --- a/src/plugins/mercurial/mercurialplugin.cpp +++ b/src/plugins/mercurial/mercurialplugin.cpp @@ -557,7 +557,7 @@ void MercurialPlugin::showCommitWidget(const QList<VcsBaseClient::StatusItem> &s // Keep the file alive, else it removes self and forgets its name saver.setAutoRemove(false); if (!saver.finalize()) { - VcsBase::VcsBaseOutputWindow::instance()->append(saver.errorString()); + VcsBase::VcsBaseOutputWindow::instance()->appendError(saver.errorString()); return; } diff --git a/src/plugins/perforce/perforceplugin.cpp b/src/plugins/perforce/perforceplugin.cpp index 14d76ff23b..95adbfbdbf 100644 --- a/src/plugins/perforce/perforceplugin.cpp +++ b/src/plugins/perforce/perforceplugin.cpp @@ -1095,7 +1095,7 @@ PerforceResponse PerforcePlugin::fullySynchronousProcess(const QString &workingD // Logging VcsBase::VcsBaseOutputWindow *outputWindow = VcsBase::VcsBaseOutputWindow::instance(); if ((flags & StdErrToWindow) && !response.stdErr.isEmpty()) - outputWindow->append(response.stdErr); + outputWindow->appendError(response.stdErr); if ((flags & StdOutToWindow) && !response.stdOut.isEmpty()) outputWindow->append(response.stdOut); return response; diff --git a/src/plugins/vcsbase/vcsbaseclient.cpp b/src/plugins/vcsbase/vcsbaseclient.cpp index 9900221303..ffa4b42bbc 100644 --- a/src/plugins/vcsbase/vcsbaseclient.cpp +++ b/src/plugins/vcsbase/vcsbaseclient.cpp @@ -305,7 +305,7 @@ bool VcsBaseClient::vcsFullySynchronousExec(const QString &workingDir, return false; } if (!stdErr.isEmpty()) - ::vcsOutputWindow()->append(QString::fromLocal8Bit(stdErr)); + ::vcsOutputWindow()->appendError(QString::fromLocal8Bit(stdErr)); return vcsProcess.exitStatus() == QProcess::NormalExit && vcsProcess.exitCode() == 0; } diff --git a/src/plugins/vcsbase/vcsbaseplugin.cpp b/src/plugins/vcsbase/vcsbaseplugin.cpp index ea3096de5b..653c4e8726 100644 --- a/src/plugins/vcsbase/vcsbaseplugin.cpp +++ b/src/plugins/vcsbase/vcsbaseplugin.cpp @@ -1098,7 +1098,7 @@ bool VcsBasePlugin::runPatch(const QByteArray &input, const QString &workingDire if (!stdOut.isEmpty()) ow->append(QString::fromLocal8Bit(stdOut)); if (!stdErr.isEmpty()) - ow->append(QString::fromLocal8Bit(stdErr)); + ow->appendError(QString::fromLocal8Bit(stdErr)); if (patchProcess.exitStatus() != QProcess::NormalExit) { ow->appendError(tr("'%1' crashed.").arg(patch)); |