[gnome-music/wip/jfelder/selection-misc-cleanups: 11/20] albumwidget: Remove unused selected_items_count logic



commit b1d4c6dfbb6a49c039ea43fcba1e3b677b99e9aa
Author: Jean Felder <jfelder src gnome org>
Date:   Fri Jan 10 13:09:05 2020 +0100

    albumwidget: Remove unused selected_items_count logic
    
    Since the core rewrite, it is handled by CoreSelection.

 gnomemusic/widgets/albumwidget.py | 9 ---------
 1 file changed, 9 deletions(-)
---
diff --git a/gnomemusic/widgets/albumwidget.py b/gnomemusic/widgets/albumwidget.py
index 24deb5e4..0a166d1f 100644
--- a/gnomemusic/widgets/albumwidget.py
+++ b/gnomemusic/widgets/albumwidget.py
@@ -51,7 +51,6 @@ class AlbumWidget(Gtk.EventBox):
     _running_info_label = Gtk.Template.Child()
     _title_label = Gtk.Template.Child()
 
-    selected_items_count = GObject.Property(type=int, default=0, minimum=0)
     selection_mode = GObject.Property(type=bool, default=False)
 
     _duration = 0
@@ -162,14 +161,6 @@ class AlbumWidget(Gtk.EventBox):
         self._running_info_label.props.label = ngettext(
             "{} minute", "{} minutes", mins).format(mins)
 
-    def _on_selection_changed(self, klass, value):
-        n_items = 0
-        for song in self._model[0]:
-            if song.props.selected:
-                n_items += 1
-
-        self.props.selected_items_count = n_items
-
     def _song_activated(self, widget, song_widget):
         if self.props.selection_mode:
             song_widget.props.selected = not song_widget.props.selected


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