]> Pileus Git - ~andy/gtk/commitdiff
Use gtk_render_activity() when rendering progressbars through GtkStyle
authorCarlos Garnacho <carlosg@gnome.org>
Sun, 21 Nov 2010 18:38:07 +0000 (19:38 +0100)
committerCarlos Garnacho <carlosg@gnome.org>
Sat, 4 Dec 2010 14:39:23 +0000 (15:39 +0100)
gtk/gtkstyle.c

index eaa0a256faf3b58cce477f0a8ed7d41203d5c6e3..482cdf449a106aea1b7396d5ca0800cbb08ad119 100644 (file)
@@ -2540,8 +2540,13 @@ gtk_default_draw_box (GtkStyle      *style,
 
   cairo_save (cr);
 
-  gtk_render_background (context, cr, x, y, width, height);
-  gtk_render_frame (context, cr, x, y, width, height);
+  if (gtk_style_context_has_class (context, GTK_STYLE_CLASS_PROGRESSBAR))
+    gtk_render_activity (context, cr, x, y, width, height);
+  else
+    {
+      gtk_render_background (context, cr, x, y, width, height);
+      gtk_render_frame (context, cr, x, y, width, height);
+    }
 
   cairo_restore (cr);
   gtk_style_context_restore (context);