[gtk+/nth-child: 5/22] css: Use new gtk_widget_path_iter_get_region_flags()
- From: Benjamin Otte <otte src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/nth-child: 5/22] css: Use new gtk_widget_path_iter_get_region_flags()
- Date: Thu, 26 May 2011 03:30:59 +0000 (UTC)
commit 195ffe6659ef88699961cd75ecfaa7698578a3ba
Author: Benjamin Otte <otte redhat com>
Date: Wed May 25 20:05:55 2011 +0200
css: Use new gtk_widget_path_iter_get_region_flags()
gtk/gtkcssselector.c | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
---
diff --git a/gtk/gtkcssselector.c b/gtk/gtkcssselector.c
index d0397a6..c88c4f5 100644
--- a/gtk/gtkcssselector.c
+++ b/gtk/gtkcssselector.c
@@ -186,12 +186,16 @@ gtk_css_selector_matches_type (const GtkCssSelector *selector,
const GtkWidgetPath *path,
guint id)
{
- if (selector->name == NULL)
- return TRUE;
+ GtkRegionFlags flags;
- if (selector->pseudo_classes)
+ flags = gtk_widget_path_iter_get_region_flags (path, id);
+
+ if ((selector->pseudo_classes & flags) != selector->pseudo_classes)
return FALSE;
+ if (selector->name == NULL)
+ return TRUE;
+
if (selector->type == G_TYPE_NONE)
return FALSE;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]