[glade/searchbar: 2/3] Searchbar: Ignore some properties



commit 05e36c30d8a913eb9627aa723068d334021a6bd0
Author: Matthias Clasen <mclasen redhat com>
Date:   Sat Oct 25 16:46:12 2014 -0400

    Searchbar: Ignore some properties
    
    Don't apply the search-mode and show-close-button properties
    in the embedded view, since it would be confusing to have the
    search bar just 'disappear'. We do save these properties, so
    it is possible to set them up for the actual application.

 plugins/gtk+/glade-gtk-searchbar.c |    3 +++
 plugins/gtk+/gtk+.xml.in           |    3 ++-
 2 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/plugins/gtk+/glade-gtk-searchbar.c b/plugins/gtk+/glade-gtk-searchbar.c
index da955fc..9f222e8 100644
--- a/plugins/gtk+/glade-gtk-searchbar.c
+++ b/plugins/gtk+/glade-gtk-searchbar.c
@@ -39,6 +39,9 @@ glade_gtk_search_bar_post_create (GladeWidgetAdaptor *adaptor,
       gtk_container_add (GTK_CONTAINER (widget), child);
       g_object_set_data (G_OBJECT (widget), "child", child);
     }
+
+  gtk_search_bar_set_search_mode (GTK_SEARCH_BAR (widget), TRUE);
+  gtk_search_bar_set_show_close_button (GTK_SEARCH_BAR (widget), FALSE);
 }
 
 gboolean
diff --git a/plugins/gtk+/gtk+.xml.in b/plugins/gtk+/gtk+.xml.in
index fe90fb6..e9ada68 100644
--- a/plugins/gtk+/gtk+.xml.in
+++ b/plugins/gtk+/gtk+.xml.in
@@ -1613,7 +1613,8 @@
         <remove-child-function>glade_gtk_search_bar_remove_child</remove-child-function>
         <replace-child-function>glade_gtk_search_bar_replace_child</replace-child-function>
         <properties>
-          <property id="search-mode-enabled" save="False" default="True"/>
+          <property id="search-mode-enabled" save="True" ignore="True"/>
+          <property id="show-close-button" save="True" ignore="True"/>
         </properties>
 
       </glade-widget-class>


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