[gtk+/gtk-3-22] cssnodestylecache: Use const pointer in lookup



commit ec8192420e973cc6e00f1589034bab076eccbaab
Author: Timm Bäder <mail baedert org>
Date:   Tue Feb 28 08:23:19 2017 +0100

    cssnodestylecache: Use const pointer in lookup

 gtk/gtkcssnode.c                  |    2 +-
 gtk/gtkcssnodestylecache.c        |    8 ++++----
 gtk/gtkcssnodestylecacheprivate.h |    8 ++++----
 3 files changed, 9 insertions(+), 9 deletions(-)
---
diff --git a/gtk/gtkcssnode.c b/gtk/gtkcssnode.c
index 5be2806..f68c1e1 100644
--- a/gtk/gtkcssnode.c
+++ b/gtk/gtkcssnode.c
@@ -318,7 +318,7 @@ lookup_in_global_parent_cache (GtkCssNode                  *node,
 
   g_assert (node->cache == NULL);
   node->cache = gtk_css_node_style_cache_lookup (parent->cache,
-                                                 (GtkCssNodeDeclaration *) decl,
+                                                 decl,
                                                  gtk_css_node_is_first_child (node),
                                                  gtk_css_node_is_last_child (node));
   if (node->cache == NULL)
diff --git a/gtk/gtkcssnodestylecache.c b/gtk/gtkcssnodestylecache.c
index b07776d..c5d7562 100644
--- a/gtk/gtkcssnodestylecache.c
+++ b/gtk/gtkcssnodestylecache.c
@@ -163,10 +163,10 @@ gtk_css_node_style_cache_insert (GtkCssNodeStyleCache   *parent,
 }
 
 GtkCssNodeStyleCache *
-gtk_css_node_style_cache_lookup (GtkCssNodeStyleCache   *parent,
-                                 GtkCssNodeDeclaration  *decl,
-                                 gboolean                is_first,
-                                 gboolean                is_last)
+gtk_css_node_style_cache_lookup (GtkCssNodeStyleCache        *parent,
+                                 const GtkCssNodeDeclaration *decl,
+                                 gboolean                     is_first,
+                                 gboolean                     is_last)
 {
   GtkCssNodeStyleCache *result;
 
diff --git a/gtk/gtkcssnodestylecacheprivate.h b/gtk/gtkcssnodestylecacheprivate.h
index cef1ec2..f4d62b6 100644
--- a/gtk/gtkcssnodestylecacheprivate.h
+++ b/gtk/gtkcssnodestylecacheprivate.h
@@ -36,10 +36,10 @@ GtkCssNodeStyleCache *  gtk_css_node_style_cache_insert         (GtkCssNodeStyle
                                                                  gboolean                is_first,
                                                                  gboolean                is_last,
                                                                  GtkCssStyle            *style);
-GtkCssNodeStyleCache *  gtk_css_node_style_cache_lookup         (GtkCssNodeStyleCache   *parent,
-                                                                 GtkCssNodeDeclaration  *decl,
-                                                                 gboolean                is_first,
-                                                                 gboolean                is_last);
+GtkCssNodeStyleCache *  gtk_css_node_style_cache_lookup         (GtkCssNodeStyleCache        *parent,
+                                                                 const GtkCssNodeDeclaration *decl,
+                                                                 gboolean                     is_first,
+                                                                 gboolean                     is_last);
 
 G_END_DECLS
 


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