]> Pileus Git - ~andy/gtk/blobdiff - examples/radiobuttons/radiobuttons.c
Use gtk_box_new() instead gtk_[v|h]box_new()
[~andy/gtk] / examples / radiobuttons / radiobuttons.c
index 05fd1e38a2886e606a85cfd7a69eeb945427c95c..2869df9c4439195c2a9961a78e7a93e1afaf288a 100644 (file)
@@ -31,11 +31,11 @@ int main( int   argc,
     gtk_window_set_title (GTK_WINDOW (window), "radio buttons");
     gtk_container_set_border_width (GTK_CONTAINER (window), 0);
 
-    box1 = gtk_vbox_new (FALSE, 0);
+    box1 = gtk_box_new (GTK_ORIENTATION_VERTICAL, FALSE, 0);
     gtk_container_add (GTK_CONTAINER (window), box1);
     gtk_widget_show (box1);
 
-    box2 = gtk_vbox_new (FALSE, 10);
+    box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, FALSE, 10);
     gtk_container_set_border_width (GTK_CONTAINER (box2), 10);
     gtk_box_pack_start (GTK_BOX (box1), box2, TRUE, TRUE, 0);
     gtk_widget_show (box2);
@@ -55,11 +55,11 @@ int main( int   argc,
     gtk_box_pack_start (GTK_BOX (box2), button, TRUE, TRUE, 0);
     gtk_widget_show (button);
 
-    separator = gtk_hseparator_new ();
+    separator = gtk_separator_new (GTK_ORIENTATION_HORIZONTAL);
     gtk_box_pack_start (GTK_BOX (box1), separator, FALSE, TRUE, 0);
     gtk_widget_show (separator);
 
-    box2 = gtk_vbox_new (FALSE, 10);
+    box2 = gtk_box_new (GTK_ORIENTATION_VERTICAL, FALSE, 10);
     gtk_container_set_border_width (GTK_CONTAINER (box2), 10);
     gtk_box_pack_start (GTK_BOX (box1), box2, FALSE, TRUE, 0);
     gtk_widget_show (box2);
@@ -69,7 +69,7 @@ int main( int   argc,
                               G_CALLBACK (close_application),
                               window);
     gtk_box_pack_start (GTK_BOX (box2), button, TRUE, TRUE, 0);
-    GTK_WIDGET_SET_FLAGS (button, GTK_CAN_DEFAULT);
+    gtk_widget_set_can_default (button, TRUE);
     gtk_widget_grab_default (button);
     gtk_widget_show (button);
     gtk_widget_show (window);