listbase: Sink adjustments

gtk_adjustment_new returns floating objects.
Sink them.

Fixes: #4403
This commit is contained in:
Matthias Clasen 2021-11-03 21:08:46 -04:00
parent c125ffb384
commit 3c2818b30a

View File

@ -1803,7 +1803,9 @@ gtk_list_base_init_real (GtkListBase *self,
priv->focus = gtk_list_item_tracker_new (priv->item_manager);
priv->adjustment[GTK_ORIENTATION_HORIZONTAL] = gtk_adjustment_new (0.0, 0.0, 0.0, 0.0, 0.0, 0.0);
g_object_ref_sink (priv->adjustment[GTK_ORIENTATION_HORIZONTAL]);
priv->adjustment[GTK_ORIENTATION_VERTICAL] = gtk_adjustment_new (0.0, 0.0, 0.0, 0.0, 0.0, 0.0);
g_object_ref_sink (priv->adjustment[GTK_ORIENTATION_VERTICAL]);
priv->orientation = GTK_ORIENTATION_VERTICAL;