[gnome-boxes] topbar: simplify and generalize a function



commit 05896cea1923497fb7ed151fe514cc4d8407ad89
Author: Marc-Andrà Lureau <marcandre lureau gmail com>
Date:   Thu Aug 2 20:09:56 2012 +0200

    topbar: simplify and generalize a function
    
    Rename update_select_btn_sensitivity () to update_select_btn () since
    it could perform and other UI changes, and we want name consitency
    with other similar UI update functions.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=681089

 src/topbar.vala |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/src/topbar.vala b/src/topbar.vala
index 642e988..d693eeb 100644
--- a/src/topbar.vala
+++ b/src/topbar.vala
@@ -98,9 +98,9 @@ private class Boxes.Topbar: Boxes.UI {
                 TopbarPage.SELECTION : notebook.page = TopbarPage.COLLECTION;
         });
 
-        update_select_btn_sensitivity ();
-        App.app.collection.item_added.connect (update_select_btn_sensitivity);
-        App.app.collection.item_removed.connect (update_select_btn_sensitivity);
+        update_select_btn ();
+        App.app.collection.item_added.connect (update_select_btn);
+        App.app.collection.item_removed.connect (update_select_btn);
         toolbar_end.insert (select_btn, 1);
 
         toolbar_end.set_show_arrow (false);
@@ -149,7 +149,7 @@ private class Boxes.Topbar: Boxes.UI {
         notebook.show_all ();
     }
 
-    private void update_select_btn_sensitivity () {
+    private void update_select_btn () {
         select_btn.sensitive = App.app.collection.items.length != 0;
     }
 



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