[gnome-bluetooth] lib: Fix widget orientation



commit 3335b3ce3ae31797dbf9ce7ea084ff2133f920de
Author: Bastien Nocera <hadess hadess net>
Date:   Sun Jun 26 11:59:00 2011 +0100

    lib: Fix widget orientation
    
    When not using the "_new()" function to instantiate one.

 lib/bluetooth-chooser.c       |    3 ++-
 lib/bluetooth-filter-widget.c |    3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/lib/bluetooth-chooser.c b/lib/bluetooth-chooser.c
index 4a02ccf..aa1528e 100644
--- a/lib/bluetooth-chooser.c
+++ b/lib/bluetooth-chooser.c
@@ -857,6 +857,8 @@ bluetooth_chooser_init(BluetoothChooser *self)
 
 	gtk_widget_push_composite_child ();
 
+	g_object_set (G_OBJECT (self), "orientation", GTK_ORIENTATION_VERTICAL, NULL);
+
 	priv->client = bluetooth_client_new ();
 
 	/* Setup the widget itself */
@@ -1250,7 +1252,6 @@ GtkWidget *
 bluetooth_chooser_new (const gchar *title)
 {
 	return g_object_new(BLUETOOTH_TYPE_CHOOSER,
-			    "orientation", GTK_ORIENTATION_VERTICAL,
 			    "title", title,
 			    NULL);
 }
diff --git a/lib/bluetooth-filter-widget.c b/lib/bluetooth-filter-widget.c
index fa2f087..65a2ea4 100644
--- a/lib/bluetooth-filter-widget.c
+++ b/lib/bluetooth-filter-widget.c
@@ -224,6 +224,8 @@ bluetooth_filter_widget_init(BluetoothFilterWidget *self)
 
 	gtk_widget_push_composite_child ();
 
+	g_object_set (G_OBJECT (self), "orientation", GTK_ORIENTATION_VERTICAL, NULL);
+
 	gtk_box_set_homogeneous (GTK_BOX (self), FALSE);
 	gtk_box_set_spacing (GTK_BOX (self), 6);
 
@@ -481,6 +483,5 @@ GtkWidget *
 bluetooth_filter_widget_new (void)
 {
 	return g_object_new(BLUETOOTH_TYPE_FILTER_WIDGET,
-			    "orientation", GTK_ORIENTATION_VERTICAL,
 			    NULL);
 }



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