modalDialog: Inherit from St.Widget
Make the dialog a widget itself, removing the `_group` property used for handling the actor. Update all the inherited classes to be also GObject implementations, moving all the signals to proper object ones. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/55
This commit is contained in:
@ -676,9 +676,10 @@ var NMWirelessDialogItem = GObject.registerClass({
|
||||
}
|
||||
});
|
||||
|
||||
var NMWirelessDialog = class extends ModalDialog.ModalDialog {
|
||||
constructor(client, device) {
|
||||
super({ styleClass: 'nm-dialog' });
|
||||
var NMWirelessDialog = GObject.registerClass(
|
||||
class NMWirelessDialog extends ModalDialog.ModalDialog {
|
||||
_init(client, device) {
|
||||
super._init({ styleClass: 'nm-dialog' });
|
||||
|
||||
this._client = client;
|
||||
this._device = device;
|
||||
@ -724,9 +725,11 @@ var NMWirelessDialog = class extends ModalDialog.ModalDialog {
|
||||
Main.sessionMode.disconnect(id);
|
||||
this.close();
|
||||
});
|
||||
|
||||
this.connect('destroy', this._onDestroy.bind(this));
|
||||
}
|
||||
|
||||
destroy() {
|
||||
_onDestroy() {
|
||||
if (this._apAddedId) {
|
||||
GObject.Object.prototype.disconnect.call(this._device, this._apAddedId);
|
||||
this._apAddedId = 0;
|
||||
@ -752,8 +755,6 @@ var NMWirelessDialog = class extends ModalDialog.ModalDialog {
|
||||
Mainloop.source_remove(this._scanTimeoutId);
|
||||
this._scanTimeoutId = 0;
|
||||
}
|
||||
|
||||
super.destroy();
|
||||
}
|
||||
|
||||
_onScanTimeout() {
|
||||
@ -1144,7 +1145,7 @@ var NMWirelessDialog = class extends ModalDialog.ModalDialog {
|
||||
this._itemBox.grab_key_focus();
|
||||
});
|
||||
}
|
||||
};
|
||||
});
|
||||
|
||||
var NMDeviceWireless = class {
|
||||
constructor(client, device) {
|
||||
|
Reference in New Issue
Block a user