]> Pileus Git - ~andy/gtk/commitdiff
Allow unsetting the custom image by passing NULL. (gtk_button_init):
authorMatthias Clasen <mclasen@redhat.com>
Sun, 2 Jan 2005 03:14:34 +0000 (03:14 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Sun, 2 Jan 2005 03:14:34 +0000 (03:14 +0000)
2005-01-01  Matthias Clasen  <mclasen@redhat.com>

* gtk/gtkbutton.c (gtk_button_set_image): Allow unsetting the
custom image by passing NULL.
(gtk_button_init): Initialize image_is_stock to TRUE, fixing
a problem with changing stock labels.  (#162273, Marcin
Krzyzanowski)

ChangeLog
ChangeLog.pre-2-10
ChangeLog.pre-2-6
ChangeLog.pre-2-8
gtk/gtkbutton.c

index c0d9171581568d6e24a5b1c62472ec2b25cf6ab8..eb3dac94dfcf15058e69be88770a82e0eed52af5 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2005-01-01  Matthias Clasen  <mclasen@redhat.com>
+
+       * gtk/gtkbutton.c (gtk_button_set_image): Allow unsetting the
+       custom image by passing NULL.
+       (gtk_button_init): Initialize image_is_stock to TRUE, fixing
+       a problem with changing stock labels.  (#162273, Marcin 
+       Krzyzanowski)
+
 2005-01-01  Tor Lillqvist  <tml@iki.fi>
 
        * gtk/gtkmodules.c (get_module_path)
index c0d9171581568d6e24a5b1c62472ec2b25cf6ab8..eb3dac94dfcf15058e69be88770a82e0eed52af5 100644 (file)
@@ -1,3 +1,11 @@
+2005-01-01  Matthias Clasen  <mclasen@redhat.com>
+
+       * gtk/gtkbutton.c (gtk_button_set_image): Allow unsetting the
+       custom image by passing NULL.
+       (gtk_button_init): Initialize image_is_stock to TRUE, fixing
+       a problem with changing stock labels.  (#162273, Marcin 
+       Krzyzanowski)
+
 2005-01-01  Tor Lillqvist  <tml@iki.fi>
 
        * gtk/gtkmodules.c (get_module_path)
index c0d9171581568d6e24a5b1c62472ec2b25cf6ab8..eb3dac94dfcf15058e69be88770a82e0eed52af5 100644 (file)
@@ -1,3 +1,11 @@
+2005-01-01  Matthias Clasen  <mclasen@redhat.com>
+
+       * gtk/gtkbutton.c (gtk_button_set_image): Allow unsetting the
+       custom image by passing NULL.
+       (gtk_button_init): Initialize image_is_stock to TRUE, fixing
+       a problem with changing stock labels.  (#162273, Marcin 
+       Krzyzanowski)
+
 2005-01-01  Tor Lillqvist  <tml@iki.fi>
 
        * gtk/gtkmodules.c (get_module_path)
index c0d9171581568d6e24a5b1c62472ec2b25cf6ab8..eb3dac94dfcf15058e69be88770a82e0eed52af5 100644 (file)
@@ -1,3 +1,11 @@
+2005-01-01  Matthias Clasen  <mclasen@redhat.com>
+
+       * gtk/gtkbutton.c (gtk_button_set_image): Allow unsetting the
+       custom image by passing NULL.
+       (gtk_button_init): Initialize image_is_stock to TRUE, fixing
+       a problem with changing stock labels.  (#162273, Marcin 
+       Krzyzanowski)
+
 2005-01-01  Tor Lillqvist  <tml@iki.fi>
 
        * gtk/gtkmodules.c (get_module_path)
index 5d2297efd4e1998c1f891999ee565f5fbf503559..7785863ed88c338c502f6ce1b74282f6f6bce642 100644 (file)
@@ -445,6 +445,7 @@ gtk_button_init (GtkButton *button)
   priv->xalign = 0.5;
   priv->yalign = 0.5;
   priv->align_set = 0;
+  priv->image_is_stock = TRUE;
 }
 
 static void
@@ -1757,7 +1758,7 @@ gtk_button_set_image (GtkButton *button,
   GtkButtonPrivate *priv = GTK_BUTTON_GET_PRIVATE (button);
 
   priv->image = image;
-  priv->image_is_stock = FALSE;
+  priv->image_is_stock = (image == NULL);
 
   gtk_button_construct_child (button);