[gnome-music/wip/mschraal/core: 83/86] albumswidget2: Cleanup



commit 1a4ce50843bcac41f9fd71bedb26dc514b39bf5a
Author: Marinus Schraal <mschraal gnome org>
Date:   Thu Jun 6 00:50:37 2019 +0200

    albumswidget2: Cleanup

 gnomemusic/widgets/albumwidget2.py | 33 ---------------------------------
 1 file changed, 33 deletions(-)
---
diff --git a/gnomemusic/widgets/albumwidget2.py b/gnomemusic/widgets/albumwidget2.py
index c231c86f..8014444f 100644
--- a/gnomemusic/widgets/albumwidget2.py
+++ b/gnomemusic/widgets/albumwidget2.py
@@ -145,38 +145,6 @@ class AlbumWidget2(Gtk.EventBox):
         self._running_info_label.props.label = ngettext(
             "{} minute", "{} minutes", mins).format(mins)
 
-    @log
-    def _on_row_activated(self, klass, listboxrow):
-        old_model = Gtk.ListStore(
-            GObject.TYPE_STRING,  # title
-            GObject.TYPE_STRING,
-            GObject.TYPE_STRING,
-            GObject.TYPE_STRING,
-            GdkPixbuf.Pixbuf,    # icon
-            GObject.TYPE_OBJECT,  # song object
-            GObject.TYPE_BOOLEAN,  # item selected
-            GObject.TYPE_STRING,
-            GObject.TYPE_BOOLEAN,
-            GObject.TYPE_INT,  # icon shown
-            GObject.TYPE_BOOLEAN,
-            GObject.TYPE_INT
-        )
-
-        print(listboxrow.get_index())
-        # for song in self._model[0]:
-        #     _iter = old_model.insert_with_valuesv(-1, [5], [song.props.media])
-        #     if song is self._model[0][listboxrow.get_index()]:
-        #         activated_iter = _iter
-        #         listboxrow.get_child().props.state = SongWidget.State.PLAYING
-
-        coresong = listboxrow.get_child()
-        self._parent_view._window._app._coremodel.set_playlist_model(
-            PlayerPlaylist.Type.ALBUM, album, coresong, self._album_model)
-        # self._player.set_playlist(
-        #     PlayerPlaylist.Type.ALBUM, self._album_name, old_model,
-        #     activated_iter)
-        self._player.play()
-
     @log
     def _on_selection_changed(self, klass, value):
         n_items = 0
@@ -199,7 +167,6 @@ class AlbumWidget2(Gtk.EventBox):
             self._player.play(None, None, song_widget._media)
             self._parent_view._window._app._coremodel.disconnect(signal_id)
 
-        # coresong = listboxrow.get_child()
         signal_id = self._parent_view._window._app._coremodel.connect(
             "playlist-loaded", _on_playlist_loaded)
         self._parent_view._window._app._coremodel.set_playlist_model(


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