diff options
author | Alessandro Portale <[email protected]> | 2015-11-23 16:41:54 +0100 |
---|---|---|
committer | Alessandro Portale <[email protected]> | 2015-11-25 12:30:52 +0000 |
commit | 033862f3057818df3123d07fc6cb34e193250c53 (patch) | |
tree | 884de0b3b8ac16e548e4f585bd8c821aa890f8b4 /src/plugins/imageviewer/imageviewer.cpp | |
parent | 00c75cd7ebde4f191c15e92550db369163a95b68 (diff) |
Themed Icons: Introduce Utils::Icon
Instead of describing icons via file name or in the themed icons case
via
a string that is a list of mask/color pairs, we have now a class for it.
Icons are now listed in per-plugin *icons.h headers.
RunControl::m_icon was The only place left where an icon property was in
fact a string. This patch changes that member to be a Utils::Icon.
Change-Id: Ibcfa8bb25e6d2e330c567ee7ccc0b97ead603177
Reviewed-by: Eike Ziller <[email protected]>
Diffstat (limited to 'src/plugins/imageviewer/imageviewer.cpp')
-rw-r--r-- | src/plugins/imageviewer/imageviewer.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/plugins/imageviewer/imageviewer.cpp b/src/plugins/imageviewer/imageviewer.cpp index 1614ea3032b..a629a6d7295 100644 --- a/src/plugins/imageviewer/imageviewer.cpp +++ b/src/plugins/imageviewer/imageviewer.cpp @@ -36,12 +36,12 @@ #include "imageview.h" #include "ui_imageviewertoolbar.h" +#include <coreplugin/coreicons.h> #include <coreplugin/icore.h> #include <coreplugin/actionmanager/actionmanager.h> #include <coreplugin/actionmanager/command.h> #include <utils/fileutils.h> #include <utils/qtcassert.h> -#include <utils/themehelper.h> #include <QMap> #include <QFileInfo> @@ -106,12 +106,9 @@ void ImageViewer::ctor() // toolbar d->toolbar = new QWidget(); d->ui_toolbar.setupUi(d->toolbar); - d->ui_toolbar.toolButtonZoomIn->setIcon(Utils::ThemeHelper::themedIcon( - QLatin1String(Core::Constants::ICON_PLUS))); - d->ui_toolbar.toolButtonZoomOut->setIcon(Utils::ThemeHelper::themedIcon( - QLatin1String(Core::Constants::ICON_MINUS))); - d->ui_toolbar.toolButtonFitToScreen->setIcon(Utils::ThemeHelper::themedIcon( - QLatin1String(Core::Constants::ICON_ZOOM))); + d->ui_toolbar.toolButtonZoomIn->setIcon(Core::Icons::PLUS.icon()); + d->ui_toolbar.toolButtonZoomOut->setIcon(Core::Icons::MINUS.icon()); + d->ui_toolbar.toolButtonFitToScreen->setIcon(Core::Icons::ZOOM.icon()); // icons update - try to use system theme updateButtonIconByTheme(d->ui_toolbar.toolButtonZoomIn, QLatin1String("zoom-in")); |