rfkill: Turn manager into a GObject

That will allow us to use it in property bindings.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2385>
This commit is contained in:
Florian Müllner
2022-07-18 20:28:13 +02:00
committed by Marge Bot
parent bb043bb761
commit 98cbc31e86
2 changed files with 43 additions and 15 deletions

View File

@ -750,8 +750,10 @@ class NMWirelessDialog extends ModalDialog.ModalDialog {
this._syncView.bind(this), this);
this._rfkill = Rfkill.getRfkillManager();
this._rfkill.connectObject('airplane-mode-changed',
this._syncView.bind(this), this);
this._rfkill.connectObject(
'notify::airplane-mode', () => this._syncView(),
'notify::hw-airplane-mode', () => this._syncView(),
this);
this._networks = [];
this._buildLayout();