diff options
Diffstat (limited to 'src/plugins')
-rw-r--r-- | src/plugins/coreplugin/find/searchresultwidget.cpp | 2 | ||||
-rw-r--r-- | src/plugins/coreplugin/infobar.cpp | 4 | ||||
-rw-r--r-- | src/plugins/coreplugin/infobar.h | 8 | ||||
-rw-r--r-- | src/plugins/coreplugin/vcsmanager.cpp | 2 | ||||
-rw-r--r-- | src/plugins/cppeditor/cppeditordocument.cpp | 2 | ||||
-rw-r--r-- | src/plugins/git/gitplugin.cpp | 2 | ||||
-rw-r--r-- | src/plugins/projectexplorer/projecttree.cpp | 2 | ||||
-rw-r--r-- | src/plugins/texteditor/texteditor.cpp | 2 | ||||
-rw-r--r-- | src/plugins/welcome/introductionwidget.cpp | 2 |
9 files changed, 13 insertions, 13 deletions
diff --git a/src/plugins/coreplugin/find/searchresultwidget.cpp b/src/plugins/coreplugin/find/searchresultwidget.cpp index bbc9f24d2b..23b894ef9a 100644 --- a/src/plugins/coreplugin/find/searchresultwidget.cpp +++ b/src/plugins/coreplugin/find/searchresultwidget.cpp @@ -257,7 +257,7 @@ void SearchResultWidget::addResults(const QList<SearchResultItem> &items, Search Id undoWarningId = Id("warninglabel/").withSuffix(m_dontAskAgainGroup); if (m_infoBar.canInfoBeAdded(undoWarningId)) { InfoBarEntry info(undoWarningId, tr("This change cannot be undone."), - InfoBarEntry::GlobalSuppressionEnabled); + InfoBarEntry::GlobalSuppression::Enabled); m_infoBar.addInfo(info); } } diff --git a/src/plugins/coreplugin/infobar.cpp b/src/plugins/coreplugin/infobar.cpp index 2113e0b78e..93f051e158 100644 --- a/src/plugins/coreplugin/infobar.cpp +++ b/src/plugins/coreplugin/infobar.cpp @@ -47,7 +47,7 @@ QSet<Id> InfoBar::globallySuppressed; QSettings *InfoBar::m_settings = nullptr; Utils::Theme *InfoBar::m_theme = nullptr; -InfoBarEntry::InfoBarEntry(Id _id, const QString &_infoText, GlobalSuppressionMode _globalSuppression) +InfoBarEntry::InfoBarEntry(Id _id, const QString &_infoText, GlobalSuppression _globalSuppression) : m_id(_id) , m_infoText(_infoText) , m_globalSuppression(_globalSuppression) @@ -307,7 +307,7 @@ void InfoBarDisplay::update() const Id id = info.m_id; QToolButton *infoWidgetSuppressButton = nullptr; - if (info.m_globalSuppression == InfoBarEntry::GlobalSuppressionEnabled) { + if (info.m_globalSuppression == InfoBarEntry::GlobalSuppression::Enabled) { infoWidgetSuppressButton = new QToolButton; infoWidgetSuppressButton->setText(tr("Do Not Show Again")); connect(infoWidgetSuppressButton, &QAbstractButton::clicked, this, [this, id] { diff --git a/src/plugins/coreplugin/infobar.h b/src/plugins/coreplugin/infobar.h index fd8f476c1d..a6cb0ee590 100644 --- a/src/plugins/coreplugin/infobar.h +++ b/src/plugins/coreplugin/infobar.h @@ -49,13 +49,13 @@ class InfoBarDisplay; class CORE_EXPORT InfoBarEntry { public: - enum GlobalSuppressionMode + enum class GlobalSuppression { - GlobalSuppressionDisabled, - GlobalSuppressionEnabled + Disabled, + Enabled }; - InfoBarEntry(Id _id, const QString &_infoText, GlobalSuppressionMode _globalSuppression = GlobalSuppressionDisabled); + InfoBarEntry(Id _id, const QString &_infoText, GlobalSuppression _globalSuppression = GlobalSuppression::Disabled); using CallBack = std::function<void()>; void setCustomButtonInfo(const QString &_buttonText, CallBack callBack); diff --git a/src/plugins/coreplugin/vcsmanager.cpp b/src/plugins/coreplugin/vcsmanager.cpp index fc9388aa1e..0de226c5cf 100644 --- a/src/plugins/coreplugin/vcsmanager.cpp +++ b/src/plugins/coreplugin/vcsmanager.cpp @@ -301,7 +301,7 @@ IVersionControl* VcsManager::findVersionControlForDirectory(const QString &input InfoBarEntry info(vcsWarning, tr("%1 repository was detected but %1 is not configured.") .arg(versionControl->displayName()), - InfoBarEntry::GlobalSuppressionEnabled); + InfoBarEntry::GlobalSuppression::Enabled); d->m_unconfiguredVcs = versionControl; info.setCustomButtonInfo(ICore::msgShowOptionsDialog(), []() { QTC_ASSERT(d->m_unconfiguredVcs, return); diff --git a/src/plugins/cppeditor/cppeditordocument.cpp b/src/plugins/cppeditor/cppeditordocument.cpp index e2d85d0f41..5d85bd638c 100644 --- a/src/plugins/cppeditor/cppeditordocument.cpp +++ b/src/plugins/cppeditor/cppeditordocument.cpp @@ -357,7 +357,7 @@ void CppEditorDocument::showHideInfoBarAboutMultipleParseContexts(bool show) Core::InfoBarEntry info(id, tr("Note: Multiple parse contexts are available for this file. " "Choose the preferred one from the editor toolbar."), - Core::InfoBarEntry::GlobalSuppressionEnabled); + Core::InfoBarEntry::GlobalSuppression::Enabled); info.removeCancelButton(); if (infoBar()->canInfoBeAdded(id)) infoBar()->addInfo(info); diff --git a/src/plugins/git/gitplugin.cpp b/src/plugins/git/gitplugin.cpp index db3154e499..4c0a0e9998 100644 --- a/src/plugins/git/gitplugin.cpp +++ b/src/plugins/git/gitplugin.cpp @@ -988,7 +988,7 @@ void GitPlugin::updateVersionWarning() infoBar->addInfo(InfoBarEntry(gitVersionWarning, tr("Unsupported version of Git found. Git %1 or later required.") .arg(versionString(minimumRequiredVersion)), - InfoBarEntry::GlobalSuppressionEnabled)); + InfoBarEntry::GlobalSuppression::Enabled)); } IEditor *GitPlugin::openSubmitEditor(const QString &fileName, const CommitData &cd) diff --git a/src/plugins/projectexplorer/projecttree.cpp b/src/plugins/projectexplorer/projecttree.cpp index 5259a0d609..5010b18b87 100644 --- a/src/plugins/projectexplorer/projecttree.cpp +++ b/src/plugins/projectexplorer/projecttree.cpp @@ -321,7 +321,7 @@ void ProjectTree::updateExternalFileWarning() } infoBar->addInfo(Core::InfoBarEntry(externalFileId, tr("<b>Warning:</b> This file is outside the project directory."), - Core::InfoBarEntry::GlobalSuppressionEnabled)); + Core::InfoBarEntry::GlobalSuppression::Enabled)); } bool ProjectTree::hasFocus(ProjectTreeWidget *widget) diff --git a/src/plugins/texteditor/texteditor.cpp b/src/plugins/texteditor/texteditor.cpp index b022a5a7e3..1419b045c2 100644 --- a/src/plugins/texteditor/texteditor.cpp +++ b/src/plugins/texteditor/texteditor.cpp @@ -3101,7 +3101,7 @@ void TextEditorWidgetPrivate::updateSyntaxInfoBar(const Highlighter::Definitions InfoBarEntry info(missing, BaseTextEditor::tr("A highlight definition was not found for this file. " "Would you like to update highlight definition files?"), - InfoBarEntry::GlobalSuppressionEnabled); + InfoBarEntry::GlobalSuppression::Enabled); info.setCustomButtonInfo(BaseTextEditor::tr("Update Definitions"), [missing, this]() { m_document->infoBar()->removeInfo(missing); Highlighter::updateDefinitions([widget = QPointer<TextEditorWidget>(q)]() { diff --git a/src/plugins/welcome/introductionwidget.cpp b/src/plugins/welcome/introductionwidget.cpp index a719a4ae90..a29b5e4f57 100644 --- a/src/plugins/welcome/introductionwidget.cpp +++ b/src/plugins/welcome/introductionwidget.cpp @@ -59,7 +59,7 @@ void IntroductionWidget::askUserAboutIntroduction(QWidget *parent, QSettings *se tr("Would you like to take a quick UI tour? This tour highlights important user " "interface elements and shows how they are used. To take the tour later, " "select Help > UI Tour."), - Core::InfoBarEntry::GlobalSuppressionEnabled); + Core::InfoBarEntry::GlobalSuppression::Enabled); info.setCustomButtonInfo(tr("Take UI Tour"), [parent] { Core::ICore::infoBar()->removeInfo(kTakeTourSetting); Core::ICore::infoBar()->globallySuppressInfo(kTakeTourSetting); |