summaryrefslogtreecommitdiff
path: root/gtk/inspector/misc-info.c
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2020-05-05 11:57:49 -0400
committerMatthias Clasen <mclasen@redhat.com>2020-05-06 14:27:45 -0400
commit92bcf4c7a7c783b4cc01c8371e340efbea1b2e9e (patch)
tree9d64f070866ef626225f1c0b8cacb97244c8e4da /gtk/inspector/misc-info.c
parentb21a027d102022b84b40c4f749055033a225e1e4 (diff)
downloadgtk+-92bcf4c7a7c783b4cc01c8371e340efbea1b2e9e.tar.gz
inspector: Stop using ::size-allocate
This signal is going away. Currently, there is no other way for the inspector to monitor the allocation.
Diffstat (limited to 'gtk/inspector/misc-info.c')
-rw-r--r--gtk/inspector/misc-info.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/gtk/inspector/misc-info.c b/gtk/inspector/misc-info.c
index 659960d7b8..7810854941 100644
--- a/gtk/inspector/misc-info.c
+++ b/gtk/inspector/misc-info.c
@@ -139,11 +139,8 @@ state_flags_changed (GtkWidget *w, GtkStateFlags old_flags, GtkInspectorMiscInfo
}
static void
-allocation_changed (GtkWidget *w,
- int width,
- int height,
- int baseline,
- GtkInspectorMiscInfo *sl)
+update_allocation (GtkWidget *w,
+ GtkInspectorMiscInfo *sl)
{
GtkAllocation alloc;
gchar *size_label;
@@ -419,7 +416,6 @@ gtk_inspector_misc_info_set_object (GtkInspectorMiscInfo *sl,
if (sl->priv->object)
{
g_signal_handlers_disconnect_by_func (sl->priv->object, state_flags_changed, sl);
- g_signal_handlers_disconnect_by_func (sl->priv->object, allocation_changed, sl);
disconnect_each_other (sl->priv->object, G_OBJECT (sl));
disconnect_each_other (sl, sl->priv->object);
sl->priv->object = NULL;
@@ -452,8 +448,7 @@ gtk_inspector_misc_info_set_object (GtkInspectorMiscInfo *sl,
g_signal_connect_object (object, "state-flags-changed", G_CALLBACK (state_flags_changed), sl, 0);
state_flags_changed (GTK_WIDGET (sl->priv->object), 0, sl);
- g_signal_connect_object (object, "size-allocate", G_CALLBACK (allocation_changed), sl, 0);
- allocation_changed (GTK_WIDGET (sl->priv->object), 0, 0, -1, sl);
+ update_allocation (GTK_WIDGET (sl->priv->object), sl);
}
else
{