[gnome-music/wip/jfelder/coverstack-timeout] coverstack: Correctly reset timeout



commit 9497dcca559e1e574f7cfe6f30fb7fd4a790ead4
Author: Jean Felder <jfelder src gnome org>
Date:   Tue Jan 22 14:52:58 2019 +0100

    coverstack: Correctly reset timeout
    
    If CoverStack loading child becomes visible, it means that the timeout
    is over but _timeout attribute is not reset. Then, once a coverstack
    is found, _art_retrieved method will try to remove a source which does
    not exist anymore. It will result in a source not found warning
    message.
    
    Resetting _timeout attribute in _set_loading_child method fixes the
    issue.

 gnomemusic/widgets/coverstack.py | 1 +
 1 file changed, 1 insertion(+)
---
diff --git a/gnomemusic/widgets/coverstack.py b/gnomemusic/widgets/coverstack.py
index d7456ec6..4a981193 100644
--- a/gnomemusic/widgets/coverstack.py
+++ b/gnomemusic/widgets/coverstack.py
@@ -121,6 +121,7 @@ class CoverStack(Gtk.Stack):
     def _set_loading_child(self):
         self.props.visible_child_name = "loading"
         self._active_child = self.props.visible_child_name
+        self._timeout = None
 
         return GLib.SOURCE_REMOVE
 


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