forked from AuroraMiddleware/gtk
Drop the anchored field
We can just change priv->root instead.
This commit is contained in:
parent
5dd0863bd7
commit
a3901f2563
@ -3755,7 +3755,6 @@ gtk_widget_realize (GtkWidget *widget)
|
||||
GtkWidgetPrivate *priv = gtk_widget_get_instance_private (widget);
|
||||
|
||||
g_return_if_fail (GTK_IS_WIDGET (widget));
|
||||
g_return_if_fail (priv->anchored || GTK_IS_INVISIBLE (widget));
|
||||
|
||||
if (!_gtk_widget_get_realized (widget))
|
||||
{
|
||||
@ -5493,7 +5492,7 @@ gtk_widget_real_style_updated (GtkWidget *widget)
|
||||
if (has_text && gtk_css_style_change_affects (change, GTK_CSS_AFFECTS_TEXT))
|
||||
gtk_widget_update_pango_context (widget);
|
||||
|
||||
if (priv->anchored)
|
||||
if (priv->root)
|
||||
{
|
||||
if (gtk_css_style_change_affects (change, GTK_CSS_AFFECTS_SIZE) ||
|
||||
(has_text && gtk_css_style_change_affects (change, GTK_CSS_AFFECTS_TEXT_SIZE)))
|
||||
@ -5515,7 +5514,7 @@ gtk_widget_real_style_updated (GtkWidget *widget)
|
||||
{
|
||||
gtk_widget_update_pango_context (widget);
|
||||
|
||||
if (priv->anchored)
|
||||
if (priv->root)
|
||||
gtk_widget_queue_resize (widget);
|
||||
}
|
||||
}
|
||||
@ -11763,23 +11762,6 @@ gtk_widget_in_destruction (GtkWidget *widget)
|
||||
return priv->in_destruction;
|
||||
}
|
||||
|
||||
gboolean
|
||||
_gtk_widget_get_anchored (GtkWidget *widget)
|
||||
{
|
||||
GtkWidgetPrivate *priv = gtk_widget_get_instance_private (widget);
|
||||
|
||||
return priv->anchored;
|
||||
}
|
||||
|
||||
void
|
||||
_gtk_widget_set_anchored (GtkWidget *widget,
|
||||
gboolean anchored)
|
||||
{
|
||||
GtkWidgetPrivate *priv = gtk_widget_get_instance_private (widget);
|
||||
|
||||
priv->anchored = anchored;
|
||||
}
|
||||
|
||||
gboolean
|
||||
_gtk_widget_get_shadowed (GtkWidget *widget)
|
||||
{
|
||||
|
@ -58,7 +58,6 @@ struct _GtkWidgetPrivate
|
||||
#endif
|
||||
|
||||
guint in_destruction : 1;
|
||||
guint anchored : 1;
|
||||
guint no_surface : 1;
|
||||
guint no_surface_set : 1;
|
||||
guint realized : 1;
|
||||
@ -195,9 +194,6 @@ struct _GtkWidgetPrivate
|
||||
GtkCssNode * gtk_widget_get_css_node (GtkWidget *widget);
|
||||
void _gtk_widget_set_visible_flag (GtkWidget *widget,
|
||||
gboolean visible);
|
||||
gboolean _gtk_widget_get_anchored (GtkWidget *widget);
|
||||
void _gtk_widget_set_anchored (GtkWidget *widget,
|
||||
gboolean anchored);
|
||||
gboolean _gtk_widget_get_shadowed (GtkWidget *widget);
|
||||
void _gtk_widget_set_shadowed (GtkWidget *widget,
|
||||
gboolean shadowed);
|
||||
|
@ -1866,7 +1866,6 @@ gtk_window_init (GtkWindow *window)
|
||||
widget = GTK_WIDGET (window);
|
||||
|
||||
gtk_widget_set_has_surface (widget, TRUE);
|
||||
_gtk_widget_set_anchored (widget, TRUE);
|
||||
|
||||
priv->title = NULL;
|
||||
priv->wm_role = NULL;
|
||||
|
Loading…
Reference in New Issue
Block a user