wineshelllink: Remove hardcoded icon file extension.

Vitaliy Margolen wine-patch at kievinfo.com
Mon Jan 16 10:13:51 CST 2006


ChangeLog:
wineshelllink: Remove hardcoded icon file extension.

 tools/wineshelllink |    8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)
-------------- next part --------------
b650630fbd861a6a3193ab1cb3388a6118fd5ca1
diff --git a/tools/wineshelllink b/tools/wineshelllink
index 6dc0233..f47234f 100755
--- a/tools/wineshelllink
+++ b/tools/wineshelllink
@@ -133,8 +133,9 @@ copy_icon()
   mkdir -p "$dir/""`dirname "$link"`" || true
   if [ -f "$icon" ]
   then
-    cp "$icon" "$dir/$link.xpm"
-    xpmicon="$dir/$link.xpm"
+    ext=`echo $icon | sed "s/.*\.//"`
+    cp "$icon" "$dir/$link.$ext"
+    xpmicon="$dir/$link.$ext"
   else
     xpmicon=""
   fi
@@ -145,7 +146,8 @@ copy_icon()
 type update-menus > /dev/null 2>&1
 if [ $? = 0 -a $mode = "menu" ]
 then
-  iconname="`basename "$link"`.xpm"
+  ext=`echo $icon | sed "s/.*\.//"`
+  iconname="`basename "$link"`.$ext"
   dir="$HOME/.menu/icons"
   if [ -f "$icon" ]
   then


More information about the wine-patches mailing list