diff options
Diffstat (limited to 'src/plugins/git/gitsubmiteditorwidget.cpp')
-rw-r--r-- | src/plugins/git/gitsubmiteditorwidget.cpp | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/src/plugins/git/gitsubmiteditorwidget.cpp b/src/plugins/git/gitsubmiteditorwidget.cpp index 351dd6ee1e..582dea38c7 100644 --- a/src/plugins/git/gitsubmiteditorwidget.cpp +++ b/src/plugins/git/gitsubmiteditorwidget.cpp @@ -58,10 +58,10 @@ GitSubmitEditorWidget::GitSubmitEditorWidget() : m_emailValidator = new QRegExpValidator(QRegExp(QLatin1String("[^@ ]+@[^@ ]+\\.[a-zA-Z]+")), this); - connect(m_gitSubmitPanelUi.authorLineEdit, SIGNAL(textChanged(QString)), - this, SLOT(authorInformationChanged())); - connect(m_gitSubmitPanelUi.emailLineEdit, SIGNAL(textChanged(QString)), - this, SLOT(authorInformationChanged())); + connect(m_gitSubmitPanelUi.authorLineEdit, &QLineEdit::textChanged, + this, &GitSubmitEditorWidget::authorInformationChanged); + connect(m_gitSubmitPanelUi.emailLineEdit, &QLineEdit::textChanged, + this, &GitSubmitEditorWidget::authorInformationChanged); } void GitSubmitEditorWidget::setPanelInfo(const GitSubmitEditorPanelInfo &info) @@ -94,12 +94,13 @@ void GitSubmitEditorWidget::initialize(CommitType commitType, return; m_isInitialized = true; if (commitType == FixupCommit) { - QGroupBox *logChangeGroupBox = new QGroupBox(tr("Select Change")); - QVBoxLayout *logChangeLayout = new QVBoxLayout; + auto logChangeGroupBox = new QGroupBox(tr("Select Change")); + auto logChangeLayout = new QVBoxLayout; logChangeGroupBox->setLayout(logChangeLayout); m_logChangeWidget = new LogChangeWidget; m_logChangeWidget->init(repository); - connect(m_logChangeWidget, SIGNAL(activated(QString)), this, SIGNAL(show(QString))); + connect(m_logChangeWidget, &LogChangeWidget::activated, + this, &GitSubmitEditorWidget::show); logChangeLayout->addWidget(m_logChangeWidget); insertTopWidget(logChangeGroupBox); m_gitSubmitPanelUi.editGroup->hide(); @@ -110,7 +111,7 @@ void GitSubmitEditorWidget::initialize(CommitType commitType, setPanelInfo(info); if (enablePush) { - QMenu *menu = new QMenu(this); + auto menu = new QMenu(this); menu->addAction(tr("&Commit only"), this, SLOT(commitOnlySlot())); menu->addAction(tr("Commit and &Push"), this, SLOT(commitAndPushSlot())); menu->addAction(tr("Commit and Push to &Gerrit"), this, SLOT(commitAndPushToGerritSlot())); |