[gtk+/wip/baedert/box: 199/234] widget: Remove push/pop_composite_child



commit ccd88282afddedf9269d2ff7084a4c075b595c33
Author: Timm Bäder <mail baedert org>
Date:   Wed Oct 12 20:01:31 2016 +0200

    widget: Remove push/pop_composite_child
    
    as well as the composite-child property

 docs/reference/gtk/gtk4-sections.txt |    2 -
 gtk/gtkwidget.c                      |   48 ----------------------------------
 gtk/gtkwidget.h                      |    9 ------
 gtk/gtkwidgetprivate.h               |    1 -
 4 files changed, 0 insertions(+), 60 deletions(-)
---
diff --git a/docs/reference/gtk/gtk4-sections.txt b/docs/reference/gtk/gtk4-sections.txt
index dc2a893..94b44ff 100644
--- a/docs/reference/gtk/gtk4-sections.txt
+++ b/docs/reference/gtk/gtk4-sections.txt
@@ -5111,8 +5111,6 @@ gtk_widget_get_font_map
 gtk_widget_create_pango_layout
 gtk_widget_render_icon
 gtk_widget_render_icon_pixbuf
-gtk_widget_pop_composite_child
-gtk_widget_push_composite_child
 gtk_widget_queue_draw_area
 gtk_widget_queue_draw_region
 gtk_widget_set_app_paintable
diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c
index f6274b6..2f2e548 100644
--- a/gtk/gtkwidget.c
+++ b/gtk/gtkwidget.c
@@ -575,7 +575,6 @@ enum {
   PROP_CAN_DEFAULT,
   PROP_HAS_DEFAULT,
   PROP_RECEIVES_DEFAULT,
-  PROP_COMPOSITE_CHILD,
   PROP_EVENTS,
   PROP_NO_SHOW_ALL,
   PROP_HAS_TOOLTIP,
@@ -802,7 +801,6 @@ static void gtk_widget_update_input_shape (GtkWidget *widget);
 static gint             GtkWidget_private_offset = 0;
 static gpointer         gtk_widget_parent_class = NULL;
 static guint            widget_signals[LAST_SIGNAL] = { 0 };
-static guint            composite_child_stack = 0;
 GtkTextDirection gtk_default_direction = GTK_TEXT_DIR_LTR;
 static GParamSpecPool  *style_property_spec_pool = NULL;
 
@@ -1199,13 +1197,6 @@ gtk_widget_class_init (GtkWidgetClass *klass)
                             FALSE,
                             GTK_PARAM_READWRITE|G_PARAM_EXPLICIT_NOTIFY);
 
-  widget_props[PROP_COMPOSITE_CHILD] =
-      g_param_spec_boolean ("composite-child",
-                            P_("Composite child"),
-                            P_("Whether the widget is part of a composite widget"),
-                            FALSE,
-                            GTK_PARAM_READABLE);
-
   widget_props[PROP_EVENTS] =
       g_param_spec_flags ("events",
                           P_("Events"),
@@ -3505,9 +3496,6 @@ gtk_widget_get_property (GObject         *object,
     case PROP_RECEIVES_DEFAULT:
       g_value_set_boolean (value, gtk_widget_get_receives_default (widget));
       break;
-    case PROP_COMPOSITE_CHILD:
-      g_value_set_boolean (value, widget->priv->composite_child);
-      break;
     case PROP_EVENTS:
       eventp = g_object_get_qdata (G_OBJECT (widget), quark_event_mask);
       g_value_set_flags (value, GPOINTER_TO_INT (eventp));
@@ -3915,7 +3903,6 @@ gtk_widget_init (GTypeInstance *instance, gpointer g_class)
   priv->parent = NULL;
 
   priv->sensitive = TRUE;
-  priv->composite_child = composite_child_stack != 0;
   priv->redraw_on_alloc = TRUE;
   priv->alloc_needed = TRUE;
   priv->alloc_needed_on_child = TRUE;
@@ -10434,41 +10421,6 @@ gtk_widget_is_ancestor (GtkWidget *widget,
   return FALSE;
 }
 
-/**
- * gtk_widget_push_composite_child:
- *
- * Makes all newly-created widgets as composite children until
- * the corresponding gtk_widget_pop_composite_child() call.
- *
- * A composite child is a child that’s an implementation detail of the
- * container it’s inside and should not be visible to people using the
- * container. Composite children aren’t treated differently by GTK+ (but
- * see gtk_container_foreach() vs. gtk_container_forall()), but e.g. GUI
- * builders might want to treat them in a different way.
- *
- * Deprecated: 3.10: This API never really worked well and was mostly unused, now
- * we have a more complete mechanism for composite children, see gtk_widget_class_set_template().
- **/
-void
-gtk_widget_push_composite_child (void)
-{
-  composite_child_stack++;
-}
-
-/**
- * gtk_widget_pop_composite_child:
- *
- * Cancels the effect of a previous call to gtk_widget_push_composite_child().
- *
- * Deprecated: 3.10: Use gtk_widget_class_set_template(), or don’t use this API at all.
- **/
-void
-gtk_widget_pop_composite_child (void)
-{
-  if (composite_child_stack)
-    composite_child_stack--;
-}
-
 static void
 gtk_widget_emit_direction_changed (GtkWidget        *widget,
                                    GtkTextDirection  old_dir)
diff --git a/gtk/gtkwidget.h b/gtk/gtkwidget.h
index 5102b2d..9d05b7e 100644
--- a/gtk/gtkwidget.h
+++ b/gtk/gtkwidget.h
@@ -1095,15 +1095,6 @@ GDK_AVAILABLE_IN_ALL
 PangoLayout  *gtk_widget_create_pango_layout  (GtkWidget   *widget,
                                               const gchar *text);
 
-/* Push/pop pairs, to change default values upon a widget's creation.
- * This will override the values that got set by the
- * gtk_widget_set_default_* () functions.
- */
-GDK_DEPRECATED_IN_3_10_FOR(gtk_widget_class_set_template)
-void        gtk_widget_push_composite_child (void);
-GDK_DEPRECATED_IN_3_10_FOR(gtk_widget_class_set_template)
-void        gtk_widget_pop_composite_child  (void);
-
 /* widget style properties
  */
 GDK_AVAILABLE_IN_ALL
diff --git a/gtk/gtkwidgetprivate.h b/gtk/gtkwidgetprivate.h
index 1fe2c03..a9fcb46 100644
--- a/gtk/gtkwidgetprivate.h
+++ b/gtk/gtkwidgetprivate.h
@@ -52,7 +52,6 @@ struct _GtkWidgetPrivate
   guint in_destruction        : 1;
   guint toplevel              : 1;
   guint anchored              : 1;
-  guint composite_child       : 1;
   guint no_window             : 1;
   guint realized              : 1;
   guint mapped                : 1;


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