mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2025-01-13 22:10:08 +00:00
container: Remove reallocate_redraws
This commit is contained in:
parent
3e3eb0187a
commit
de65f87816
@ -900,7 +900,6 @@ gtk_container_check_resize
|
||||
gtk_container_foreach
|
||||
gtk_container_get_children
|
||||
gtk_container_get_path_for_child
|
||||
gtk_container_set_reallocate_redraws
|
||||
gtk_container_get_focus_child
|
||||
gtk_container_set_focus_child
|
||||
gtk_container_get_focus_vadjustment
|
||||
|
@ -281,7 +281,6 @@ struct _GtkContainerPrivate
|
||||
guint resize_handler;
|
||||
|
||||
guint has_focus_chain : 1;
|
||||
guint reallocate_redraws : 1;
|
||||
guint restyle_pending : 1;
|
||||
guint request_mode : 2;
|
||||
};
|
||||
@ -1603,7 +1602,6 @@ gtk_container_init (GtkContainer *container)
|
||||
priv = container->priv;
|
||||
|
||||
priv->focus_child = NULL;
|
||||
priv->reallocate_redraws = FALSE;
|
||||
}
|
||||
|
||||
static void
|
||||
@ -1706,27 +1704,6 @@ gtk_container_remove (GtkContainer *container,
|
||||
g_object_unref (container);
|
||||
}
|
||||
|
||||
/**
|
||||
* gtk_container_set_reallocate_redraws:
|
||||
* @container: a #GtkContainer
|
||||
* @needs_redraws: the new value for the container’s @reallocate_redraws flag
|
||||
*
|
||||
* Sets the @reallocate_redraws flag of the container to the given value.
|
||||
*
|
||||
* Containers requesting reallocation redraws get automatically
|
||||
* redrawn if any of their children changed allocation.
|
||||
*
|
||||
* Deprecated: 3.14: Call gtk_widget_queue_draw() in your size_allocate handler.
|
||||
**/
|
||||
void
|
||||
gtk_container_set_reallocate_redraws (GtkContainer *container,
|
||||
gboolean needs_redraws)
|
||||
{
|
||||
g_return_if_fail (GTK_IS_CONTAINER (container));
|
||||
|
||||
container->priv->reallocate_redraws = needs_redraws ? TRUE : FALSE;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
gtk_container_needs_idle_sizer (GtkContainer *container)
|
||||
{
|
||||
@ -3359,12 +3336,6 @@ gtk_container_propagate_draw (GtkContainer *container,
|
||||
cairo_restore (cr);
|
||||
}
|
||||
|
||||
gboolean
|
||||
_gtk_container_get_reallocate_redraws (GtkContainer *container)
|
||||
{
|
||||
return container->priv->reallocate_redraws;
|
||||
}
|
||||
|
||||
/**
|
||||
* gtk_container_get_path_for_child:
|
||||
* @container: a #GtkContainer
|
||||
|
@ -157,9 +157,6 @@ void gtk_container_unset_focus_chain (GtkContainer *container);
|
||||
|
||||
/* Widget-level methods */
|
||||
|
||||
GDK_DEPRECATED_IN_3_14
|
||||
void gtk_container_set_reallocate_redraws (GtkContainer *container,
|
||||
gboolean needs_redraws);
|
||||
GDK_AVAILABLE_IN_ALL
|
||||
void gtk_container_set_focus_child (GtkContainer *container,
|
||||
GtkWidget *child);
|
||||
|
@ -5599,14 +5599,6 @@ gtk_widget_size_allocate_with_baseline (GtkWidget *widget,
|
||||
}
|
||||
}
|
||||
|
||||
if ((size_changed || position_changed || baseline_changed) && priv->parent &&
|
||||
_gtk_widget_get_realized (priv->parent) && _gtk_container_get_reallocate_redraws (GTK_CONTAINER (priv->parent)))
|
||||
{
|
||||
cairo_region_t *invalidate = cairo_region_create_rectangle (&priv->parent->priv->clip);
|
||||
gtk_widget_invalidate_widget_windows (priv->parent, invalidate);
|
||||
cairo_region_destroy (invalidate);
|
||||
}
|
||||
|
||||
out:
|
||||
if (priv->alloc_needed_on_child)
|
||||
gtk_widget_ensure_allocate (widget);
|
||||
|
Loading…
Reference in New Issue
Block a user