diff options
author | Robert Griebl <rgriebl@trolltech.com> | 2009-10-15 16:37:13 (GMT) |
---|---|---|
committer | Robert Griebl <rgriebl@trolltech.com> | 2009-10-15 16:39:12 (GMT) |
commit | 307a12d9e2a5ec302e44d29c5ba5ca4cf0f7ebff (patch) | |
tree | ce25eeb014679494c548a574b60f5b594b1d005b /src | |
parent | fd2049b3e318e28a10c18fe344de54820ef9ea40 (diff) | |
download | Qt-307a12d9e2a5ec302e44d29c5ba5ca4cf0f7ebff.zip Qt-307a12d9e2a5ec302e44d29c5ba5ca4cf0f7ebff.tar.gz Qt-307a12d9e2a5ec302e44d29c5ba5ca4cf0f7ebff.tar.bz2 |
Use the fallback icon theme name, if the system icon theme name can not be determined.
This restores the behavior from before the the gui plugin merge.
Reviewed-by: Olivier Goffart
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/image/qiconloader.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gui/image/qiconloader.cpp b/src/gui/image/qiconloader.cpp index e7620bd..46c5431 100644 --- a/src/gui/image/qiconloader.cpp +++ b/src/gui/image/qiconloader.cpp @@ -89,6 +89,8 @@ QIconLoader::QIconLoader() : m_themeKey(1), m_supportsSvg(false) { m_systemTheme = qt_guiPlatformPlugin()->systemIconThemeName(); + if (m_systemTheme.isEmpty()) + m_systemTheme = fallbackTheme(); QFactoryLoader iconFactoryLoader(QIconEngineFactoryInterfaceV2_iid, QLatin1String("/iconengines"), @@ -109,6 +111,8 @@ void QIconLoader::updateSystemTheme() // Only change if this is not explicitly set by the user if (m_userTheme.isEmpty()) { QString theme = qt_guiPlatformPlugin()->systemIconThemeName(); + if (theme.isEmpty()) + theme = fallbackTheme(); if (theme != m_systemTheme) { m_systemTheme = theme; invalidateKey(); |