[gnome-music/wip/jfelder/gtk4-v3: 167/200] artstack: Fix annotations




commit d14ff6cf4ed9f9b7f4fe49197f21be45fcb06915
Author: Marinus Schraal <mschraal gnome org>
Date:   Sat Feb 5 21:00:12 2022 +0100

    artstack: Fix annotations

 gnomemusic/widgets/artstack.py | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)
---
diff --git a/gnomemusic/widgets/artstack.py b/gnomemusic/widgets/artstack.py
index 9acaa8447..a7b11f595 100644
--- a/gnomemusic/widgets/artstack.py
+++ b/gnomemusic/widgets/artstack.py
@@ -27,9 +27,6 @@ from typing import Optional, Union
 import typing
 
 from gi.repository import Adw, GObject, Gtk
-if typing.TYPE_CHECKING:
-    from cairo import ImageSurface
-
 
 from gnomemusic.asyncqueue import AsyncQueue
 from gnomemusic.artcache import ArtCache
@@ -163,7 +160,8 @@ class ArtStack(Gtk.Stack):
 
         self._async_queue.queue(self._cache, coreobject, self._size)
 
-    def _swap_thumbnails(self, paintable: Paintable, animate: bool) -> None:
+    def _swap_thumbnails(
+            self, paintable: Gtk.Paintable, animate: bool) -> None:
         if self.props.visible_child_name == "B":
             self._cover_a.props.paintable = paintable
             if animate:
@@ -179,7 +177,8 @@ class ArtStack(Gtk.Stack):
             else:
                 self.props.visible_child_name = "B"
 
-    def _on_cache_result(self, cache: ArtCache, paintable: Gdk.Paintable) -> None:
+    def _on_cache_result(
+            self, cache: ArtCache, paintable: Gtk.Paintable) -> None:
         self._swap_thumbnails(paintable, True)
 
     def _on_destroy(self, widget: ArtStack) -> None:


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