forked from qt-creator/qt-creator
Core: Make IOptionsPageProvider::categoryIcon a Utils::Icon
...just like it is with IOptionsPage Change-Id: I033891f1a908be24b05103cb13a4ef628994d2a7 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -211,5 +211,5 @@ const QList<Core::IOptionsPageProvider *> Core::IOptionsPageProvider::allOptions
|
|||||||
|
|
||||||
QIcon Core::IOptionsPageProvider::categoryIcon() const
|
QIcon Core::IOptionsPageProvider::categoryIcon() const
|
||||||
{
|
{
|
||||||
return QIcon(m_categoryIcon);
|
return m_categoryIcon.icon();
|
||||||
}
|
}
|
||||||
|
@@ -105,11 +105,11 @@ public:
|
|||||||
protected:
|
protected:
|
||||||
void setCategory(Id category) { m_category = category; }
|
void setCategory(Id category) { m_category = category; }
|
||||||
void setDisplayCategory(const QString &displayCategory) { m_displayCategory = displayCategory; }
|
void setDisplayCategory(const QString &displayCategory) { m_displayCategory = displayCategory; }
|
||||||
void setCategoryIcon(const QString &categoryIcon) { m_categoryIcon = categoryIcon; }
|
void setCategoryIcon(const Utils::Icon &categoryIcon) { m_categoryIcon = categoryIcon; }
|
||||||
|
|
||||||
Id m_category;
|
Id m_category;
|
||||||
QString m_displayCategory;
|
QString m_displayCategory;
|
||||||
QString m_categoryIcon;
|
Utils::Icon m_categoryIcon;
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace Core
|
} // namespace Core
|
||||||
|
@@ -36,7 +36,6 @@ const char C_DESIGNER_XML_EDITOR[] = "Designer Xml Editor";
|
|||||||
const char C_DESIGNER_XML_DISPLAY_NAME[] = QT_TRANSLATE_NOOP("Designer", "Form Editor");
|
const char C_DESIGNER_XML_DISPLAY_NAME[] = QT_TRANSLATE_NOOP("Designer", "Form Editor");
|
||||||
|
|
||||||
const char SETTINGS_CATEGORY[] = "P.Designer";
|
const char SETTINGS_CATEGORY[] = "P.Designer";
|
||||||
const char SETTINGS_CATEGORY_ICON[] = ":/core/images/category_design.png";
|
|
||||||
const char SETTINGS_TR_CATEGORY[] = QT_TRANSLATE_NOOP("Designer", "Designer");
|
const char SETTINGS_TR_CATEGORY[] = QT_TRANSLATE_NOOP("Designer", "Designer");
|
||||||
|
|
||||||
// Context
|
// Context
|
||||||
|
@@ -72,7 +72,7 @@ SettingsPageProvider::SettingsPageProvider(QObject *parent)
|
|||||||
setCategory(Designer::Constants::SETTINGS_CATEGORY);
|
setCategory(Designer::Constants::SETTINGS_CATEGORY);
|
||||||
setDisplayCategory(QCoreApplication::translate("Designer",
|
setDisplayCategory(QCoreApplication::translate("Designer",
|
||||||
Designer::Constants::SETTINGS_TR_CATEGORY));
|
Designer::Constants::SETTINGS_TR_CATEGORY));
|
||||||
setCategoryIcon(Designer::Constants::SETTINGS_CATEGORY_ICON);
|
setCategoryIcon(Utils::Icon(":/core/images/category_design.png"));
|
||||||
}
|
}
|
||||||
|
|
||||||
QList<Core::IOptionsPage *> SettingsPageProvider::pages() const
|
QList<Core::IOptionsPage *> SettingsPageProvider::pages() const
|
||||||
|
Reference in New Issue
Block a user