summaryrefslogtreecommitdiff
path: root/libmate-desktop
diff options
context:
space:
mode:
Diffstat (limited to 'libmate-desktop')
-rw-r--r--libmate-desktop/mate-colorbutton.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/libmate-desktop/mate-colorbutton.c b/libmate-desktop/mate-colorbutton.c
index ff62e16..2f65e64 100644
--- a/libmate-desktop/mate-colorbutton.c
+++ b/libmate-desktop/mate-colorbutton.c
@@ -257,26 +257,24 @@ mate_color_button_get_checkered (void)
}
/* Handle exposure events for the color picker's drawing area */
-#if GTK_CHECK_VERSION (3, 0, 0)
static gboolean
+#if GTK_CHECK_VERSION (3, 0, 0)
draw (GtkWidget *widget,
cairo_t *cr,
gpointer data)
#else
-static gint
expose_event (GtkWidget *widget,
GdkEventExpose *event,
gpointer data)
#endif
{
MateColorButton *color_button = MATE_COLOR_BUTTON (data);
- GtkAllocation allocation;
cairo_pattern_t *checkered;
-#if !GTK_CHECK_VERSION (3, 0, 0)
- cairo_t *cr;
- cr = gdk_cairo_create (event->window);
+#if !GTK_CHECK_VERSION (3, 0, 0)
+ cairo_t *cr = gdk_cairo_create (event->window);
+ GtkAllocation allocation;
gtk_widget_get_allocation (widget, &allocation);
gdk_cairo_rectangle (cr, &allocation);
cairo_clip (cr);