diff options
author | Bruno Coudoin <bcoudoin@src.gnome.org> | 2006-10-15 02:56:45 (GMT) |
---|---|---|
committer | Bruno Coudoin <bcoudoin@src.gnome.org> | 2006-10-15 02:56:45 (GMT) |
commit | 6470b304ec68f6d2c6b705f1c938211dab99dfda (patch) | |
tree | b1151053857df2adbd1c801ff5be9fbe5817ad22 /src/gcompris/bar.c | |
parent | b232d93bddff0d6fec3e3c90933b316fe5e2b490 (diff) |
*** RELEASE 8.1 ***
- Fixed a major crash case on images with a focus and a changing image
like the level icon.
Diffstat (limited to 'src/gcompris/bar.c')
-rw-r--r-- | src/gcompris/bar.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gcompris/bar.c b/src/gcompris/bar.c index 91a2797..b4ddc9a 100644 --- a/src/gcompris/bar.c +++ b/src/gcompris/bar.c @@ -296,8 +296,9 @@ void gc_bar_set_level(GcomprisBoard *gcomprisBoard) pixmap = gc_skin_pixmap_load(str); g_free(str); - /* Warning changing the image needs to update pixbuf_ref for the focus usage */ - g_object_set_data (G_OBJECT (level_item), "pixbuf_ref", pixmap); + /* Warning changing the image needs to free the focus first */ + gc_item_focus_free(level_item, NULL); + gnome_canvas_item_set (level_item, "pixbuf", pixmap, NULL); @@ -322,7 +323,7 @@ void gc_bar_set_repeat_icon (GdkPixbuf *pixmap) { /* Warning changing the image needs to update pixbuf_ref for the focus usage */ - g_object_set_data (G_OBJECT (repeat_item), "pixbuf_ref", pixmap); + gc_item_focus_free(repeat_item, NULL); gnome_canvas_item_set (repeat_item, "pixbuf", pixmap, NULL); |