- if (style & wxSL_VERTICAL)
- m_widget = gtk_hbox_new(false, 0);
- else
- m_widget = gtk_vbox_new(false, 0);
- g_object_ref(m_widget);
- gtk_widget_show( m_widget );
- gtk_container_add( GTK_CONTAINER(m_widget), m_scale );
-
- GtkWidget *box;
- if (style & wxSL_VERTICAL)
- box = gtk_vbox_new(false,0);
- else
- box = gtk_hbox_new(false,0);
- g_object_ref(box);
+ m_widget = gtk_box_new(GtkOrientation(!isVertical), 0);
+ gtk_box_pack_start(GTK_BOX(m_widget), m_scale, true, true, 0);
+
+ GtkWidget* box = gtk_box_new(GtkOrientation(isVertical), 0);