forked from qt-creator/qt-creator
Move InfoBar to Utils
The only reason it was required to be in Core plugin, was its use of Id, which now is available in Utils. Change-Id: I66ce863c24924e6448d339b3422538a7fe167336 Reviewed-by: Alessandro Portale <alessandro.portale@qt.io> Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
@@ -66,6 +66,7 @@ add_qtc_library(Utils
|
||||
htmldocextractor.cpp htmldocextractor.h
|
||||
icon.cpp icon.h
|
||||
id.cpp id.h
|
||||
infobar.cpp infobar.h
|
||||
infolabel.cpp infolabel.h
|
||||
itemviews.cpp itemviews.h
|
||||
json.cpp json.h
|
||||
|
@@ -1,6 +1,6 @@
|
||||
/****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2016 The Qt Company Ltd.
|
||||
** Copyright (C) 2020 The Qt Company Ltd.
|
||||
** Contact: https://www.qt.io/licensing/
|
||||
**
|
||||
** This file is part of Qt Creator.
|
||||
@@ -25,10 +25,10 @@
|
||||
|
||||
#include "infobar.h"
|
||||
|
||||
#include <utils/algorithm.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/theme/theme.h>
|
||||
#include <utils/utilsicons.h>
|
||||
#include "algorithm.h"
|
||||
#include "qtcassert.h"
|
||||
#include "theme/theme.h"
|
||||
#include "utilsicons.h"
|
||||
|
||||
#include <QHBoxLayout>
|
||||
#include <QSettings>
|
||||
@@ -39,9 +39,7 @@
|
||||
|
||||
static const char C_SUPPRESSED_WARNINGS[] = "SuppressedWarnings";
|
||||
|
||||
using namespace Utils;
|
||||
|
||||
namespace Core {
|
||||
namespace Utils {
|
||||
|
||||
QSet<Id> InfoBar::globallySuppressed;
|
||||
QSettings *InfoBar::m_settings = nullptr;
|
||||
@@ -358,4 +356,4 @@ void InfoBarDisplay::widgetDestroyed()
|
||||
m_infoWidgets.removeOne(static_cast<QWidget *>(sender()));
|
||||
}
|
||||
|
||||
} // namespace Core
|
||||
} // namespace Utils
|
@@ -1,6 +1,6 @@
|
||||
/****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2016 The Qt Company Ltd.
|
||||
** Copyright (C) 2020 The Qt Company Ltd.
|
||||
** Contact: https://www.qt.io/licensing/
|
||||
**
|
||||
** This file is part of Qt Creator.
|
||||
@@ -25,8 +25,8 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "core_global.h"
|
||||
#include <coreplugin/id.h>
|
||||
#include "id.h"
|
||||
#include "utils_global.h"
|
||||
|
||||
#include <QFrame>
|
||||
#include <QObject>
|
||||
@@ -39,14 +39,13 @@ class QBoxLayout;
|
||||
class QSettings;
|
||||
QT_END_NAMESPACE
|
||||
|
||||
namespace Utils { class Theme; }
|
||||
|
||||
namespace Core {
|
||||
namespace Utils {
|
||||
|
||||
class InfoBar;
|
||||
class InfoBarDisplay;
|
||||
class Theme;
|
||||
|
||||
class CORE_EXPORT InfoBarEntry
|
||||
class QTCREATOR_UTILS_EXPORT InfoBarEntry
|
||||
{
|
||||
public:
|
||||
enum class GlobalSuppression
|
||||
@@ -84,7 +83,7 @@ private:
|
||||
friend class InfoBarDisplay;
|
||||
};
|
||||
|
||||
class CORE_EXPORT InfoBar : public QObject
|
||||
class QTCREATOR_UTILS_EXPORT InfoBar : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
@@ -101,7 +100,7 @@ public:
|
||||
static void clearGloballySuppressed();
|
||||
static bool anyGloballySuppressed();
|
||||
|
||||
static void initialize(QSettings *settings, Utils::Theme *theme);
|
||||
static void initialize(QSettings *settings, Theme *theme);
|
||||
|
||||
signals:
|
||||
void changed();
|
||||
@@ -115,12 +114,12 @@ private:
|
||||
|
||||
static QSet<Id> globallySuppressed;
|
||||
static QSettings *m_settings;
|
||||
static Utils::Theme *m_theme;
|
||||
static Theme *m_theme;
|
||||
|
||||
friend class InfoBarDisplay;
|
||||
};
|
||||
|
||||
class CORE_EXPORT InfoBarDisplay : public QObject
|
||||
class QTCREATOR_UTILS_EXPORT InfoBarDisplay : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
@@ -145,4 +144,4 @@ private:
|
||||
bool m_isShowingDetailsWidget = false;
|
||||
};
|
||||
|
||||
} // namespace Core
|
||||
} // namespace Utils
|
@@ -135,7 +135,8 @@ SOURCES += \
|
||||
$$PWD/infolabel.cpp \
|
||||
$$PWD/overlaywidget.cpp \
|
||||
$$PWD/archive.cpp \
|
||||
$$PWD/id.cpp
|
||||
$$PWD/id.cpp \
|
||||
$$PWD/infobar.cpp
|
||||
|
||||
HEADERS += \
|
||||
$$PWD/environmentfwd.h \
|
||||
@@ -287,7 +288,8 @@ HEADERS += \
|
||||
$$PWD/infolabel.h \
|
||||
$$PWD/overlaywidget.h \
|
||||
$$PWD/archive.h \
|
||||
$$PWD/id.h
|
||||
$$PWD/id.h \
|
||||
$$PWD/infobar.h
|
||||
|
||||
FORMS += $$PWD/filewizardpage.ui \
|
||||
$$PWD/projectintropage.ui \
|
||||
|
@@ -145,6 +145,8 @@ Project {
|
||||
"icon.h",
|
||||
"id.cpp",
|
||||
"id.h",
|
||||
"infobar.cpp",
|
||||
"infobar.h",
|
||||
"infolabel.cpp",
|
||||
"infolabel.h",
|
||||
"itemviews.cpp",
|
||||
|
@@ -34,7 +34,6 @@
|
||||
#include "splashiconcontainerwidget.h"
|
||||
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/editormanager/ieditor.h>
|
||||
|
||||
#include <qtsupport/qtkitinformation.h>
|
||||
@@ -53,6 +52,7 @@
|
||||
|
||||
#include <utils/algorithm.h>
|
||||
#include <utils/fileutils.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/stylehelper.h>
|
||||
#include <utils/utilsicons.h>
|
||||
|
||||
@@ -721,13 +721,13 @@ void AndroidManifestEditorWidget::updateSdkVersions()
|
||||
|
||||
void AndroidManifestEditorWidget::updateInfoBar(const QString &errorMessage, int line, int column)
|
||||
{
|
||||
Core::InfoBar *infoBar = m_textEditorWidget->textDocument()->infoBar();
|
||||
Utils::InfoBar *infoBar = m_textEditorWidget->textDocument()->infoBar();
|
||||
QString text;
|
||||
if (line < 0)
|
||||
text = tr("Could not parse file: \"%1\".").arg(errorMessage);
|
||||
else
|
||||
text = tr("%2: Could not parse file: \"%1\".").arg(errorMessage).arg(line);
|
||||
Core::InfoBarEntry infoBarEntry(infoBarId, text);
|
||||
Utils::InfoBarEntry infoBarEntry(infoBarId, text);
|
||||
infoBarEntry.setCustomButtonInfo(tr("Goto error"), [this]() {
|
||||
m_textEditorWidget->gotoLine(m_errorLine, m_errorColumn);
|
||||
});
|
||||
@@ -741,7 +741,7 @@ void AndroidManifestEditorWidget::updateInfoBar(const QString &errorMessage, int
|
||||
|
||||
void AndroidManifestEditorWidget::hideInfoBar()
|
||||
{
|
||||
Core::InfoBar *infoBar = m_textEditorWidget->textDocument()->infoBar();
|
||||
Utils::InfoBar *infoBar = m_textEditorWidget->textDocument()->infoBar();
|
||||
infoBar->removeInfo(infoBarId);
|
||||
m_timerParseCheck.stop();
|
||||
}
|
||||
@@ -753,7 +753,7 @@ void AndroidManifestEditorWidget::setInvalidServiceInfo()
|
||||
Core::Id id(kServicesInvalid);
|
||||
if (m_textEditorWidget->textDocument()->infoBar()->containsInfo(id))
|
||||
return;
|
||||
Core::InfoBarEntry info(id,
|
||||
Utils::InfoBarEntry info(id,
|
||||
tr("Services invalid. "
|
||||
"Manifest cannot be saved. Correct the service definitions before saving."));
|
||||
m_textEditorWidget->textDocument()->infoBar()->addInfo(info);
|
||||
|
@@ -47,8 +47,8 @@
|
||||
#endif
|
||||
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <utils/checkablemessagebox.h>
|
||||
#include <utils/infobar.h>
|
||||
|
||||
#include <projectexplorer/devicesupport/devicemanager.h>
|
||||
#include <projectexplorer/buildconfiguration.h>
|
||||
@@ -194,12 +194,12 @@ void AndroidPlugin::askUserAboutAndroidSetup()
|
||||
|| !Core::ICore::infoBar()->canInfoBeAdded(kSetupAndroidSetting))
|
||||
return;
|
||||
|
||||
Core::InfoBarEntry info(
|
||||
kSetupAndroidSetting,
|
||||
tr("Would you like to configure Android options? This will ensure "
|
||||
"Android kits can be usable and all essential packages are installed. "
|
||||
"To do it later, select Options > Devices > Android."),
|
||||
Core::InfoBarEntry::GlobalSuppression::Enabled);
|
||||
Utils::InfoBarEntry
|
||||
info(kSetupAndroidSetting,
|
||||
tr("Would you like to configure Android options? This will ensure "
|
||||
"Android kits can be usable and all essential packages are installed. "
|
||||
"To do it later, select Options > Devices > Android."),
|
||||
Utils::InfoBarEntry::GlobalSuppression::Enabled);
|
||||
info.setCustomButtonInfo(tr("Configure Android"), [this] {
|
||||
Core::ICore::infoBar()->removeInfo(kSetupAndroidSetting);
|
||||
Core::ICore::infoBar()->globallySuppressInfo(kSetupAndroidSetting);
|
||||
|
@@ -44,7 +44,6 @@
|
||||
#include <coreplugin/editormanager/documentmodel.h>
|
||||
#include <coreplugin/editormanager/editormanager.h>
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/locator/commandlocator.h>
|
||||
#include <coreplugin/messagemanager.h>
|
||||
#include <coreplugin/progressmanager/progressmanager.h>
|
||||
@@ -58,6 +57,7 @@
|
||||
#include <utils/algorithm.h>
|
||||
#include <utils/fileutils.h>
|
||||
#include <utils/hostosinfo.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/parameteraction.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/runextensions.h>
|
||||
|
@@ -91,7 +91,6 @@ add_qtc_plugin(Core
|
||||
ifilewizardextension.h
|
||||
imode.cpp imode.h
|
||||
inavigationwidgetfactory.cpp inavigationwidgetfactory.h
|
||||
infobar.cpp infobar.h
|
||||
ioutputpane.cpp ioutputpane.h
|
||||
iversioncontrol.cpp iversioncontrol.h
|
||||
iwelcomepage.cpp iwelcomepage.h
|
||||
|
@@ -29,7 +29,6 @@
|
||||
#include "helpmanager.h"
|
||||
#include "icore.h"
|
||||
#include "idocument.h"
|
||||
#include "infobar.h"
|
||||
#include "iwizardfactory.h"
|
||||
#include "mainwindow.h"
|
||||
#include "modemanager.h"
|
||||
@@ -50,9 +49,10 @@
|
||||
#include <extensionsystem/pluginmanager.h>
|
||||
#include <extensionsystem/pluginspec.h>
|
||||
#include <utils/algorithm.h>
|
||||
#include <utils/pathchooser.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/macroexpander.h>
|
||||
#include <utils/mimetypes/mimedatabase.h>
|
||||
#include <utils/pathchooser.h>
|
||||
#include <utils/savefile.h>
|
||||
#include <utils/stringutils.h>
|
||||
#include <utils/theme/theme.h>
|
||||
|
@@ -71,7 +71,6 @@ SOURCES += corejsextensions.cpp \
|
||||
sidebar.cpp \
|
||||
fileiconprovider.cpp \
|
||||
icore.cpp \
|
||||
infobar.cpp \
|
||||
editormanager/ieditor.cpp \
|
||||
dialogs/ioptionspage.cpp \
|
||||
settingsdatabase.cpp \
|
||||
@@ -168,7 +167,6 @@ HEADERS += corejsextensions.h \
|
||||
reaper_p.h \
|
||||
icontext.h \
|
||||
icore.h \
|
||||
infobar.h \
|
||||
imode.h \
|
||||
ioutputpane.h \
|
||||
coreconstants.h \
|
||||
|
@@ -102,8 +102,6 @@ Project {
|
||||
"imode.h",
|
||||
"inavigationwidgetfactory.cpp",
|
||||
"inavigationwidgetfactory.h",
|
||||
"infobar.cpp",
|
||||
"infobar.h",
|
||||
"ioutputpane.cpp",
|
||||
"ioutputpane.h",
|
||||
"iversioncontrol.cpp",
|
||||
|
@@ -52,7 +52,6 @@
|
||||
#include <coreplugin/find/searchresultitem.h>
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/imode.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/iversioncontrol.h>
|
||||
#include <coreplugin/modemanager.h>
|
||||
#include <coreplugin/outputpane.h>
|
||||
@@ -68,6 +67,7 @@
|
||||
#include <utils/executeondestruction.h>
|
||||
#include <utils/fileutils.h>
|
||||
#include <utils/hostosinfo.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/macroexpander.h>
|
||||
#include <utils/mimetypes/mimedatabase.h>
|
||||
#include <utils/mimetypes/mimetype.h>
|
||||
|
@@ -31,13 +31,13 @@
|
||||
#include "documentmodel_p.h"
|
||||
|
||||
#include <coreplugin/actionmanager/actionmanager.h>
|
||||
#include <coreplugin/editormanager/ieditor.h>
|
||||
#include <coreplugin/editortoolbar.h>
|
||||
#include <coreplugin/findplaceholder.h>
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/locator/locatorconstants.h>
|
||||
#include <coreplugin/minisplitter.h>
|
||||
#include <coreplugin/editormanager/ieditor.h>
|
||||
#include <coreplugin/findplaceholder.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/theme/theme.h>
|
||||
#include <utils/utilsicons.h>
|
||||
|
@@ -50,10 +50,13 @@ class QStackedWidget;
|
||||
class QToolButton;
|
||||
QT_END_NAMESPACE
|
||||
|
||||
namespace Utils {
|
||||
class InfoBarDisplay;
|
||||
}
|
||||
|
||||
namespace Core {
|
||||
class IDocument;
|
||||
class IEditor;
|
||||
class InfoBarDisplay;
|
||||
class EditorToolBar;
|
||||
|
||||
namespace Internal {
|
||||
@@ -130,7 +133,7 @@ private:
|
||||
EditorToolBar *m_toolBar;
|
||||
|
||||
QStackedWidget *m_container;
|
||||
InfoBarDisplay *m_infoBarDisplay;
|
||||
Utils::InfoBarDisplay *m_infoBarDisplay;
|
||||
QString m_statusWidgetId;
|
||||
QFrame *m_statusHLine;
|
||||
QFrame *m_statusWidget;
|
||||
|
@@ -25,7 +25,7 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "infobar.h"
|
||||
#include <utils/infobar.h>
|
||||
|
||||
#include <QIcon>
|
||||
#include <QWidget>
|
||||
@@ -159,7 +159,7 @@ public:
|
||||
|
||||
int currentIndex() const;
|
||||
QStatusBar *statusBar() const;
|
||||
InfoBar *infoBar();
|
||||
Utils::InfoBar *infoBar();
|
||||
|
||||
void setTabEnabled(int index, bool enable);
|
||||
bool isTabEnabled(int index) const;
|
||||
@@ -186,8 +186,8 @@ private:
|
||||
QStackedLayout *m_modesStack;
|
||||
QWidget *m_selectionWidget;
|
||||
QStatusBar *m_statusBar;
|
||||
InfoBarDisplay m_infoBarDisplay;
|
||||
InfoBar m_infoBar;
|
||||
Utils::InfoBarDisplay m_infoBarDisplay;
|
||||
Utils::InfoBar m_infoBar;
|
||||
};
|
||||
|
||||
} // namespace Internal
|
||||
|
@@ -27,7 +27,7 @@
|
||||
|
||||
#include "searchresultwindow.h"
|
||||
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <utils/infobar.h>
|
||||
|
||||
#include <QWidget>
|
||||
|
||||
@@ -127,8 +127,8 @@ private:
|
||||
int m_count = 0;
|
||||
QString m_dontAskAgainGroup;
|
||||
QFrame *m_messageWidget = nullptr;
|
||||
InfoBar m_infoBar;
|
||||
InfoBarDisplay m_infoBarDisplay;
|
||||
Utils::InfoBar m_infoBar;
|
||||
Utils::InfoBarDisplay m_infoBarDisplay;
|
||||
QWidget *m_topReplaceWidget = nullptr;
|
||||
QLabel *m_replaceLabel = nullptr;
|
||||
QLineEdit *m_replaceTextEdit = nullptr;
|
||||
|
@@ -26,7 +26,6 @@
|
||||
#include "generalsettings.h"
|
||||
#include "coreconstants.h"
|
||||
#include "icore.h"
|
||||
#include "infobar.h"
|
||||
|
||||
#include "ui_generalsettings.h"
|
||||
|
||||
@@ -34,6 +33,7 @@
|
||||
|
||||
#include <utils/checkablemessagebox.h>
|
||||
#include <utils/hostosinfo.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/stylehelper.h>
|
||||
|
||||
#include <QCoreApplication>
|
||||
|
@@ -654,7 +654,7 @@ QStatusBar *ICore::statusBar()
|
||||
Use for notifying the user of something without interrupting with
|
||||
dialog. Use sparingly.
|
||||
*/
|
||||
InfoBar *ICore::infoBar()
|
||||
Utils::InfoBar *ICore::infoBar()
|
||||
{
|
||||
return m_mainwindow->infoBar();
|
||||
}
|
||||
|
@@ -42,10 +42,13 @@ class QStatusBar;
|
||||
class QWidget;
|
||||
QT_END_NAMESPACE
|
||||
|
||||
namespace Utils {
|
||||
class InfoBar;
|
||||
}
|
||||
|
||||
namespace Core {
|
||||
class Context;
|
||||
class IContext;
|
||||
class InfoBar;
|
||||
class IWizardFactory;
|
||||
class SettingsDatabase;
|
||||
|
||||
@@ -100,7 +103,7 @@ public:
|
||||
|
||||
static QMainWindow *mainWindow();
|
||||
static QWidget *dialogParent();
|
||||
static InfoBar *infoBar();
|
||||
static Utils::InfoBar *infoBar();
|
||||
|
||||
static void raiseWindow(QWidget *widget);
|
||||
|
||||
|
@@ -25,9 +25,8 @@
|
||||
|
||||
#include "idocument.h"
|
||||
|
||||
#include "infobar.h"
|
||||
|
||||
#include <utils/fileutils.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/qtcassert.h>
|
||||
|
||||
#include <QFile>
|
||||
@@ -76,7 +75,7 @@ public:
|
||||
QString preferredDisplayName;
|
||||
QString uniqueDisplayName;
|
||||
QString autoSaveName;
|
||||
InfoBar *infoBar = nullptr;
|
||||
Utils::InfoBar *infoBar = nullptr;
|
||||
Id id;
|
||||
bool temporary = false;
|
||||
bool hasWriteWarning = false;
|
||||
@@ -286,9 +285,9 @@ void IDocument::setRestoredFrom(const QString &name)
|
||||
{
|
||||
d->autoSaveName = name;
|
||||
d->restored = true;
|
||||
InfoBarEntry info(Id(kRestoredAutoSave),
|
||||
tr("File was restored from auto-saved copy. "
|
||||
"Select Save to confirm or Revert to Saved to discard changes."));
|
||||
Utils::InfoBarEntry info(Id(kRestoredAutoSave),
|
||||
tr("File was restored from auto-saved copy. "
|
||||
"Select Save to confirm or Revert to Saved to discard changes."));
|
||||
infoBar()->addInfo(info);
|
||||
}
|
||||
|
||||
@@ -314,10 +313,10 @@ void IDocument::setWriteWarning(bool has)
|
||||
d->hasWriteWarning = has;
|
||||
}
|
||||
|
||||
InfoBar *IDocument::infoBar()
|
||||
Utils::InfoBar *IDocument::infoBar()
|
||||
{
|
||||
if (!d->infoBar)
|
||||
d->infoBar = new InfoBar;
|
||||
d->infoBar = new Utils::InfoBar;
|
||||
return d->infoBar;
|
||||
}
|
||||
|
||||
|
@@ -30,10 +30,12 @@
|
||||
|
||||
#include <QObject>
|
||||
|
||||
namespace Utils { class FilePath; }
|
||||
namespace Utils {
|
||||
class FilePath;
|
||||
class InfoBar;
|
||||
} // namespace Utils
|
||||
|
||||
namespace Core {
|
||||
class InfoBar;
|
||||
|
||||
namespace Internal {
|
||||
class IDocumentPrivate;
|
||||
@@ -130,7 +132,7 @@ public:
|
||||
bool hasWriteWarning() const;
|
||||
void setWriteWarning(bool has);
|
||||
|
||||
InfoBar *infoBar();
|
||||
Utils::InfoBar *infoBar();
|
||||
|
||||
signals:
|
||||
// For meta data changes: file name, modified state, ...
|
||||
|
@@ -41,12 +41,15 @@ class QPrinter;
|
||||
class QToolButton;
|
||||
QT_END_NAMESPACE
|
||||
|
||||
namespace Utils {
|
||||
class InfoBar;
|
||||
}
|
||||
|
||||
namespace Core {
|
||||
|
||||
class EditorManager;
|
||||
class ExternalToolManager;
|
||||
class IDocument;
|
||||
class InfoBar;
|
||||
class JsExpander;
|
||||
class MessageManager;
|
||||
class ModeManager;
|
||||
@@ -94,7 +97,7 @@ public:
|
||||
virtual QPrinter *printer() const;
|
||||
IContext * currentContextObject() const;
|
||||
QStatusBar *statusBar() const;
|
||||
InfoBar *infoBar() const;
|
||||
Utils::InfoBar *infoBar() const;
|
||||
|
||||
void updateAdditionalContexts(const Context &remove, const Context &add,
|
||||
ICore::ContextPriority priority);
|
||||
|
@@ -28,17 +28,17 @@
|
||||
#include "icore.h"
|
||||
#include "documentmanager.h"
|
||||
#include "idocument.h"
|
||||
#include "infobar.h"
|
||||
|
||||
#include <coreplugin/dialogs/addtovcsdialog.h>
|
||||
#include <coreplugin/editormanager/editormanager.h>
|
||||
#include <coreplugin/editormanager/ieditor.h>
|
||||
|
||||
#include <vcsbase/vcsbaseconstants.h>
|
||||
#include <extensionsystem/pluginmanager.h>
|
||||
#include <utils/algorithm.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/optional.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <vcsbase/vcsbaseconstants.h>
|
||||
|
||||
#include <QDir>
|
||||
#include <QString>
|
||||
@@ -296,12 +296,12 @@ IVersionControl* VcsManager::findVersionControlForDirectory(const QString &input
|
||||
}
|
||||
return versionControl;
|
||||
} else {
|
||||
InfoBar *infoBar = curDocument ? curDocument->infoBar() : nullptr;
|
||||
Utils::InfoBar *infoBar = curDocument ? curDocument->infoBar() : nullptr;
|
||||
if (infoBar && infoBar->canInfoBeAdded(vcsWarning)) {
|
||||
InfoBarEntry info(vcsWarning,
|
||||
tr("%1 repository was detected but %1 is not configured.")
|
||||
.arg(versionControl->displayName()),
|
||||
InfoBarEntry::GlobalSuppression::Enabled);
|
||||
Utils::InfoBarEntry info(vcsWarning,
|
||||
tr("%1 repository was detected but %1 is not configured.")
|
||||
.arg(versionControl->displayName()),
|
||||
Utils::InfoBarEntry::GlobalSuppression::Enabled);
|
||||
d->m_unconfiguredVcs = versionControl;
|
||||
info.setCustomButtonInfo(ICore::msgShowOptionsDialog(), []() {
|
||||
QTC_ASSERT(d->m_unconfiguredVcs, return);
|
||||
|
@@ -30,7 +30,7 @@
|
||||
#include "cpphighlighter.h"
|
||||
#include "cppquickfixassistant.h"
|
||||
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/editormanager/editormanager.h>
|
||||
|
||||
#include <cpptools/baseeditordocumentparser.h>
|
||||
#include <cpptools/builtineditordocumentprocessor.h>
|
||||
@@ -48,8 +48,8 @@
|
||||
#include <texteditor/textdocumentlayout.h>
|
||||
#include <texteditor/texteditorsettings.h>
|
||||
|
||||
#include <coreplugin/editormanager/editormanager.h>
|
||||
#include <utils/executeondestruction.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/mimetypes/mimedatabase.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/runextensions.h>
|
||||
@@ -354,10 +354,10 @@ void CppEditorDocument::showHideInfoBarAboutMultipleParseContexts(bool show)
|
||||
const Core::Id id = Constants::MULTIPLE_PARSE_CONTEXTS_AVAILABLE;
|
||||
|
||||
if (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::GlobalSuppression::Enabled);
|
||||
Utils::InfoBarEntry info(id,
|
||||
tr("Note: Multiple parse contexts are available for this file. "
|
||||
"Choose the preferred one from the editor toolbar."),
|
||||
Utils::InfoBarEntry::GlobalSuppression::Enabled);
|
||||
info.removeCancelButton();
|
||||
if (infoBar()->canInfoBeAdded(id))
|
||||
infoBar()->addInfo(info);
|
||||
|
@@ -45,7 +45,6 @@
|
||||
#include <coreplugin/editormanager/documentmodel.h>
|
||||
#include <coreplugin/editormanager/editormanager.h>
|
||||
#include <coreplugin/find/searchresultwindow.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
|
||||
#include <cpptools/cppcanonicalsymbol.h>
|
||||
#include <cpptools/cppchecksymbols.h>
|
||||
@@ -83,6 +82,7 @@
|
||||
#include <cplusplus/ASTPath.h>
|
||||
#include <cplusplus/FastPreprocessor.h>
|
||||
#include <cplusplus/MatchingText.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/progressindicator.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/textutils.h>
|
||||
|
@@ -31,15 +31,16 @@
|
||||
#include <QToolButton>
|
||||
|
||||
#include <coreplugin/id.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
|
||||
#include <cpptools/cpptoolssettings.h>
|
||||
|
||||
#include <utils/utilsicons.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/utilsicons.h>
|
||||
|
||||
using namespace Core;
|
||||
using namespace CppTools;
|
||||
using namespace Utils;
|
||||
|
||||
namespace CppEditor {
|
||||
namespace Internal {
|
||||
|
@@ -33,7 +33,7 @@
|
||||
|
||||
#include <functional>
|
||||
|
||||
namespace Core {
|
||||
namespace Utils {
|
||||
class InfoBar;
|
||||
}
|
||||
|
||||
@@ -52,7 +52,7 @@ public:
|
||||
static Actions createShowInfoBarActions(const ActionCreator &actionCreator);
|
||||
|
||||
public:
|
||||
explicit MinimizableInfoBars(Core::InfoBar &infoBar, QObject *parent = nullptr);
|
||||
explicit MinimizableInfoBars(Utils::InfoBar &infoBar, QObject *parent = nullptr);
|
||||
|
||||
// Expected call order: processHasProjectPart(), processHeaderDiagnostics()
|
||||
void processHasProjectPart(bool hasProjectPart);
|
||||
@@ -70,7 +70,7 @@ private:
|
||||
const DiagnosticWidgetCreator &diagnosticWidgetCreator);
|
||||
|
||||
private:
|
||||
Core::InfoBar &m_infoBar;
|
||||
Utils::InfoBar &m_infoBar;
|
||||
|
||||
bool m_hasProjectPart = true;
|
||||
DiagnosticWidgetCreator m_diagnosticWidgetCreator;
|
||||
|
@@ -34,19 +34,19 @@
|
||||
#include "designercontext.h"
|
||||
#include <widgethost.h>
|
||||
|
||||
#include <coreplugin/editortoolbar.h>
|
||||
#include <coreplugin/designmode.h>
|
||||
#include <coreplugin/coreconstants.h>
|
||||
#include <coreplugin/dialogs/ioptionspage.h>
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/helpmanager.h>
|
||||
#include <coreplugin/actionmanager/actionmanager.h>
|
||||
#include <coreplugin/actionmanager/actioncontainer.h>
|
||||
#include <coreplugin/actionmanager/actionmanager.h>
|
||||
#include <coreplugin/coreconstants.h>
|
||||
#include <coreplugin/designmode.h>
|
||||
#include <coreplugin/dialogs/ioptionspage.h>
|
||||
#include <coreplugin/editormanager/editormanager.h>
|
||||
#include <coreplugin/modemanager.h>
|
||||
#include <coreplugin/editortoolbar.h>
|
||||
#include <coreplugin/helpmanager.h>
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/minisplitter.h>
|
||||
#include <coreplugin/modemanager.h>
|
||||
#include <coreplugin/outputpane.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/qtcassert.h>
|
||||
|
||||
#include <QDesignerFormEditorPluginInterface>
|
||||
@@ -774,8 +774,8 @@ IEditor *FormEditorData::createEditor()
|
||||
m_toolBar->addEditor(formWindowEditor);
|
||||
|
||||
if (formWindowEditor) {
|
||||
InfoBarEntry info(Id(Constants::INFO_READ_ONLY),
|
||||
tr("This file can only be edited in <b>Design</b> mode."));
|
||||
Utils::InfoBarEntry info(Id(Constants::INFO_READ_ONLY),
|
||||
tr("This file can only be edited in <b>Design</b> mode."));
|
||||
info.setCustomButtonInfo(tr("Switch Mode"), []() { ModeManager::activateMode(Core::Constants::MODE_DESIGN); });
|
||||
formWindowEditor->document()->infoBar()->addInfo(info);
|
||||
}
|
||||
|
@@ -30,7 +30,6 @@
|
||||
|
||||
#include <coreplugin/documentmanager.h>
|
||||
#include <coreplugin/editormanager/editormanager.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/patchtool.h>
|
||||
|
||||
#include <texteditor/fontsettings.h>
|
||||
@@ -40,6 +39,7 @@
|
||||
|
||||
#include <cpaster/codepasterservice.h>
|
||||
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/progressindicator.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/temporaryfile.h>
|
||||
@@ -307,15 +307,15 @@ void DiffEditorWidgetController::updateCannotDecodeInfo()
|
||||
if (!m_document)
|
||||
return;
|
||||
|
||||
InfoBar *infoBar = m_document->infoBar();
|
||||
Utils::InfoBar *infoBar = m_document->infoBar();
|
||||
Id selectEncodingId(Constants::SELECT_ENCODING);
|
||||
if (m_document->hasDecodingError()) {
|
||||
if (!infoBar->canInfoBeAdded(selectEncodingId))
|
||||
return;
|
||||
InfoBarEntry info(selectEncodingId,
|
||||
tr("<b>Error:</b> Could not decode \"%1\" with \"%2\"-encoding.")
|
||||
.arg(m_document->displayName(),
|
||||
QString::fromLatin1(m_document->codec()->name())));
|
||||
Utils::InfoBarEntry info(selectEncodingId,
|
||||
tr("<b>Error:</b> Could not decode \"%1\" with \"%2\"-encoding.")
|
||||
.arg(m_document->displayName(),
|
||||
QString::fromLatin1(m_document->codec()->name())));
|
||||
info.setCustomButtonInfo(tr("Select Encoding"), [this]() { m_document->selectEncoding(); });
|
||||
infoBar->addInfo(info);
|
||||
} else {
|
||||
|
@@ -50,7 +50,6 @@
|
||||
#include <coreplugin/actionmanager/command.h>
|
||||
#include <coreplugin/id.h>
|
||||
#include <coreplugin/idocument.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/editormanager/editormanager.h>
|
||||
#include <coreplugin/editormanager/ieditor.h>
|
||||
#include <coreplugin/locator/commandlocator.h>
|
||||
@@ -60,12 +59,14 @@
|
||||
#include <coreplugin/vcsmanager.h>
|
||||
|
||||
#include <aggregation/aggregate.h>
|
||||
|
||||
#include <texteditor/texteditor.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/parameteraction.h>
|
||||
#include <utils/pathchooser.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/stringutils.h>
|
||||
#include <utils/utilsicons.h>
|
||||
#include <texteditor/texteditor.h>
|
||||
|
||||
#include <vcsbase/basevcseditorfactory.h>
|
||||
#include <vcsbase/submitfilemodel.h>
|
||||
|
@@ -33,12 +33,13 @@
|
||||
#include <coreplugin/coreconstants.h>
|
||||
#include <coreplugin/icontext.h>
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
|
||||
#include <projectexplorer/devicesupport/devicemanager.h>
|
||||
#include <projectexplorer/jsonwizard/jsonwizardfactory.h>
|
||||
#include <projectexplorer/kitmanager.h>
|
||||
|
||||
#include <utils/infobar.h>
|
||||
|
||||
#include <QTimer>
|
||||
|
||||
using namespace Core;
|
||||
@@ -107,11 +108,10 @@ void McuSupportPlugin::askUserAboutMcuSupportKitsSetup()
|
||||
|| !McuSupportOptions::existingKits(nullptr).isEmpty())
|
||||
return;
|
||||
|
||||
InfoBarEntry info(
|
||||
setupMcuSupportKits,
|
||||
tr("Create Kits for Qt for MCUs? "
|
||||
"To do it later, select Options > Devices > MCU."),
|
||||
InfoBarEntry::GlobalSuppression::Enabled);
|
||||
Utils::InfoBarEntry info(setupMcuSupportKits,
|
||||
tr("Create Kits for Qt for MCUs? "
|
||||
"To do it later, select Options > Devices > MCU."),
|
||||
Utils::InfoBarEntry::GlobalSuppression::Enabled);
|
||||
info.setCustomButtonInfo(tr("Create Kits for Qt for MCUs"), [setupMcuSupportKits] {
|
||||
ICore::infoBar()->removeInfo(setupMcuSupportKits);
|
||||
QTimer::singleShot(0, []() { ICore::showOptionsDialog(Constants::SETTINGS_ID); });
|
||||
|
@@ -39,12 +39,12 @@
|
||||
#include <coreplugin/editormanager/ieditor.h>
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/idocument.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/modemanager.h>
|
||||
#include <coreplugin/navigationwidget.h>
|
||||
#include <coreplugin/vcsmanager.h>
|
||||
|
||||
#include <utils/algorithm.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/qtcassert.h>
|
||||
|
||||
#include <QApplication>
|
||||
@@ -314,7 +314,7 @@ void ProjectTree::updateExternalFileWarning()
|
||||
auto document = qobject_cast<Core::IDocument *>(sender());
|
||||
if (!document || document->filePath().isEmpty())
|
||||
return;
|
||||
Core::InfoBar *infoBar = document->infoBar();
|
||||
Utils::InfoBar *infoBar = document->infoBar();
|
||||
Core::Id externalFileId(EXTERNAL_FILE_WARNING);
|
||||
if (!document->isModified()) {
|
||||
infoBar->removeInfo(externalFileId);
|
||||
@@ -339,9 +339,10 @@ void ProjectTree::updateExternalFileWarning()
|
||||
return;
|
||||
}
|
||||
}
|
||||
infoBar->addInfo(Core::InfoBarEntry(externalFileId,
|
||||
tr("<b>Warning:</b> This file is outside the project directory."),
|
||||
Core::InfoBarEntry::GlobalSuppression::Enabled));
|
||||
infoBar->addInfo(
|
||||
Utils::InfoBarEntry(externalFileId,
|
||||
tr("<b>Warning:</b> This file is outside the project directory."),
|
||||
Utils::InfoBarEntry::GlobalSuppression::Enabled));
|
||||
}
|
||||
|
||||
bool ProjectTree::hasFocus(ProjectTreeWidget *widget)
|
||||
|
@@ -32,7 +32,6 @@
|
||||
#include "pythonsettings.h"
|
||||
|
||||
#include <coreplugin/editormanager/editormanager.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/progressmanager/progressmanager.h>
|
||||
|
||||
#include <languageclient/languageclientmanager.h>
|
||||
@@ -44,6 +43,7 @@
|
||||
#include <texteditor/textdocument.h>
|
||||
|
||||
#include <utils/consoleprocess.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/mimetypes/mimedatabase.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/runextensions.h>
|
||||
@@ -412,15 +412,15 @@ void PyLSConfigureAssistant::handlePyLSState(const FilePath &python,
|
||||
}
|
||||
|
||||
resetEditorInfoBar(document);
|
||||
Core::InfoBar *infoBar = document->infoBar();
|
||||
Utils::InfoBar *infoBar = document->infoBar();
|
||||
if (state.state == PythonLanguageServerState::CanBeInstalled
|
||||
&& infoBar->canInfoBeAdded(installPylsInfoBarId)) {
|
||||
auto message = tr("Install and set up Python language server (PyLS) for %1 (%2). "
|
||||
"The language server provides Python specific completion and annotation.")
|
||||
.arg(pythonName(python), python.toUserOutput());
|
||||
Core::InfoBarEntry info(installPylsInfoBarId,
|
||||
message,
|
||||
Core::InfoBarEntry::GlobalSuppression::Enabled);
|
||||
Utils::InfoBarEntry info(installPylsInfoBarId,
|
||||
message,
|
||||
Utils::InfoBarEntry::GlobalSuppression::Enabled);
|
||||
info.setCustomButtonInfo(tr("Install"),
|
||||
[=]() { installPythonLanguageServer(python, document); });
|
||||
infoBar->addInfo(info);
|
||||
@@ -430,9 +430,9 @@ void PyLSConfigureAssistant::handlePyLSState(const FilePath &python,
|
||||
auto message = tr("Found a Python language server for %1 (%2). "
|
||||
"Set it up for this document?")
|
||||
.arg(pythonName(python), python.toUserOutput());
|
||||
Core::InfoBarEntry info(startPylsInfoBarId,
|
||||
message,
|
||||
Core::InfoBarEntry::GlobalSuppression::Enabled);
|
||||
Utils::InfoBarEntry info(startPylsInfoBarId,
|
||||
message,
|
||||
Utils::InfoBarEntry::GlobalSuppression::Enabled);
|
||||
info.setCustomButtonInfo(tr("Setup"),
|
||||
[=]() { setupPythonLanguageServer(python, document); });
|
||||
infoBar->addInfo(info);
|
||||
@@ -441,9 +441,9 @@ void PyLSConfigureAssistant::handlePyLSState(const FilePath &python,
|
||||
&& infoBar->canInfoBeAdded(enablePylsInfoBarId)) {
|
||||
auto message = tr("Enable Python language server for %1 (%2)?")
|
||||
.arg(pythonName(python), python.toUserOutput());
|
||||
Core::InfoBarEntry info(enablePylsInfoBarId,
|
||||
message,
|
||||
Core::InfoBarEntry::GlobalSuppression::Enabled);
|
||||
Utils::InfoBarEntry info(enablePylsInfoBarId,
|
||||
message,
|
||||
Utils::InfoBarEntry::GlobalSuppression::Enabled);
|
||||
info.setCustomButtonInfo(tr("Enable"),
|
||||
[=]() { enablePythonLanguageServer(python, document); });
|
||||
infoBar->addInfo(info);
|
||||
@@ -464,7 +464,7 @@ void PyLSConfigureAssistant::resetEditorInfoBar(TextEditor::TextDocument *docume
|
||||
{
|
||||
for (QList<TextEditor::TextDocument *> &documents : m_infoBarEntries)
|
||||
documents.removeAll(document);
|
||||
Core::InfoBar *infoBar = document->infoBar();
|
||||
Utils::InfoBar *infoBar = document->infoBar();
|
||||
infoBar->removeInfo(installPylsInfoBarId);
|
||||
infoBar->removeInfo(startPylsInfoBarId);
|
||||
infoBar->removeInfo(enablePylsInfoBarId);
|
||||
|
@@ -36,13 +36,14 @@
|
||||
#include "qmloutlinemodel.h"
|
||||
|
||||
#include <coreplugin/coreconstants.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/modemanager.h>
|
||||
|
||||
#include <qmljstools/qmljsindenter.h>
|
||||
#include <qmljstools/qmljsmodelmanager.h>
|
||||
#include <qmljstools/qmljsqtstylecodeformatter.h>
|
||||
|
||||
#include <utils/infobar.h>
|
||||
|
||||
#include <QDebug>
|
||||
|
||||
const char QML_UI_FILE_WARNING[] = "QmlJSEditor.QmlUiFileWarning";
|
||||
@@ -692,8 +693,8 @@ void QmlJSEditorDocument::setIsDesignModePreferred(bool value)
|
||||
d->m_isDesignModePreferred = value;
|
||||
if (value) {
|
||||
if (infoBar()->canInfoBeAdded(QML_UI_FILE_WARNING)) {
|
||||
Core::InfoBarEntry info(QML_UI_FILE_WARNING,
|
||||
tr("This file should only be edited in <b>Design</b> mode."));
|
||||
Utils::InfoBarEntry info(QML_UI_FILE_WARNING,
|
||||
tr("This file should only be edited in <b>Design</b> mode."));
|
||||
info.setCustomButtonInfo(tr("Switch Mode"), []() {
|
||||
Core::ModeManager::activateMode(Core::Constants::MODE_DESIGN);
|
||||
});
|
||||
|
@@ -40,7 +40,6 @@
|
||||
#include "uicgenerator.h"
|
||||
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/jsexpander.h>
|
||||
|
||||
#include <projectexplorer/jsonwizard/jsonwizardfactory.h>
|
||||
@@ -50,6 +49,7 @@
|
||||
#include <projectexplorer/runcontrol.h>
|
||||
#include <projectexplorer/target.h>
|
||||
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/macroexpander.h>
|
||||
|
||||
const char kHostBins[] = "CurrentProject:QT_HOST_BINS";
|
||||
@@ -126,12 +126,12 @@ static void askAboutQtInstallation()
|
||||
|| !ICore::infoBar()->canInfoBeAdded(kLinkWithQtInstallationSetting))
|
||||
return;
|
||||
|
||||
InfoBarEntry info(
|
||||
Utils::InfoBarEntry info(
|
||||
kLinkWithQtInstallationSetting,
|
||||
QtSupportPlugin::tr(
|
||||
"Link with a Qt installation to automatically register Qt versions and kits? To do "
|
||||
"this later, select Options > Kits > Qt Versions > Link with Qt."),
|
||||
InfoBarEntry::GlobalSuppression::Enabled);
|
||||
Utils::InfoBarEntry::GlobalSuppression::Enabled);
|
||||
info.setCustomButtonInfo(QtSupportPlugin::tr("Link with Qt"), [] {
|
||||
ICore::infoBar()->removeInfo(kLinkWithQtInstallationSetting);
|
||||
ICore::infoBar()->globallySuppressInfo(kLinkWithQtInstallationSetting);
|
||||
|
@@ -36,15 +36,15 @@
|
||||
#include <coreplugin/editormanager/editormanager.h>
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/idocument.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/minisplitter.h>
|
||||
#include <coreplugin/modemanager.h>
|
||||
#include <coreplugin/outputpane.h>
|
||||
|
||||
#include <projectexplorer/projectexplorerconstants.h>
|
||||
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/icon.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/utilsicons.h>
|
||||
|
||||
#include <QVBoxLayout>
|
||||
@@ -160,8 +160,8 @@ IEditor *ScxmlEditorData::createEditor()
|
||||
m_mainToolBar->addEditor(xmlEditor);
|
||||
|
||||
if (xmlEditor) {
|
||||
InfoBarEntry info(Id(Constants::INFO_READ_ONLY),
|
||||
tr("This file can only be edited in <b>Design</b> mode."));
|
||||
Utils::InfoBarEntry info(Id(Constants::INFO_READ_ONLY),
|
||||
tr("This file can only be edited in <b>Design</b> mode."));
|
||||
info.setCustomButtonInfo(tr("Switch Mode"), []() { ModeManager::activateMode(Core::Constants::MODE_DESIGN); });
|
||||
xmlEditor->document()->infoBar()->addInfo(info);
|
||||
}
|
||||
|
@@ -34,7 +34,7 @@
|
||||
#include "textindenter.h"
|
||||
|
||||
#include <coreplugin/coreconstants.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/qtcassert.h>
|
||||
|
||||
#include <QCoreApplication>
|
||||
|
@@ -58,17 +58,16 @@
|
||||
#include <texteditor/codeassist/completionassistprovider.h>
|
||||
#include <texteditor/codeassist/documentcontentcompletion.h>
|
||||
|
||||
#include <coreplugin/dialogs/codecselector.h>
|
||||
#include <coreplugin/icore.h>
|
||||
#include <aggregation/aggregate.h>
|
||||
#include <coreplugin/actionmanager/actionmanager.h>
|
||||
#include <coreplugin/actionmanager/actioncontainer.h>
|
||||
#include <coreplugin/actionmanager/actionmanager.h>
|
||||
#include <coreplugin/actionmanager/command.h>
|
||||
#include <coreplugin/coreconstants.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/manhattanstyle.h>
|
||||
#include <coreplugin/dialogs/codecselector.h>
|
||||
#include <coreplugin/find/basetextfind.h>
|
||||
#include <coreplugin/find/highlightscrollbarcontroller.h>
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/manhattanstyle.h>
|
||||
#include <utils/algorithm.h>
|
||||
#include <utils/camelcasecursor.h>
|
||||
#include <utils/dropsupport.h>
|
||||
@@ -78,6 +77,7 @@
|
||||
#include <utils/fileutils.h>
|
||||
#include <utils/fixedsizeclicklabel.h>
|
||||
#include <utils/hostosinfo.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/mimetypes/mimedatabase.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/styledbar.h>
|
||||
|
@@ -30,10 +30,10 @@
|
||||
#include <coreplugin/actionmanager/actionmanager.h>
|
||||
#include <coreplugin/coreconstants.h>
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <coreplugin/settingsdatabase.h>
|
||||
#include <coreplugin/shellcommand.h>
|
||||
#include <utils/fileutils.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/synchronousprocess.h>
|
||||
|
||||
#include <QDate>
|
||||
@@ -192,8 +192,7 @@ void UpdateInfoPlugin::checkForUpdatesFinished()
|
||||
if (d->m_progress)
|
||||
d->m_progress->setKeepOnFinish(FutureProgress::HideOnFinish);
|
||||
emit newUpdatesAvailable(true);
|
||||
Core::InfoBarEntry info(InstallUpdates,
|
||||
tr("New updates are available. Start the update?"));
|
||||
Utils::InfoBarEntry info(InstallUpdates, tr("New updates are available. Start the update?"));
|
||||
info.setCustomButtonInfo(tr("Start Update"), [this] {
|
||||
Core::ICore::infoBar()->removeInfo(InstallUpdates);
|
||||
startUpdater();
|
||||
|
@@ -26,9 +26,9 @@
|
||||
#include "introductionwidget.h"
|
||||
|
||||
#include <coreplugin/icore.h>
|
||||
#include <coreplugin/infobar.h>
|
||||
#include <utils/algorithm.h>
|
||||
#include <utils/checkablemessagebox.h>
|
||||
#include <utils/infobar.h>
|
||||
#include <utils/qtcassert.h>
|
||||
#include <utils/stylehelper.h>
|
||||
|
||||
@@ -54,12 +54,12 @@ void IntroductionWidget::askUserAboutIntroduction(QWidget *parent, QSettings *se
|
||||
|| !Core::ICore::infoBar()->canInfoBeAdded(kTakeTourSetting))
|
||||
return;
|
||||
|
||||
Core::InfoBarEntry
|
||||
Utils::InfoBarEntry
|
||||
info(kTakeTourSetting,
|
||||
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::GlobalSuppression::Enabled);
|
||||
Utils::InfoBarEntry::GlobalSuppression::Enabled);
|
||||
info.setCustomButtonInfo(tr("Take UI Tour"), [parent] {
|
||||
Core::ICore::infoBar()->removeInfo(kTakeTourSetting);
|
||||
Core::ICore::infoBar()->globallySuppressInfo(kTakeTourSetting);
|
||||
|
Reference in New Issue
Block a user