Fix condition for finding icons without extension.
authorOleksandr Gavenko <gavenkoa@gmail.com>
Wed, 29 Aug 2012 11:35:22 +0300
changeset 521 20ee6c014cef
parent 520 af66efcdc75d
child 522 499d9a727fa1
Fix condition for finding icons without extension.
.fvwm/xdg2fvwm.py
--- a/.fvwm/xdg2fvwm.py	Wed Aug 29 11:28:35 2012 +0300
+++ b/.fvwm/xdg2fvwm.py	Wed Aug 29 11:35:22 2012 +0300
@@ -32,8 +32,7 @@
         elif isinstance(entry, xdg.Menu.MenuEntry):
             desktop = DesktopEntry(entry.DesktopEntry.getFileName())
             icon = desktop.getIcon()
-            icon_slash_idx = icon.rfind('/')
-            if icon_slash_idx == -1:
+            if icon.rfind('/') == -1 and icon.rfind('.') == -1:
                 icon = icon + ".png"
             cmd = desktop.getExec().rstrip('%FUfu')
             if icon == '':