diff options
author | kotontrion <[email protected]> | 2024-11-26 09:44:39 +0100 |
---|---|---|
committer | kotontrion <[email protected]> | 2024-11-26 09:44:39 +0100 |
commit | 361fe5d1937bf2220e7e35a7e26fbd2a6b0a2d83 (patch) | |
tree | e299b70e648ec757a66f91041c9a8c25ab352905 /lib | |
parent | 60e0dfc945616d739c1acdf93f9e2c55dc505638 (diff) |
tray: workaround for icon name as path
Diffstat (limited to 'lib')
-rw-r--r-- | lib/tray/trayItem.vala | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/tray/trayItem.vala b/lib/tray/trayItem.vala index be221bf..d1de0c3 100644 --- a/lib/tray/trayItem.vala +++ b/lib/tray/trayItem.vala @@ -239,7 +239,10 @@ public class TrayItem : Object { private void update_gicon() { if(icon_name != null && icon_name != "") { - if(icon_theme_path != null && icon_theme_path != "") { + if(GLib.FileUtils.test(icon_name, GLib.FileTest.EXISTS)) { + gicon = new GLib.FileIcon(GLib.File.new_for_path(icon_name)); + } + else if(icon_theme_path != null && icon_theme_path != "") { gicon = new GLib.FileIcon(GLib.File.new_for_path( find_icon_in_theme(icon_name, icon_theme_path))); } else { |