mirror of
https://github.com/martinrotter/rssguard.git
synced 2025-01-23 14:11:44 +01:00
Clearing icon cache.
This commit is contained in:
parent
4ffab88435
commit
bcb2421be1
@ -283,6 +283,9 @@ void FormMain::setupIcons() {
|
||||
|
||||
// Setup icons on TabWidget too.
|
||||
m_ui->m_tabWidget->setupIcons();
|
||||
|
||||
// Most of icons are loaded, clear the cache.
|
||||
qApp->icons()->clearCache();
|
||||
}
|
||||
|
||||
void FormMain::loadSize() {
|
||||
|
@ -57,6 +57,10 @@ QByteArray IconFactory::toByteArray(const QIcon &icon) {
|
||||
return array.toBase64();
|
||||
}
|
||||
|
||||
void IconFactory::clearCache() {
|
||||
m_cachedIcons.clear();
|
||||
}
|
||||
|
||||
void IconFactory::setupSearchPaths() {
|
||||
QIcon::setThemeSearchPaths(QStringList() << APP_THEME_PATH);
|
||||
qDebug("Available icon theme paths: %s.",
|
||||
|
@ -44,6 +44,8 @@ class IconFactory : public QObject {
|
||||
QIcon fromByteArray(QByteArray array);
|
||||
QByteArray toByteArray(const QIcon &icon);
|
||||
|
||||
void clearCache();
|
||||
|
||||
// Returns icon from active theme or invalid icon if
|
||||
// "no icon theme" is set.
|
||||
inline QIcon fromTheme(const QString &name) {
|
||||
|
Loading…
Reference in New Issue
Block a user