mirror of
https://github.com/martinrotter/rssguard.git
synced 2025-01-10 15:22:30 +01:00
Fixing of icon loading.
This commit is contained in:
parent
66821e9695
commit
3319c7b78f
@ -73,7 +73,7 @@ QSettings::Status Settings::setupSettings() {
|
||||
QDir(web_path).mkpath(web_path);
|
||||
QWebSettings::setIconDatabasePath(web_path);
|
||||
|
||||
qDebug("Initializing settings in %s (portable way).",
|
||||
qDebug("Initializing settings in '%s' (portable way).",
|
||||
qPrintable(QDir::toNativeSeparators(app_path)));
|
||||
}
|
||||
else {
|
||||
@ -91,7 +91,7 @@ QSettings::Status Settings::setupSettings() {
|
||||
QDir(web_path).mkpath(web_path);
|
||||
QWebSettings::setIconDatabasePath(web_path);
|
||||
|
||||
qDebug("Initializing settings in %s (non-portable way).",
|
||||
qDebug("Initializing settings in '%s' (non-portable way).",
|
||||
qPrintable(QDir::toNativeSeparators(home_path_file)));
|
||||
}
|
||||
|
||||
|
@ -14,7 +14,7 @@
|
||||
QPointer<IconThemeFactory> IconThemeFactory::s_instance;
|
||||
|
||||
IconThemeFactory::IconThemeFactory(QObject *parent)
|
||||
: QObject(parent), m_currentIconTheme(APP_THEME_DEFAULT) {
|
||||
: QObject(parent) {
|
||||
}
|
||||
|
||||
IconThemeFactory::~IconThemeFactory() {
|
||||
@ -32,7 +32,8 @@ IconThemeFactory *IconThemeFactory::getInstance() {
|
||||
void IconThemeFactory::setupSearchPaths() {
|
||||
QIcon::setThemeSearchPaths(QStringList() << APP_THEME_PATH);
|
||||
qDebug("Available icon theme paths: %s.",
|
||||
qPrintable(QIcon::themeSearchPaths().join(", ")));
|
||||
qPrintable(QIcon::themeSearchPaths().replaceInStrings(QRegExp("^|$"),
|
||||
"\'").join(", ")));
|
||||
}
|
||||
|
||||
QString IconThemeFactory::getCurrentIconTheme() {
|
||||
@ -74,7 +75,8 @@ void IconThemeFactory::loadCurrentIconTheme() {
|
||||
|
||||
// Display list of installed themes.
|
||||
qDebug("Installed icon themes are: %s.",
|
||||
qPrintable(installed_themes.join(", ")));
|
||||
qPrintable(QStringList(installed_themes).replaceInStrings(QRegExp("^|$"),
|
||||
"\'").join(", ")));
|
||||
|
||||
if (installed_themes.contains(theme_name_from_settings)) {
|
||||
// Desired icon theme is installed and can be loaded.
|
||||
@ -104,9 +106,9 @@ QStringList IconThemeFactory::getInstalledIconThemes() {
|
||||
|
||||
// Iterate all icon themes in this directory.
|
||||
foreach (const QString &icon_theme_path, icon_dir.entryList(QDir::Dirs | QDir::NoDotAndDotDot |
|
||||
QDir::Readable | QDir::CaseSensitive |
|
||||
QDir::NoSymLinks,
|
||||
QDir::Time)) {
|
||||
QDir::Readable | QDir::CaseSensitive |
|
||||
QDir::NoSymLinks,
|
||||
QDir::Time)) {
|
||||
icon_theme_names << icon_theme_path;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user