summaryrefslogtreecommitdiff
path: root/gtk/gtktogglebutton.c
diff options
context:
space:
mode:
authorTim Janik <timj@gtk.org>2001-05-11 04:09:47 +0000
committerTim Janik <timj@src.gnome.org>2001-05-11 04:09:47 +0000
commit564e2235e9384b6984f43fa35cb141439b5bb27f (patch)
treef2b7cd2aefb889284fdb4465c356488ebffabc3b /gtk/gtktogglebutton.c
parent836e5f4a79821bc5385eb7974801160f046f1cb2 (diff)
downloadgtk+-564e2235e9384b6984f43fa35cb141439b5bb27f.tar.gz
don't propagate exposes to NULL child.
Fri May 11 02:53:57 2001 Tim Janik <timj@gtk.org> * gtk/gtktogglebutton.c (gtk_toggle_button_expose): don't propagate exposes to NULL child. * gtk/gtkscrolledwindow.c (gtk_scrolled_window_adjustment_changed): guard against not having one of the scrollbars. * gtk/gtklabel.c (gtk_label_setup_mnemonic): clean up after us, we don't keep a mnemonic window if we have no mnemonic installed.
Diffstat (limited to 'gtk/gtktogglebutton.c')
-rw-r--r--gtk/gtktogglebutton.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/gtk/gtktogglebutton.c b/gtk/gtktogglebutton.c
index b4af1af243..46cc40d93a 100644
--- a/gtk/gtktogglebutton.c
+++ b/gtk/gtktogglebutton.c
@@ -466,11 +466,12 @@ gtk_toggle_button_expose (GtkWidget *widget,
{
if (GTK_WIDGET_DRAWABLE (widget))
{
+ GtkWidget *child = GTK_BIN (widget)->child;
+
gtk_toggle_button_paint (widget, &event->area);
-
- gtk_container_propagate_expose (GTK_CONTAINER (widget),
- GTK_BIN (widget)->child,
- event);
+
+ if (child)
+ gtk_container_propagate_expose (GTK_CONTAINER (widget), child, event);
}
return TRUE;