diff --git a/capplets/common/ChangeLog b/capplets/common/ChangeLog index ac87602ca..196b77dc2 100644 --- a/capplets/common/ChangeLog +++ b/capplets/common/ChangeLog @@ -1,3 +1,10 @@ +2007-05-25 Jens Granseuer + + * gnome-theme-info.c: (read_icon_theme): + * gnome-theme-info.h: + add a "readable_name" property for icon themes, and make sure "name" + points to the internal theme name + 2007-05-25 Denis Washington * theme-thumbnail.c: diff --git a/capplets/common/gnome-theme-info.c b/capplets/common/gnome-theme-info.c index 793c41377..79692afb0 100644 --- a/capplets/common/gnome-theme-info.c +++ b/capplets/common/gnome-theme-info.c @@ -421,7 +421,7 @@ read_icon_theme (GnomeVFSURI *icon_theme_uri) { GnomeThemeIconInfo *icon_theme_info; GnomeDesktopItem *icon_theme_ditem; - char *icon_theme_file; + gchar *icon_theme_file; const gchar *name; const gchar *hidden_theme_icon; @@ -445,9 +445,13 @@ read_icon_theme (GnomeVFSURI *icon_theme_uri) if (hidden_theme_icon == NULL || strcmp (hidden_theme_icon, "false") == 0) { + gchar *dir_name; icon_theme_info = gnome_theme_icon_info_new (); - icon_theme_info->name = g_strdup (name); + icon_theme_info->readable_name = g_strdup (name); icon_theme_info->path = icon_theme_file; + dir_name = g_path_get_dirname (icon_theme_file); + icon_theme_info->name = g_path_get_basename (dir_name); + g_free (dir_name); } else { diff --git a/capplets/common/gnome-theme-info.h b/capplets/common/gnome-theme-info.h index 604ebe149..8c5bb605a 100644 --- a/capplets/common/gnome-theme-info.h +++ b/capplets/common/gnome-theme-info.h @@ -67,6 +67,7 @@ struct _GnomeThemeIconInfo { gchar *path; gchar *name; + gchar *readable_name; gint priority; };