animation: Disable spinner animations when actor is destroyed

There's nothing to animate anymore, just a source for warnings when
trying to access a destroyed object.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/362
This commit is contained in:
Florian Müllner 2019-01-23 23:40:18 +01:00
parent 9dc3b73ef9
commit edbb204332

View File

@ -104,6 +104,11 @@ var Spinner = new Lang.Class({
this._animate = animate;
},
_onDestroy() {
this._animate = false;
this.parent();
},
play() {
Tweener.removeTweens(this.actor);