Alert: fix for traceback in the draw - SL #4251

The Gtk.StyleContext get_background_color method needs a
Gtk.StateFlags as a parameter.  Feeding it with a GtkStateType doesn't
work anymore in recent gtk+.

Signed-off-by: Manuel Quiñones <manuq@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
This commit is contained in:
Manuel Quiñones 2012-11-20 15:46:33 -03:00
parent 936ebaa382
commit 9c230ea498

View File

@ -370,7 +370,7 @@ class _TimeoutIcon(Gtk.Alignment):
radius = w / 2 radius = w / 2
context.arc(x, y, radius, 0, 2 * math.pi) context.arc(x, y, radius, 0, 2 * math.pi)
widget_style = self.get_style_context() widget_style = self.get_style_context()
color = widget_style.get_background_color(self.get_state()) color = widget_style.get_background_color(self.get_state_flags())
context.set_source_rgb(color.red, color.green, color.blue) context.set_source_rgb(color.red, color.green, color.blue)
context.fill_preserve() context.fill_preserve()