summaryrefslogtreecommitdiff
path: root/gtk/gtkcalendar.c
diff options
context:
space:
mode:
authorBenjamin Otte <otte@redhat.com>2016-11-22 19:31:03 +0100
committerBenjamin Otte <lvs@localhost.localdomain>2016-11-23 18:48:38 +0100
commit4850271ae81f346fb508692f6939c0c2c5883452 (patch)
treed0931c79656e98ea11300a1362eba73447f14607 /gtk/gtkcalendar.c
parentb7869c65a858a52632f9eae3c5f98bdce84fa375 (diff)
downloadgtk+-4850271ae81f346fb508692f6939c0c2c5883452.tar.gz
API: Remove gtk_cairo_should_draw_window()
The answer is: Yes.
Diffstat (limited to 'gtk/gtkcalendar.c')
-rw-r--r--gtk/gtkcalendar.c26
1 files changed, 11 insertions, 15 deletions
diff --git a/gtk/gtkcalendar.c b/gtk/gtkcalendar.c
index 24f34a34ca..e8cdc6d6f4 100644
--- a/gtk/gtkcalendar.c
+++ b/gtk/gtkcalendar.c
@@ -2742,26 +2742,22 @@ gtk_calendar_draw (GtkWidget *widget,
{
GtkCalendar *calendar = GTK_CALENDAR (widget);
GtkCalendarPrivate *priv = calendar->priv;
+ GtkStyleContext *context;
int i;
- if (gtk_cairo_should_draw_window (cr, gtk_widget_get_window (widget)))
- {
- GtkStyleContext *context;
-
- context = gtk_widget_get_style_context (widget);
+ context = gtk_widget_get_style_context (widget);
- gtk_style_context_save (context);
- gtk_style_context_add_class (context, GTK_STYLE_CLASS_VIEW);
+ gtk_style_context_save (context);
+ gtk_style_context_add_class (context, GTK_STYLE_CLASS_VIEW);
- gtk_render_background (context, cr, 0, 0,
- gtk_widget_get_allocated_width (widget),
- gtk_widget_get_allocated_height (widget));
- gtk_render_frame (context, cr, 0, 0,
- gtk_widget_get_allocated_width (widget),
- gtk_widget_get_allocated_height (widget));
+ gtk_render_background (context, cr, 0, 0,
+ gtk_widget_get_allocated_width (widget),
+ gtk_widget_get_allocated_height (widget));
+ gtk_render_frame (context, cr, 0, 0,
+ gtk_widget_get_allocated_width (widget),
+ gtk_widget_get_allocated_height (widget));
- gtk_style_context_restore (context);
- }
+ gtk_style_context_restore (context);
calendar_paint_main (calendar, cr);