[gnome-music/wip/mschraal/rework-art-widget: 2/18] artstack: Drop alternate stack page




commit 56fe9e49f27450f05d67f40fdc815f3e9d926108
Author: Marinus Schraal <mschraal gnome org>
Date:   Thu Mar 17 16:51:07 2022 +0100

    artstack: Drop alternate stack page

 gnomemusic/widgets/artstack.py | 10 +---------
 1 file changed, 1 insertion(+), 9 deletions(-)
---
diff --git a/gnomemusic/widgets/artstack.py b/gnomemusic/widgets/artstack.py
index f81ff7c78..47601eac7 100644
--- a/gnomemusic/widgets/artstack.py
+++ b/gnomemusic/widgets/artstack.py
@@ -70,11 +70,8 @@ class ArtStack(Gtk.Stack):
 
         self._cover_a = Gtk.Image()
         self._cover_a.props.visible = True
-        self._cover_b = Gtk.Image()
-        self._cover_b.props.visible = True
 
         self.add_named(self._cover_a, "A")
-        self.add_named(self._cover_b, "B")
 
         self.props.size = size
 
@@ -171,12 +168,7 @@ class ArtStack(Gtk.Stack):
         self._async_queue.queue(self._cache, coreobject, self._size)
 
     def _swap_thumbnails(self, paintable: Gtk.Paintable) -> None:
-        if self.props.visible_child_name == "B":
-            self._cover_a.props.paintable = paintable
-            self.props.visible_child_name = "A"
-        else:
-            self._cover_b.props.paintable = paintable
-            self.props.visible_child_name = "B"
+        self._cover_a.props.paintable = paintable
 
     def _on_cache_result(
             self, cache: ArtCache, paintable: Gtk.Paintable) -> None:


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