boxPointer: Rename show/hide to open/close
Pretty much like dd4709bb2
, BoxPointer's show() and hide()
functions will clash with Clutter.Actor's ones.
In addition to that, on a conceptual level, the current API
is not great, because calling boxPointer.hide() won't result
in boxPointer.actor.visible == false.
For these reasons, rename show() and hide() to open() and
close(). A compatibility layer will be added in a following
commit, warning about the usage of show() and hide().
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/153
This commit is contained in:
@ -356,7 +356,7 @@ var Key = new Lang.Class({
|
||||
},
|
||||
|
||||
_showSubkeys() {
|
||||
this._boxPointer.show(BoxPointer.PopupAnimation.FULL);
|
||||
this._boxPointer.open(BoxPointer.PopupAnimation.FULL);
|
||||
this._capturedEventId = global.stage.connect('captured-event',
|
||||
this._onCapturedEvent.bind(this));
|
||||
this._unmapId = this.keyButton.connect('notify::mapped', () => {
|
||||
@ -367,7 +367,7 @@ var Key = new Lang.Class({
|
||||
|
||||
_hideSubkeys() {
|
||||
if (this._boxPointer)
|
||||
this._boxPointer.hide(BoxPointer.PopupAnimation.FULL);
|
||||
this._boxPointer.close(BoxPointer.PopupAnimation.FULL);
|
||||
if (this._capturedEventId) {
|
||||
global.stage.disconnect(this._capturedEventId);
|
||||
this._capturedEventId = 0;
|
||||
|
Reference in New Issue
Block a user