[gnome-music/wip/jfelder/search-selection-reset: 2/9] headerbar: Rename search_mode_enabled property



commit 5ff675bef5e0ba1ab0a841ab579f8ee9cc0f3eea
Author: Jean Felder <jean@small-ubu>
Date:   Tue Apr 2 21:50:15 2019 +0200

    headerbar: Rename search_mode_enabled property
    
    The new name is "search_mode_active" to be consistent with the
    Search's property introduced in the previous commit.

 gnomemusic/widgets/headerbar.py | 4 ++--
 gnomemusic/window.py            | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/gnomemusic/widgets/headerbar.py b/gnomemusic/widgets/headerbar.py
index 3b362982..e01d81e1 100644
--- a/gnomemusic/widgets/headerbar.py
+++ b/gnomemusic/widgets/headerbar.py
@@ -98,7 +98,7 @@ class HeaderBar(Gtk.HeaderBar):
     _back_button = Gtk.Template.Child()
     _menu_button = Gtk.Template.Child()
 
-    search_mode_enabled = GObject.Property(type=bool, default=False)
+    search_mode_active = GObject.Property(type=bool, default=False)
     selected_items_count = GObject.Property(type=int, default=0, minimum=0)
     selection_mode_allowed = GObject.Property(type=bool, default=True)
     stack = GObject.Property(type=Gtk.Stack)
@@ -140,7 +140,7 @@ class HeaderBar(Gtk.HeaderBar):
             "selected-items-count", self._selection_menu,
             "selected-items-count")
         self.bind_property(
-            "search-mode-enabled", self._search_button, "active",
+            "search-mode-active", self._search_button, "active",
             GObject.BindingFlags.BIDIRECTIONAL
             | GObject.BindingFlags.SYNC_CREATE)
 
diff --git a/gnomemusic/window.py b/gnomemusic/window.py
index e53ab79c..8996c38f 100644
--- a/gnomemusic/window.py
+++ b/gnomemusic/window.py
@@ -124,7 +124,7 @@ class Window(Gtk.ApplicationWindow):
         self._headerbar = HeaderBar()
         self._searchbar = Searchbar()
         self._search.bind_property(
-            "search-mode-active", self._headerbar, "search-mode-enabled",
+            "search-mode-active", self._headerbar, "search-mode-active",
             GObject.BindingFlags.BIDIRECTIONAL
             | GObject.BindingFlags.SYNC_CREATE)
         self._search.bind_property(


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