* make the header icon hack somewhat work for maemo too
[modest] / src / maemo / modest-platform.c
index fc7caa5..0542ff8 100644 (file)
@@ -300,15 +300,31 @@ modest_platform_get_icon (const gchar *name)
 
        g_return_val_if_fail (name, NULL);
 
+       if (g_str_has_suffix (name, ".png")) { /*FIXME: hack*/
+               pixbuf = gdk_pixbuf_new_from_file (name, &err);
+               if (!pixbuf) {
+                       g_printerr ("modest: error loading icon '%s': %s\n",
+                                   name, err->message);
+                       g_error_free (err);
+                       return NULL;
+               }
+               return pixbuf;
+       }
+
        current_theme = gtk_icon_theme_get_default ();
        pixbuf = gtk_icon_theme_load_icon (current_theme, name, 26,
                                           GTK_ICON_LOOKUP_NO_SVG,
                                           &err);
        if (!pixbuf) {
-               g_printerr ("modest: error while loading icon '%s': %s\n",
+               g_printerr ("modest: error loading theme icon '%s': %s\n",
                            name, err->message);
                g_error_free (err);
-       }
-       
+       } 
        return pixbuf;
 }
+
+const gchar*
+modest_platform_get_app_name (void)
+{
+       return _("mcen_ap_name");
+}