js: Actorize animated objects
We have a couple of places where we don't tween the actor, but a custom property on the delegate object. In order to move those to Clutter animations, we will need an animatable, so turn those objects into widget subclasses. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/666
This commit is contained in:
@ -66,8 +66,11 @@ var OsdWindow = class {
|
||||
this._label = new St.Label();
|
||||
this._box.add(this._label);
|
||||
|
||||
this._level = new BarLevel.BarLevel(0, { styleClass: 'level' });
|
||||
this._box.add(this._level.actor);
|
||||
this._level = new BarLevel.BarLevel({
|
||||
style_class: 'level',
|
||||
value: 0
|
||||
});
|
||||
this._box.add(this._level);
|
||||
|
||||
this._hideTimeoutId = 0;
|
||||
this._reset();
|
||||
@ -107,7 +110,7 @@ var OsdWindow = class {
|
||||
}
|
||||
|
||||
setLevel(value) {
|
||||
this._level.actor.visible = (value != undefined);
|
||||
this._level.visible = (value != undefined);
|
||||
if (value != undefined) {
|
||||
if (this.actor.visible)
|
||||
Tweener.addTween(this._level,
|
||||
|
Reference in New Issue
Block a user