diff --git a/capplets/background/ChangeLog b/capplets/background/ChangeLog index d30bdb797..9febda558 100644 --- a/capplets/background/ChangeLog +++ b/capplets/background/ChangeLog @@ -1,3 +1,16 @@ +2006-08-18 Rodney Dawes + + * background.desktop.in.in: Use preferences-desktop-wallpaper as the + icon name per the Icon Naming Specification + * gnome-background-properties.glade: Set the icon name for the window + to be preferences-desktop-wallpaper as per the naming spec + * gnome-wp-capplet.[ch]: Remove GtkIconTheme instance from structure + (gnome_wp_icon_theme_changed): Don't need this method any longer + (wallpaper_properties_init): Remove unused variables + Don't need to get the icon_info to load a pixbuf and set an icon, from + the theme any longer, as we can just specify the icon with one call + Don't need the extra _ensure_style call here + 2006-08-18 Rodney Dawes * gnome-wp-capplet.c (wallpaper_properties_init): Set the content area diff --git a/capplets/background/background.desktop.in.in b/capplets/background/background.desktop.in.in index 600f4f6a2..6f2b0e0cc 100644 --- a/capplets/background/background.desktop.in.in +++ b/capplets/background/background.desktop.in.in @@ -3,7 +3,7 @@ Encoding=UTF-8 _Name=Desktop Background _Comment=Change your Desktop Background settings Exec=gnome-background-properties %F -Icon=gnome-settings-background +Icon=preferences-desktop-wallpaper Terminal=false Type=Application StartupNotify=true diff --git a/capplets/background/gnome-background-properties.glade b/capplets/background/gnome-background-properties.glade index 873a91c71..2bc8db3e3 100644 --- a/capplets/background/gnome-background-properties.glade +++ b/capplets/background/gnome-background-properties.glade @@ -14,6 +14,7 @@ 418 True False + preferences-desktop-wallpaper True False False diff --git a/capplets/background/gnome-wp-capplet.c b/capplets/background/gnome-wp-capplet.c index 64a7a3c0c..ffc671ced 100644 --- a/capplets/background/gnome-wp-capplet.c +++ b/capplets/background/gnome-wp-capplet.c @@ -786,23 +786,6 @@ static void gnome_wp_color2_changed (GConfClient * client, guint id, gnome_wp_color_changed (capplet, FALSE); } -static void gnome_wp_icon_theme_changed (GtkIconTheme * theme, - GnomeWPCapplet * capplet) { - GdkPixbuf * pixbuf; - GtkIconInfo * icon_info = NULL; - - icon_info = gtk_icon_theme_lookup_icon (capplet->theme, - "gnome-settings-background", - 48, 0); - if (icon_info != NULL) { - pixbuf = gtk_icon_info_load_icon (icon_info, NULL); - gtk_icon_info_free (icon_info); - gtk_window_set_icon (GTK_WINDOW (capplet->window), NULL); - gtk_window_set_default_icon (pixbuf); - g_object_unref (pixbuf); - } -} - static GladeXML * gnome_wp_create_dialog (void) { GladeXML * new; gchar * gladefile; @@ -860,10 +843,8 @@ static void wallpaper_properties_init (poptContext ctx) { GtkCellRenderer * renderer; GtkTreeViewColumn * column; GtkTreeSelection * selection; - GdkPixbuf * pixbuf; GdkCursor * cursor; const gchar ** args; - GtkIconInfo * icon_info = NULL; GtkFileFilter *filter; gtk_rc_parse_string ("style \"wp-tree-defaults\" {\n" @@ -914,29 +895,14 @@ static void wallpaper_properties_init (poptContext ctx) { gnome_wp_item_free); capplet->thumbs = gnome_thumbnail_factory_new (GNOME_THUMBNAIL_SIZE_NORMAL); - capplet->theme = gtk_icon_theme_get_default (); - - g_signal_connect (G_OBJECT (capplet->theme), "changed", - G_CALLBACK (gnome_wp_icon_theme_changed), capplet); dialog = gnome_wp_create_dialog (); capplet->window = glade_xml_get_widget (dialog, "gnome_wp_properties"); - icon_info = gtk_icon_theme_lookup_icon (capplet->theme, - "gnome-settings-background", - 48, 0); - if (icon_info != NULL) { - pixbuf = gtk_icon_info_load_icon (icon_info, NULL); - gtk_icon_info_free (icon_info); - gtk_window_set_default_icon (pixbuf); - gtk_window_set_icon (GTK_WINDOW (capplet->window), pixbuf); - g_object_unref (pixbuf); - } + gtk_window_set_default_icon_name ("preferences-desktop-wallpaper"); gtk_widget_realize (capplet->window); - gtk_widget_ensure_style (capplet->window); - /* Drag and Drop Support */ gtk_drag_dest_unset (capplet->window); gtk_drag_dest_set (capplet->window, GTK_DEST_DEFAULT_ALL, drop_types, diff --git a/capplets/background/gnome-wp-capplet.h b/capplets/background/gnome-wp-capplet.h index 30a005b8d..35a8b8da8 100644 --- a/capplets/background/gnome-wp-capplet.h +++ b/capplets/background/gnome-wp-capplet.h @@ -63,7 +63,6 @@ struct _GnomeWPCapplet { /* Thumbnailing and Icon Theme stuff */ GnomeThumbnailFactory * thumbs; - GtkIconTheme * theme; /* Hash Table of Wallpapers */ GHashTable * wphash;