[gtk+/wip/cssvalue: 20/142] stylecontext: Introduce _gtk_style_context_queue_invalidate()



commit 02f53b0127932de7fbcb3f6ccb4b4dd5ce194480
Author: Benjamin Otte <otte redhat com>
Date:   Tue Mar 20 03:15:26 2012 +0100

    stylecontext: Introduce _gtk_style_context_queue_invalidate()
    
    This is for only queueing invalidations instead of doing a full
    invalidation cycle.

 gtk/gtkstylecontext.c        |   10 ++++++++++
 gtk/gtkstylecontextprivate.h |    2 ++
 2 files changed, 12 insertions(+), 0 deletions(-)
---
diff --git a/gtk/gtkstylecontext.c b/gtk/gtkstylecontext.c
index 6bbc6d6..1b27dfa 100644
--- a/gtk/gtkstylecontext.c
+++ b/gtk/gtkstylecontext.c
@@ -3208,6 +3208,16 @@ store_animation_region (GtkStyleContext *context,
     }
 }
 
+void
+_gtk_style_context_queue_invalidate (GtkStyleContext *context,
+                                     GtkCssChange     change)
+{
+  g_return_if_fail (GTK_IS_STYLE_CONTEXT (context));
+  g_return_if_fail (change != 0);
+
+  gtk_style_context_invalidate (context);
+}
+
 /**
  * gtk_style_context_invalidate:
  * @context: a #GtkStyleContext.
diff --git a/gtk/gtkstylecontextprivate.h b/gtk/gtkstylecontextprivate.h
index b35a3aa..41789cd 100644
--- a/gtk/gtkstylecontextprivate.h
+++ b/gtk/gtkstylecontextprivate.h
@@ -35,6 +35,8 @@ const GValue * _gtk_style_context_peek_style_property        (GtkStyleContext *c
                                                               GType            widget_type,
                                                               GtkStateFlags    state,
                                                               GParamSpec      *pspec);
+void           _gtk_style_context_queue_invalidate           (GtkStyleContext *context,
+                                                              GtkCssChange     change);
 void           _gtk_style_context_invalidate_animation_areas (GtkStyleContext *context);
 void           _gtk_style_context_coalesce_animation_areas   (GtkStyleContext *context,
                                                               GtkWidget       *widget);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]