diff options
author | Benjamin Otte <otte@redhat.com> | 2018-04-10 22:20:10 +0200 |
---|---|---|
committer | Benjamin Otte <otte@redhat.com> | 2018-04-11 03:16:34 +0200 |
commit | 3ee2aa1b22c65fe09e4145cf86bdd28831ef68b9 (patch) | |
tree | 3d22847161e1aedc37848c31b31bba24e5421c59 /gtk/gtkcontainer.c | |
parent | 21f15094fb41dacae405ca8f89d352e3320be5bd (diff) | |
download | gtk+-3ee2aa1b22c65fe09e4145cf86bdd28831ef68b9.tar.gz |
container: Remove gtk_container_maybe_start_idle_sizer()
Fold it into gtk_container_start_idle_sizer()
Diffstat (limited to 'gtk/gtkcontainer.c')
-rw-r--r-- | gtk/gtkcontainer.c | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/gtk/gtkcontainer.c b/gtk/gtkcontainer.c index 8beec75ca1..888d9d59d2 100644 --- a/gtk/gtkcontainer.c +++ b/gtk/gtkcontainer.c @@ -1590,7 +1590,7 @@ gtk_container_idle_sizer (GdkFrameClock *clock, if (!gtk_container_needs_idle_sizer (container)) { - _gtk_container_stop_idle_sizer (container); + gtk_container_stop_idle_sizer (container); } else { @@ -1599,7 +1599,7 @@ gtk_container_idle_sizer (GdkFrameClock *clock, } } -static void +void gtk_container_start_idle_sizer (GtkContainer *container) { GtkContainerPrivate *priv = gtk_container_get_instance_private (container); @@ -1608,6 +1608,9 @@ gtk_container_start_idle_sizer (GtkContainer *container) if (priv->resize_handler != 0) return; + if (!gtk_container_needs_idle_sizer (container)) + return; + clock = gtk_widget_get_frame_clock (GTK_WIDGET (container)); if (clock == NULL) return; @@ -1619,7 +1622,7 @@ gtk_container_start_idle_sizer (GtkContainer *container) } void -_gtk_container_stop_idle_sizer (GtkContainer *container) +gtk_container_stop_idle_sizer (GtkContainer *container) { GtkContainerPrivate *priv = gtk_container_get_instance_private (container); @@ -1632,13 +1635,6 @@ _gtk_container_stop_idle_sizer (GtkContainer *container) } void -_gtk_container_maybe_start_idle_sizer (GtkContainer *container) -{ - if (gtk_container_needs_idle_sizer (container)) - gtk_container_start_idle_sizer (container); -} - -void _gtk_container_queue_restyle (GtkContainer *container) { GtkContainerPrivate *priv = gtk_container_get_instance_private (container); @@ -1649,7 +1645,7 @@ _gtk_container_queue_restyle (GtkContainer *container) return; priv->restyle_pending = TRUE; - _gtk_container_maybe_start_idle_sizer (container); + gtk_container_start_idle_sizer (container); } void |