Merge pull request #3156 from PrismLauncher/backport-3152-to-release-9.x
[Backport release-9.x] Fix system icons on Linux
This commit is contained in:
commit
cdfd0b1002
@ -1,7 +1,6 @@
|
||||
[Icon Theme]
|
||||
Name=Legacy
|
||||
Comment=Default Icons
|
||||
Inherits=default
|
||||
Directories=8x8,16x16,22x22,24x24,32x32,32x32/instances,48x48,50x50/instances,64x64,128x128/instances,256x256,scalable,scalable/instances
|
||||
|
||||
[8x8]
|
||||
|
@ -36,6 +36,8 @@
|
||||
|
||||
ThemeManager::ThemeManager()
|
||||
{
|
||||
QIcon::setFallbackThemeName(QIcon::themeName());
|
||||
QIcon::setFallbackSearchPaths(QIcon::themeSearchPaths());
|
||||
themeDebugLog() << "Determining System Widget Theme...";
|
||||
const auto& style = QApplication::style();
|
||||
m_defaultStyle = style->objectName();
|
||||
@ -93,9 +95,7 @@ void ThemeManager::initializeIcons()
|
||||
// set icon theme search path!
|
||||
themeDebugLog() << "<> Initializing Icon Themes";
|
||||
|
||||
auto searchPaths = QIcon::themeSearchPaths();
|
||||
searchPaths.append(m_iconThemeFolder.path());
|
||||
QIcon::setThemeSearchPaths(searchPaths);
|
||||
QIcon::setThemeSearchPaths({ m_iconThemeFolder.path(), ":/icons" });
|
||||
|
||||
for (const QString& id : builtinIcons) {
|
||||
IconTheme theme(id, QString(":/icons/%1").arg(id));
|
||||
|
Loading…
Reference in New Issue
Block a user