forked from qt-creator/qt-creator
VcsBaseClient: Fix build on windows
Windows does pick ::log in favor of this->log in the lambda. Change-Id: Ib3037606dfe70de955b10e69e2bc513b99b82fca Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
This commit is contained in:
@@ -974,8 +974,8 @@ void GitClient::log(const QString &workingDirectory, const QString &fileName,
|
|||||||
VcsBaseEditorWidget *editor = findExistingVCSEditor("logFileName", sourceFile);
|
VcsBaseEditorWidget *editor = findExistingVCSEditor("logFileName", sourceFile);
|
||||||
if (!editor) {
|
if (!editor) {
|
||||||
auto *argWidget = new GitLogArgumentsWidget(settings());
|
auto *argWidget = new GitLogArgumentsWidget(settings());
|
||||||
QObject::connect(argWidget, &VcsBaseEditorParameterWidget::commandExecutionRequested,
|
connect(argWidget, &VcsBaseEditorParameterWidget::commandExecutionRequested,
|
||||||
[=] { log(workingDirectory, fileName, enableAnnotationContextMenu, args); });
|
[=]() { this->log(workingDirectory, fileName, enableAnnotationContextMenu, args); });
|
||||||
editor = createVcsEditor(editorId, title, sourceFile, CodecLogOutput, "logFileName", sourceFile,
|
editor = createVcsEditor(editorId, title, sourceFile, CodecLogOutput, "logFileName", sourceFile,
|
||||||
argWidget);
|
argWidget);
|
||||||
}
|
}
|
||||||
@@ -1100,11 +1100,11 @@ void GitClient::blame(const QString &workingDirectory,
|
|||||||
if (!editor) {
|
if (!editor) {
|
||||||
auto *argWidget = new GitBlameArgumentsWidget(settings());
|
auto *argWidget = new GitBlameArgumentsWidget(settings());
|
||||||
argWidget->setBaseArguments(args);
|
argWidget->setBaseArguments(args);
|
||||||
QObject::connect(argWidget, &VcsBaseEditorParameterWidget::commandExecutionRequested,
|
connect(argWidget, &VcsBaseEditorParameterWidget::commandExecutionRequested,
|
||||||
[=] {
|
[=] {
|
||||||
const int line = VcsBaseEditor::lineNumberOfCurrentEditor();
|
const int line = VcsBaseEditor::lineNumberOfCurrentEditor();
|
||||||
blame(workingDirectory, args, fileName, revision, line);
|
blame(workingDirectory, args, fileName, revision, line);
|
||||||
} );
|
} );
|
||||||
editor = createVcsEditor(editorId, title, sourceFile, CodecSource, "blameFileName", id, argWidget);
|
editor = createVcsEditor(editorId, title, sourceFile, CodecSource, "blameFileName", id, argWidget);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -101,8 +101,8 @@ VcsBaseClientPrivate::VcsBaseClientPrivate(VcsBaseClient *client, VcsBaseClientS
|
|||||||
void VcsBaseClientPrivate::bindCommandToEditor(VcsCommand *cmd, VcsBaseEditorWidget *editor)
|
void VcsBaseClientPrivate::bindCommandToEditor(VcsCommand *cmd, VcsBaseEditorWidget *editor)
|
||||||
{
|
{
|
||||||
editor->setCommand(cmd);
|
editor->setCommand(cmd);
|
||||||
QObject::connect(cmd, &VcsCommand::finished,
|
connect(cmd, &VcsCommand::finished,
|
||||||
m_cmdFinishedMapper, static_cast<void (QSignalMapper::*)()>(&QSignalMapper::map));
|
m_cmdFinishedMapper, static_cast<void (QSignalMapper::*)()>(&QSignalMapper::map));
|
||||||
m_cmdFinishedMapper->setMapping(cmd, editor);
|
m_cmdFinishedMapper->setMapping(cmd, editor);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -345,7 +345,7 @@ void VcsBaseClient::log(const QString &workingDir, const QStringList &files,
|
|||||||
if (!paramWidget && (paramWidget = d->createLogEditor())) {
|
if (!paramWidget && (paramWidget = d->createLogEditor())) {
|
||||||
// editor has been just created, createVcsEditor() didn't set a configuration widget yet
|
// editor has been just created, createVcsEditor() didn't set a configuration widget yet
|
||||||
connect(paramWidget, &VcsBaseEditorParameterWidget::commandExecutionRequested,
|
connect(paramWidget, &VcsBaseEditorParameterWidget::commandExecutionRequested,
|
||||||
[=] { log(workingDir, files, extraOptions, enableAnnotationContextMenu); } );
|
[=]() { this->log(workingDir, files, extraOptions, enableAnnotationContextMenu); } );
|
||||||
editor->setConfigurationWidget(paramWidget);
|
editor->setConfigurationWidget(paramWidget);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user