cleanup: Use arrow functions for tweener callbacks

While it is legal to use method syntax for the function properties
here, arrow notation is less unexpected and allows us to drop the
separate scope properties.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/608
This commit is contained in:
Florian Müllner
2019-06-29 17:37:59 +02:00
committed by Georges Basile Stavracas Neto
parent 6ed5bc2f6c
commit 8fcd6c7153
11 changed files with 30 additions and 50 deletions

View File

@ -283,10 +283,9 @@ var AppMenuButton = GObject.registerClass({
{ opacity: 0,
time: Overview.ANIMATION_TIME,
transition: 'easeOutQuad',
onComplete() {
onComplete: () => {
this.hide();
},
onCompleteScope: this });
} });
}
_onStyleChanged(actor) {
@ -328,8 +327,7 @@ var AppMenuButton = GObject.registerClass({
{ opacity: 0,
time: SPINNER_ANIMATION_TIME,
transition: "easeOutQuad",
onCompleteScope: this,
onComplete() {
onComplete: () => {
this._spinner.stop();
this._spinner.actor.opacity = 255;
this._spinner.actor.hide();