summaryrefslogtreecommitdiff
path: root/gtk/gtkcssselectorprivate.h
diff options
context:
space:
mode:
authorBenjamin Otte <otte@redhat.com>2020-01-27 03:26:39 +0100
committerBenjamin Otte <otte@redhat.com>2020-01-28 02:17:03 +0100
commit495eaf31d40d12604ba62bb388c05081796f6a2c (patch)
treed5a801cfc78e77438cf56e6201bf5b4161fbffdf /gtk/gtkcssselectorprivate.h
parentccdc3ee40654b44989e60d8e728aa2096f539673 (diff)
downloadgtk+-495eaf31d40d12604ba62bb388c05081796f6a2c.tar.gz
css: Use the bloom filter for change matching
Instead of just doing radical change matching on the node itself, also consider the parent nodes via the bloom filter. This means a radical change is now also one where the parent name/id/classes change, but since that's considered a radical change on the parent already, those things are slow anyway. Improves the benchmark times for CSS validation during backdrop transitions in widget-factory from 45ms to 35ms on my machine.
Diffstat (limited to 'gtk/gtkcssselectorprivate.h')
-rw-r--r--gtk/gtkcssselectorprivate.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/gtk/gtkcssselectorprivate.h b/gtk/gtkcssselectorprivate.h
index a1e265d5d2..4d8e39f376 100644
--- a/gtk/gtkcssselectorprivate.h
+++ b/gtk/gtkcssselectorprivate.h
@@ -45,7 +45,8 @@ void _gtk_css_selector_tree_free (GtkCssSelectorTree *
GPtrArray * _gtk_css_selector_tree_match_all (const GtkCssSelectorTree *tree,
const GtkCountingBloomFilter *filter,
GtkCssNode *node);
-GtkCssChange _gtk_css_selector_tree_get_change_all (const GtkCssSelectorTree *tree,
+GtkCssChange gtk_css_selector_tree_get_change_all (const GtkCssSelectorTree *tree,
+ const GtkCountingBloomFilter *filter,
GtkCssNode *node);
void _gtk_css_selector_tree_match_print (const GtkCssSelectorTree *tree,
GString *str);