[Xfce4-commits] [xfce/xfwm4] 07/32: Handle gtk_button_set_alignment deprecation

noreply at xfce.org noreply at xfce.org
Tue Dec 5 09:21:53 CET 2017


This is an automated email from the git hooks/post-receive script.

o   l   i   v   i   e   r       p   u   s   h   e   d       a       c   o   m   m   i   t       t   o       b   r   a   n   c   h       m   a   s   t   e   r   
   in repository xfce/xfwm4.

commit efff6a64b3650d93501649edf3fbedea0f8f6f2f
Author: Viktor Odintsev <zakhams at gmail.com>
Date:   Thu Jun 29 18:28:20 2017 +0300

    Handle gtk_button_set_alignment deprecation
---
 settings-dialogs/xfwm4-settings.c | 13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/settings-dialogs/xfwm4-settings.c b/settings-dialogs/xfwm4-settings.c
index 83c6cb2..f590f7b 100644
--- a/settings-dialogs/xfwm4-settings.c
+++ b/settings-dialogs/xfwm4-settings.c
@@ -1525,6 +1525,8 @@ xfwm_settings_title_button_alignment_changed (GtkComboBox *combo,
   GtkTreeIter   iter;
   gchar        *value;
   float         align = 0.5f;
+  GList        *children;
+  GList        *citer;
 
   model = gtk_combo_box_get_model (combo);
   if (gtk_combo_box_get_active_iter (combo, &iter))
@@ -1539,7 +1541,16 @@ xfwm_settings_title_button_alignment_changed (GtkComboBox *combo,
       g_free (value);
     }
 
-  gtk_button_set_alignment (GTK_BUTTON (button), align, 0.5f);
+  children = gtk_container_get_children (GTK_CONTAINER (button));
+  for (citer = children; citer != NULL; citer = g_list_next (citer))
+    {
+      if (GTK_IS_LABEL (citer->data))
+        {
+          gtk_label_set_xalign (GTK_LABEL (citer->data), align);
+          break;
+        }
+    }
+  g_list_free (children);
 }
 
 

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Xfce4-commits mailing list