Enhancements to icon theme, defaults on linux to default icon theme.
This commit is contained in:
parent
782ec0c57d
commit
1d862fdd2b
@ -128,7 +128,13 @@
|
||||
#define APP_SKIN_DEFAULT "vergilius"
|
||||
#define APP_SKIN_METADATA_FILE "metadata.xml"
|
||||
#define APP_STYLE_DEFAULT "Fusion"
|
||||
|
||||
#if defined(Q_OS_LINUX)
|
||||
#define APP_THEME_DEFAULT ""
|
||||
#else
|
||||
#define APP_THEME_DEFAULT "Faenza"
|
||||
#endif
|
||||
|
||||
#define APP_NO_THEME ""
|
||||
#define APP_THEME_SUFFIX ".png"
|
||||
|
||||
|
6
src/librssguard/gui/settings/settingsgui.cpp
Normal file → Executable file
6
src/librssguard/gui/settings/settingsgui.cpp
Normal file → Executable file
@ -103,7 +103,11 @@ void SettingsGui::loadSettings() {
|
||||
if (icon_theme_name == APP_NO_THEME) {
|
||||
// Add just "no theme" on other systems.
|
||||
//: Label for disabling icon theme.
|
||||
m_ui->m_cmbIconTheme->addItem(tr("no icon theme/system icon theme"), APP_NO_THEME);
|
||||
#if defined(Q_OS_LINUX)
|
||||
m_ui->m_cmbIconTheme->addItem(tr("system icon theme"), APP_NO_THEME);
|
||||
#else
|
||||
m_ui->m_cmbIconTheme->addItem(tr("no icon theme"), APP_NO_THEME);
|
||||
#endif
|
||||
}
|
||||
else {
|
||||
m_ui->m_cmbIconTheme->addItem(icon_theme_name, icon_theme_name);
|
||||
|
@ -85,17 +85,24 @@ void IconFactory::loadCurrentIconTheme() {
|
||||
}
|
||||
else {
|
||||
// Desired icon theme is not currently available.
|
||||
// Install "default" icon theme instead.
|
||||
qWarning("Icon theme '%s' cannot be loaded because it is not installed. No icon theme (or default/system icon theme) is loaded now.",
|
||||
// Activate "default" or "no" icon theme instead.
|
||||
#if defined(Q_OS_LINUX)
|
||||
qWarning("Icon theme '%s' cannot be loaded. Activating \"system default\" icon theme.",
|
||||
qPrintable(theme_name_from_settings));
|
||||
#else
|
||||
qWarning("Icon theme '%s' cannot be loaded because it is not installed. Activating \"no\" icon theme.",
|
||||
qPrintable(theme_name_from_settings));
|
||||
QIcon::setThemeName(APP_NO_THEME);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
QStringList IconFactory::installedIconThemes() const {
|
||||
QStringList icon_theme_names;
|
||||
|
||||
icon_theme_names << APP_NO_THEME; //<< QSL("Faenza");
|
||||
#if !defined(Q_OS_LINUX)
|
||||
icon_theme_names << APP_NO_THEME;
|
||||
#endif
|
||||
|
||||
// Iterate all directories with icon themes.
|
||||
QStringList icon_themes_paths = QIcon::themeSearchPaths();
|
||||
|
Loading…
x
Reference in New Issue
Block a user