[balsa/stop-using-gtkbuttonbox: 30/40] mime-widget-message: Stop using GtkButtonBox




commit 6206bea821270e241bf92347050c4ab6ebfa2b76
Author: Peter Bloomfield <PeterBloomfield bellsouth net>
Date:   Fri Aug 28 18:42:09 2020 -0400

    mime-widget-message: Stop using GtkButtonBox

 src/balsa-mime-widget-message.c | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)
---
diff --git a/src/balsa-mime-widget-message.c b/src/balsa-mime-widget-message.c
index 10fe18644..f3a470ccd 100644
--- a/src/balsa-mime-widget-message.c
+++ b/src/balsa-mime-widget-message.c
@@ -479,6 +479,7 @@ bm_header_widget_new(BalsaMessage * bm, GtkWidget * const * buttons)
     GtkWidget *info_bar_widget;
     GtkInfoBar *info_bar;
     GtkWidget *content_area;
+    GtkWidget *vbox;
     GtkWidget *action_area;
     GtkWidget *widget;
     GtkEventController *key_controller;
@@ -501,23 +502,22 @@ bm_header_widget_new(BalsaMessage * bm, GtkWidget * const * buttons)
     content_area = gtk_info_bar_get_content_area(info_bar);
     gtk_container_add(GTK_CONTAINER(content_area), grid);
 
+    vbox = gtk_box_new(GTK_ORIENTATION_VERTICAL, 6);
+    gtk_widget_set_vexpand(vbox, TRUE);
+    gtk_widget_set_valign(vbox, GTK_ALIGN_START);
     action_area = gtk_info_bar_get_action_area(info_bar);
-    gtk_orientable_set_orientation(GTK_ORIENTABLE(action_area),
-                                   GTK_ORIENTATION_VERTICAL);
-    gtk_button_box_set_layout(GTK_BUTTON_BOX(action_area),
-                              GTK_BUTTONBOX_START);
+    gtk_container_add(GTK_CONTAINER(action_area), vbox);
+
     if (balsa_message_get_face_box(bm) == NULL) {
         GtkWidget *face_box = gtk_box_new(GTK_ORIENTATION_VERTICAL, 0);
 
         balsa_message_set_face_box(bm, face_box);
-        gtk_container_add(GTK_CONTAINER(action_area), face_box);
-        gtk_button_box_set_child_non_homogeneous(GTK_BUTTON_BOX(action_area),
-                                                 face_box, TRUE);
+        gtk_container_add(GTK_CONTAINER(vbox), face_box);
     }
 
     if (buttons) {
         while (*buttons) {
-            gtk_container_add(GTK_CONTAINER(action_area), *buttons++);
+            gtk_container_add(GTK_CONTAINER(vbox), *buttons++);
         }
     }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]