From 7cd3da83002d7f98794e8e20a5c76d1bb7ee562c Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Sun, 2 Mar 2008 19:51:00 +0000 Subject: Check that the widget is a GtkButton before casting. 2008-03-03 Tor Lillqvist * modules/engines/ms-windows/msw_style.c (draw_box): Check that the widget is a GtkButton before casting. svn path=/trunk/; revision=19690 --- modules/engines/ms-windows/msw_style.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'modules') diff --git a/modules/engines/ms-windows/msw_style.c b/modules/engines/ms-windows/msw_style.c index aabf8f8e70..9c11b75bfc 100755 --- a/modules/engines/ms-windows/msw_style.c +++ b/modules/engines/ms-windows/msw_style.c @@ -2017,8 +2017,8 @@ draw_box (GtkStyle *style, } } else if (is_toolbar_child (widget->parent) - || (GTK_RELIEF_NONE == - gtk_button_get_relief (GTK_BUTTON (widget)))) + || (!GTK_IS_BUTTON (widget) || + (GTK_RELIEF_NONE == gtk_button_get_relief (GTK_BUTTON (widget))))) { if (draw_tool_button (window, widget, style, x, y, width, height, state_type, area)) -- cgit v1.2.1