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