graveman-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Graveman-cvs] Changes to graveman/current/src/images.c


From: sylvain cresto
Subject: [Graveman-cvs] Changes to graveman/current/src/images.c
Date: Fri, 29 Apr 2005 19:05:33 -0400

Index: graveman/current/src/images.c
diff -u graveman/current/src/images.c:1.13 graveman/current/src/images.c:1.14
--- graveman/current/src/images.c:1.13  Thu Apr 21 00:37:30 2005
+++ graveman/current/src/images.c       Fri Apr 29 23:05:29 2005
@@ -27,6 +27,7 @@
 
 
 GHashTable *Gimages = NULL;
+GHashTable *Ganimationpath = NULL;
 
 /*GdkPixbuf *GDirIcone, *GFileIcone, *GCDIcone, *GAudioIcone, *GCDRWIcone, 
*GCDpetiteIcone,
   *GCDRWpetiteIcone, *GpetiteGraver, *GGraver, *GISOpetiteIcone, *GEraseCdrw, 
*GFileImage,
@@ -34,34 +35,35 @@
   *GMenuAudio = NULL, *GMenuData = NULL, *GMenuCopy = NULL, *GMenuOther = 
NULL, *GMenuDvd = NULL;*/
 
 Timages Lotherimages[] = {
-    { "DirIcon",          "directory icon"     },
-    { "FileIcon",         "file icon"          },
-    { "FileImage",        "file image"         },
-    { "CDIcon",           "cd icon"            },
-    { "AudioIcon",        "audio icon"         },
-    { "CDRWIcon",         "cdrw icon"          },
-    { "CDRWsmallIcon",    "cdrw small icon"    },
-    { "DVDsmallIcon",     "dvd small icon"     },
-    { "DVDRWsmallIcon",   "dvdrw small icon"   },
-    { "CDsmallIcon",      "cd small icon"      },
-    { "ISOsmallIcon",     "iso small icon"     },
-    { "BurnsmallIcon",    "burn small icon"    },
-    { "BurnIcon",         "burn icon"          },
-    { "EraseCDRWIcon",    "erase cdrw icon"    },
-    { "CharsetSmallIcon", "charset small icon" },
-    { "OKIcon",           "ok icon"            },
-    { "BADIcon",          "bad icon"           },
-    { "WARNIcon",         "warning icon"       },
-    { "Themes",           "theme icon"         },
+    { "DirIcon",          "directory icon",      _IMG_PNG },
+    { "FileIcon",         "file icon",           _IMG_PNG },
+    { "FileImage",        "file image",          _IMG_PNG },
+    { "CDIcon",           "cd icon",             _IMG_PNG },
+    { "AudioIcon",        "audio icon",          _IMG_PNG },
+    { "CDRWIcon",         "cdrw icon",           _IMG_PNG },
+    { "CDRWsmallIcon",    "cdrw small icon",     _IMG_PNG },
+    { "DVDsmallIcon",     "dvd small icon",      _IMG_PNG },
+    { "DVDRWsmallIcon",   "dvdrw small icon",    _IMG_PNG },
+    { "CDsmallIcon",      "cd small icon",       _IMG_PNG },
+    { "ISOsmallIcon",     "iso small icon",      _IMG_PNG },
+    { "BurnsmallIcon",    "burn small icon",     _IMG_PNG },
+    { "BurnIcon",         "burn icon",           _IMG_PNG },
+    { "EraseCDRWIcon",    "erase cdrw icon",     _IMG_PNG },
+    { "CharsetSmallIcon", "charset small icon",  _IMG_PNG },
+    { "OKIcon",           "ok icon",             _IMG_PNG },
+    { "BADIcon",          "bad icon",            _IMG_PNG },
+    { "WARNIcon",         "warning icon",        _IMG_PNG },
+    { "Themes",           "theme icon",          _IMG_PNG },
+    { "Working",          "graveman animation",  _IMG_MNG },
     { NULL }
   };
 
 Timages Lmenuimages[] = {
-    { "Menu-Audio-",      "menu audio icon"    },
-    { "Menu-Data-",       "menu data icon"     },
-    { "Menu-Dvd-",        "menu dvd icon"      },
-    { "Menu-Copy-",       "menu copy icon"     },
-    { "Menu-Other-",      "menu other icon"    },
+    { "Menu-Audio-",      "menu audio icon",     _IMG_PNG },
+    { "Menu-Data-",       "menu data icon",      _IMG_PNG },
+    { "Menu-Dvd-",        "menu dvd icon",       _IMG_PNG },
+    { "Menu-Copy-",       "menu copy icon",      _IMG_PNG },
+    { "Menu-Other-",      "menu other icon",     _IMG_PNG },
     { NULL }
   };
 
@@ -76,14 +78,18 @@
   if (!Limagespath) return FALSE;
 
   Gimages = _hash();
+  Ganimationpath = _hash();
 
   for (Lcurimage = Lotherimages; Lcurimage->code; Lcurimage++) {
     Lpath = g_hash_table_lookup(Limagespath, Lcurimage->code);
     if (!Lpath) continue;
-    g_hash_table_insert(Gimages, Lcurimage->code, 
gdk_pixbuf_new_from_file((const gchar *)Lpath, NULL));
+    if (Lcurimage->type == _IMG_PNG) {
+      g_hash_table_insert(Gimages, Lcurimage->code, 
gdk_pixbuf_new_from_file((const gchar *)Lpath, NULL));
+      g_free(Lpath);
+    } else {
+      g_hash_table_insert(Ganimationpath, Lcurimage->code, Lpath);
+    }
     Laumoinsun = TRUE;
-
-    g_free(Lpath);
   }
 
   g_hash_table_destroy(Limagespath);
@@ -95,6 +101,11 @@
   return (GdkPixbuf *) g_hash_table_lookup(Gimages, Aident);
 }
 
+gchar *get_animation(gchar *Aident)
+{
+  return (gchar *) g_hash_table_lookup(Ganimationpath, Aident);
+}
+
 gboolean load_menu_images(gchar *Lquel) {
   Timages *Lcurimages;
   GdkPixbuf *Limg;




reply via email to

[Prev in Thread] Current Thread [Next in Thread]