diff options
author | Ken Moore <ken@ixsystems.com> | 2017-06-08 07:11:28 -0400 |
---|---|---|
committer | Ken Moore <ken@ixsystems.com> | 2017-06-08 07:11:28 -0400 |
commit | 2b4483a9f1c69d396139ac84efddd148a0060db1 (patch) | |
tree | 519c7788e47e4ee1962accf3d1f9ddb0d74f8cd2 /src-qt5/core/lumina-desktop | |
parent | Revert "Translated using Weblate (lumina_DESKTOP@en_gb (generated))" (diff) | |
download | lumina-2b4483a9f1c69d396139ac84efddd148a0060db1.tar.gz lumina-2b4483a9f1c69d396139ac84efddd148a0060db1.tar.bz2 lumina-2b4483a9f1c69d396139ac84efddd148a0060db1.zip |
Add the capability to be a bit smarter when determining a "fallback" icon for .desktop entries to be shown on the desktop. This fixes the icons for removeable USB drives on TrueOS, and might fix the icons for other .desktop files as well.
Diffstat (limited to 'src-qt5/core/lumina-desktop')
-rw-r--r-- | src-qt5/core/lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src-qt5/core/lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp b/src-qt5/core/lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp index 61293b46..f751441d 100644 --- a/src-qt5/core/lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp +++ b/src-qt5/core/lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp @@ -64,6 +64,7 @@ void AppLauncherPlugin::loadButton(){ }else{ button->setWhatsThis(file.filePath); if(ICONS->exists(file.icon)){ iconID = file.icon; } + else if(ICONS->exists(file.icon.section("-",0,-2)) ){ iconID = file.icon.section("-",0,-2); } //some icons get very specific with "-" delimiters, look for a more generic icon if possible else{ iconID = "system-run"; } //button->setIcon( QIcon(LXDG::findIcon(file.icon,"system-run").pixmap(QSize(icosize,icosize)).scaledToHeight(icosize, Qt::SmoothTransformation) ) ); if(!file.comment.isEmpty()){button->setToolTip(file.comment); } |