[libpeas] Disable the scrolled window in the demo program



commit bc89bac5ce6b4196f7b6c8e488409db810b5b51f
Author: Garrett Regier <garrettregier gmail com>
Date:   Sun Jan 18 03:35:41 2015 -0800

    Disable the scrolled window in the demo program
    
    It really isn't needed as there are only a few
    plugins. This makes it easier to test the program
    as the window's size was too small.

 peas-demo/peas-demo.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)
---
diff --git a/peas-demo/peas-demo.c b/peas-demo/peas-demo.c
index d545ba3..0b4e09e 100644
--- a/peas-demo/peas-demo.c
+++ b/peas-demo/peas-demo.c
@@ -57,6 +57,7 @@ create_main_window (void)
   GtkWidget *window;
   GtkWidget *box;
   GtkWidget *manager;
+  GtkWidget *scrolled_window;
   GtkWidget *button_box;
   GtkWidget *button;
 
@@ -73,6 +74,12 @@ create_main_window (void)
   manager = peas_gtk_plugin_manager_new (peas_engine_get_default ());
   gtk_box_pack_start (GTK_BOX (box), manager, TRUE, TRUE, 0);
 
+  /* Always show all plugins, there are only a few */
+  scrolled_window = gtk_test_find_sibling (manager,
+                                           GTK_TYPE_SCROLLED_WINDOW);
+  gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolled_window),
+                                  GTK_POLICY_NEVER, GTK_POLICY_NEVER);
+
   button_box = gtk_button_box_new (GTK_ORIENTATION_HORIZONTAL);
   gtk_box_set_spacing (GTK_BOX (button_box), 6);
   gtk_button_box_set_layout (GTK_BUTTON_BOX (button_box), GTK_BUTTONBOX_END);


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