[gtk+/gtk-style-context: 520/540] Check screen really changed before notifying it and invalidating the context
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/gtk-style-context: 520/540] Check screen really changed before notifying it and invalidating the context
- Date: Fri, 3 Dec 2010 03:19:49 +0000 (UTC)
commit 3720bbb80a094a95f1fc8659b3578eaa5cff2a0d
Author: Carlos Garcia Campos <cgarcia igalia com>
Date: Fri Nov 26 09:01:17 2010 +0100
Check screen really changed before notifying it and invalidating the context
gtk/gtkstylecontext.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/gtk/gtkstylecontext.c b/gtk/gtkstylecontext.c
index 2cee500..7e1dd2c 100644
--- a/gtk/gtkstylecontext.c
+++ b/gtk/gtkstylecontext.c
@@ -2556,8 +2556,12 @@ gtk_style_context_set_screen (GtkStyleContext *context,
GtkStyleContextPrivate *priv;
g_return_if_fail (GTK_IS_STYLE_CONTEXT (context));
+ g_return_if_fail (GDK_IS_SCREEN (screen));
priv = context->priv;
+ if (priv->screen == screen)
+ return;
+
priv->screen = screen;
g_object_notify (G_OBJECT (context), "screen");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]