Commit 642706dc authored by Orgad Shaneh's avatar Orgad Shaneh Committed by Orgad Shaneh
Browse files

VCS: Pass const values by references



Change-Id: I9749c0c76b810f3d5fee1aa8c5750dac5930cd3c
Reviewed-by: default avatarTobias Hunger <tobias.hunger@digia.com>
parent b3ff928b
......@@ -141,7 +141,7 @@ public:
return fn;
}
void insert(const QStringList path, BranchNode *n)
void insert(const QStringList &path, BranchNode *n)
{
BranchNode *current = this;
for (int i = 0; i < path.count(); ++i) {
......
......@@ -1096,9 +1096,9 @@ VcsBase::VcsBaseEditorWidget *GitClient::findExistingVCSEditor(const char *regis
return rc;
}
DiffEditor::DiffEditorDocument *GitClient::createDiffEditor(const QString documentId,
const QString &source,
const QString &title) const
DiffEditor::DiffEditorDocument *GitClient::createDiffEditor(const QString &documentId,
const QString &source,
const QString &title) const
{
DiffEditor::DiffEditorDocument *diffEditorDocument = DiffEditor::DiffEditorManager::findOrCreate(documentId, title);
QTC_ASSERT(diffEditorDocument, return 0);
......
......@@ -356,7 +356,7 @@ private:
const char *registerDynamicProperty,
const QString &dynamicPropertyValue,
VcsBase::VcsBaseEditorParameterWidget *configWidget) const;
DiffEditor::DiffEditorDocument *createDiffEditor(const QString documentId,
DiffEditor::DiffEditorDocument *createDiffEditor(const QString &documentId,
const QString &source,
const QString &title) const;
......
......@@ -1169,10 +1169,11 @@ PerforceResponse PerforcePlugin::runP4Cmd(const QString &workingDir,
return response;
}
Core::IEditor *PerforcePlugin::showOutputInEditor(const QString &title, const QString output,
int editorType,
const QString &source,
QTextCodec *codec)
Core::IEditor *PerforcePlugin::showOutputInEditor(const QString &title,
const QString &output,
int editorType,
const QString &source,
QTextCodec *codec)
{
const VcsBase::VcsBaseEditorParameters *params = findType(editorType);
QTC_ASSERT(params, return 0);
......
......@@ -146,7 +146,7 @@ protected:
private:
typedef QHash<QString, bool> ManagedDirectoryCache;
Core::IEditor *showOutputInEditor(const QString& title, const QString output,
Core::IEditor *showOutputInEditor(const QString &title, const QString &output,
int editorType, const QString &source,
QTextCodec *codec = 0);
......
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