[gtk+] GtkFileChooserWidget: derive from GtkBox, not GtkVBox



commit 88c6fc1d8468f98b95cd088da3dc3fda23377a8c
Author: Matthias Clasen <mclasen redhat com>
Date:   Tue Jun 7 18:36:22 2011 -0400

    GtkFileChooserWidget: derive from GtkBox, not GtkVBox

 gtk/gtkfilechooserwidget.c |    5 ++++-
 gtk/gtkfilechooserwidget.h |    6 +++---
 2 files changed, 7 insertions(+), 4 deletions(-)
---
diff --git a/gtk/gtkfilechooserwidget.c b/gtk/gtkfilechooserwidget.c
index 7969bff..7295e7b 100644
--- a/gtk/gtkfilechooserwidget.c
+++ b/gtk/gtkfilechooserwidget.c
@@ -26,6 +26,7 @@
 #include "gtkfilechooserutils.h"
 #include "gtktypebuiltins.h"
 #include "gtkfilechooserembed.h"
+#include "gtkorientable.h"
 #include "gtkintl.h"
 
 
@@ -63,7 +64,7 @@ static void     gtk_file_chooser_widget_get_property (GObject               *obj
 						      GValue                *value,
 						      GParamSpec            *pspec);
 
-G_DEFINE_TYPE_WITH_CODE (GtkFileChooserWidget, gtk_file_chooser_widget, GTK_TYPE_VBOX,
+G_DEFINE_TYPE_WITH_CODE (GtkFileChooserWidget, gtk_file_chooser_widget, GTK_TYPE_BOX,
 			 G_IMPLEMENT_INTERFACE (GTK_TYPE_FILE_CHOOSER,
 						_gtk_file_chooser_delegate_iface_init)
 			 G_IMPLEMENT_INTERFACE (GTK_TYPE_FILE_CHOOSER_EMBED,
@@ -91,6 +92,8 @@ gtk_file_chooser_widget_init (GtkFileChooserWidget *chooser_widget)
 								   GTK_TYPE_FILE_CHOOSER_WIDGET,
 								   GtkFileChooserWidgetPrivate);
   chooser_widget->priv = priv;
+  gtk_orientable_set_orientation (GTK_ORIENTABLE (chooser_widget),
+                                  GTK_ORIENTATION_VERTICAL);
 }
 
 static void
diff --git a/gtk/gtkfilechooserwidget.h b/gtk/gtkfilechooserwidget.h
index c7cea5f..2aaa199 100644
--- a/gtk/gtkfilechooserwidget.h
+++ b/gtk/gtkfilechooserwidget.h
@@ -26,7 +26,7 @@
 #define __GTK_FILE_CHOOSER_WIDGET_H__
 
 #include <gtk/gtkfilechooser.h>
-#include <gtk/gtkvbox.h>
+#include <gtk/gtkbox.h>
 
 G_BEGIN_DECLS
 
@@ -43,14 +43,14 @@ typedef struct _GtkFileChooserWidgetClass   GtkFileChooserWidgetClass;
 
 struct _GtkFileChooserWidget
 {
-  GtkVBox parent_instance;
+  GtkBox parent_instance;
 
   GtkFileChooserWidgetPrivate *priv;
 };
 
 struct _GtkFileChooserWidgetClass
 {
-  GtkVBoxClass parent_class;
+  GtkBoxClass parent_class;
 
   /* Padding for future expansion */
   void (*_gtk_reserved1) (void);



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