js: Use GObject properties for animated properties
Clutter animations work on GObject properties on animatables. The last commit took care of the latter by turning all animated objects into actor subclasses, now it's time to make all properties used in Tweens into GObject properties. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/666
This commit is contained in:
@ -571,6 +571,12 @@ var FocusTracker = class {
|
||||
Signals.addSignalMethods(FocusTracker.prototype);
|
||||
|
||||
var EmojiPager = GObject.registerClass({
|
||||
Properties: {
|
||||
'delta': GObject.ParamSpec.int(
|
||||
'delta', 'delta', 'delta',
|
||||
GObject.ParamFlags.READWRITE,
|
||||
0, GLib.MAXINT32, 0)
|
||||
},
|
||||
Signals: {
|
||||
'emoji': { param_types: [GObject.TYPE_STRING] },
|
||||
'page-changed': {
|
||||
@ -619,7 +625,11 @@ var EmojiPager = GObject.registerClass({
|
||||
else if (value < -this._width)
|
||||
value = -this._width;
|
||||
|
||||
if (this._delta == value)
|
||||
return;
|
||||
|
||||
this._delta = value;
|
||||
this.notify('delta');
|
||||
|
||||
if (value == 0)
|
||||
return;
|
||||
|
Reference in New Issue
Block a user