If we are passed in a NULL just return rather than using g_return_if_fail
2006-01-26 Rodney Dawes <dobey@novell.com> * gnome-wp-capplet.c (gnome_wp_capplet_scroll_to_item): If we are passed in a NULL just return rather than using g_return_if_fail to do it, so that we can avoid the glib CRITICAL warning (#327327) (gnome_wp_load_stuffs): If the settings are mangled some how, and a valid item was not duplicated, duplicated the "No Wallpaper" item Fixes #327327
This commit is contained in:
parent
f69be2bd96
commit
0a696e12e8
2 changed files with 16 additions and 1 deletions
|
@ -1,3 +1,13 @@
|
||||||
|
2006-01-26 Rodney Dawes <dobey@novell.com>
|
||||||
|
|
||||||
|
* gnome-wp-capplet.c (gnome_wp_capplet_scroll_to_item): If we are
|
||||||
|
passed in a NULL just return rather than using g_return_if_fail to
|
||||||
|
do it, so that we can avoid the glib CRITICAL warning (#327327)
|
||||||
|
(gnome_wp_load_stuffs): If the settings are mangled some how, and
|
||||||
|
a valid item was not duplicated, duplicated the "No Wallpaper" item
|
||||||
|
|
||||||
|
Fixes #327327
|
||||||
|
|
||||||
2006-01-26 Rodney Dawes <dobey@novell.com>
|
2006-01-26 Rodney Dawes <dobey@novell.com>
|
||||||
|
|
||||||
* gnome-background-properties.glade: Add an Apply button
|
* gnome-background-properties.glade: Add an Apply button
|
||||||
|
|
|
@ -81,7 +81,9 @@ static void gnome_wp_capplet_scroll_to_item (GnomeWPCapplet * capplet,
|
||||||
GtkTreePath * path;
|
GtkTreePath * path;
|
||||||
|
|
||||||
g_return_if_fail (capplet != NULL);
|
g_return_if_fail (capplet != NULL);
|
||||||
g_return_if_fail (item != NULL);
|
|
||||||
|
if (item == NULL)
|
||||||
|
return;
|
||||||
|
|
||||||
path = gtk_tree_row_reference_get_path (item->rowref);
|
path = gtk_tree_row_reference_get_path (item->rowref);
|
||||||
gtk_tree_view_set_cursor (GTK_TREE_VIEW (capplet->treeview), path,
|
gtk_tree_view_set_cursor (GTK_TREE_VIEW (capplet->treeview), path,
|
||||||
|
@ -699,6 +701,9 @@ static gboolean gnome_wp_load_stuffs (void * data) {
|
||||||
g_slist_free (capplet->uri_list);
|
g_slist_free (capplet->uri_list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (capplet->old_item == NULL && item != NULL)
|
||||||
|
capplet->old_item = gnome_wp_item_dup (item);
|
||||||
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue