summaryrefslogtreecommitdiff
path: root/gtk/gtktreeview.c
diff options
context:
space:
mode:
authorBenjamin Otte <otte@redhat.com>2014-06-19 20:00:16 +0200
committerBenjamin Otte <otte@redhat.com>2014-06-19 22:26:51 +0200
commitd80bf0790d0903ba2825f306b6f7435529f922e2 (patch)
tree290d028097851cb343496b21c6922806d01d3fdd /gtk/gtktreeview.c
parent8451b15d6ec9f181ccc716c87c1fee66a402db21 (diff)
downloadgtk+-d80bf0790d0903ba2825f306b6f7435529f922e2.tar.gz
stylecontext: Deprecate regions
Regions are done in a very non-css way. They don't fit the DOM in that they don't integrate into the CSS tree and they have very weird matching behavior in selectors. So I'm deprecating them now. GtkNotebook and GtkTreeview will continue to use them and as long as they do, we can't remove the code for it. But once those are ported it might be safe to remove the code as it will clean up lots of places in the code by quite a bit.
Diffstat (limited to 'gtk/gtktreeview.c')
-rw-r--r--gtk/gtktreeview.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/gtk/gtktreeview.c b/gtk/gtktreeview.c
index 825279ffe4..83537c9d34 100644
--- a/gtk/gtktreeview.c
+++ b/gtk/gtktreeview.c
@@ -5188,8 +5188,10 @@ gtk_tree_view_bin_draw (GtkWidget *widget,
gtk_style_context_set_state (context, state);
gtk_style_context_add_class (context, GTK_STYLE_CLASS_CELL);
+G_GNUC_BEGIN_IGNORE_DEPRECATIONS
gtk_style_context_add_region (context, GTK_STYLE_REGION_ROW, row_flags);
gtk_style_context_add_region (context, GTK_STYLE_REGION_COLUMN, column_flags);
+G_GNUC_END_IGNORE_DEPRECATIONS
if (node == tree_view->priv->cursor_node && has_can_focus_cell
&& ((column == tree_view->priv->focus_column
@@ -14574,7 +14576,9 @@ gtk_tree_view_create_row_drag_icon (GtkTreeView *tree_view,
context = gtk_widget_get_style_context (widget);
gtk_style_context_save (context);
+G_GNUC_BEGIN_IGNORE_DEPRECATIONS
gtk_style_context_add_region (context, GTK_STYLE_REGION_COLUMN, 0);
+G_GNUC_END_IGNORE_DEPRECATIONS
gtk_widget_style_get (widget,
"allow-rules", &allow_rules,
@@ -14589,7 +14593,9 @@ gtk_tree_view_create_row_drag_icon (GtkTreeView *tree_view,
else
row_flags = GTK_REGION_EVEN;
+G_GNUC_BEGIN_IGNORE_DEPRECATIONS
gtk_style_context_add_region (context, GTK_STYLE_REGION_ROW, row_flags);
+G_GNUC_END_IGNORE_DEPRECATIONS
}
is_separator = row_is_separator (tree_view, &iter, NULL);