[gtk+] Don't use gtk_scrolled_window_add_with_viewport() internally



commit 7c1c7cb7282fd4226016dd7159ea6c93bed727b0
Author: Cosimo Cecchi <cosimoc gnome org>
Date:   Fri Feb 1 16:08:09 2013 +0100

    Don't use gtk_scrolled_window_add_with_viewport() internally
    
    Just use gtk_container_add() instead.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=693015

 gtk/gtkaboutdialog.c     |    2 +-
 gtk/gtkprintunixdialog.c |    6 ++----
 2 files changed, 3 insertions(+), 5 deletions(-)
---
diff --git a/gtk/gtkaboutdialog.c b/gtk/gtkaboutdialog.c
index bca534c..f50fed0 100644
--- a/gtk/gtkaboutdialog.c
+++ b/gtk/gtkaboutdialog.c
@@ -2388,7 +2388,7 @@ create_credits_page (GtkAboutDialog *about)
   gtk_grid_set_row_spacing (GTK_GRID (grid), 2);
   gtk_widget_set_halign (grid, GTK_ALIGN_CENTER);
   gtk_widget_set_valign (grid, GTK_ALIGN_START);
-  gtk_scrolled_window_add_with_viewport (GTK_SCROLLED_WINDOW (sw), grid);
+  gtk_container_add (GTK_CONTAINER (sw), grid);
   gtk_style_context_add_class (gtk_widget_get_style_context (gtk_bin_get_child (GTK_BIN (sw))),
                                GTK_STYLE_CLASS_VIEW);
 
diff --git a/gtk/gtkprintunixdialog.c b/gtk/gtkprintunixdialog.c
index 75ea52f..c4ac913 100644
--- a/gtk/gtkprintunixdialog.c
+++ b/gtk/gtkprintunixdialog.c
@@ -3712,8 +3712,7 @@ create_optional_page (GtkPrintUnixDialog  *dialog,
   gtk_container_set_border_width (GTK_CONTAINER (table), 12);
   gtk_widget_show (table);
 
-  gtk_scrolled_window_add_with_viewport (GTK_SCROLLED_WINDOW (scrolled),
-                                         table);
+  gtk_container_add (GTK_CONTAINER (scrolled), table);
   gtk_viewport_set_shadow_type (GTK_VIEWPORT (gtk_bin_get_child (GTK_BIN (scrolled))),
                                 GTK_SHADOW_NONE);
 
@@ -3743,8 +3742,7 @@ create_advanced_page (GtkPrintUnixDialog *dialog)
   gtk_container_set_border_width (GTK_CONTAINER (main_vbox), 12);
   gtk_widget_show (main_vbox);
 
-  gtk_scrolled_window_add_with_viewport (GTK_SCROLLED_WINDOW (scrolled),
-                                         main_vbox);
+  gtk_container_add (GTK_CONTAINER (scrolled), main_vbox);
   gtk_viewport_set_shadow_type (GTK_VIEWPORT (gtk_bin_get_child (GTK_BIN (scrolled))),
                                 GTK_SHADOW_NONE);
 



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