status/power: Always sync after creating proxy
Otherwise the menu remains in an inconsistent state in case of an error, until something else triggers a call to _sync() (like a settings change). https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4431 Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1901>
This commit is contained in:
parent
9e9ed42263
commit
8430aa59da
@ -40,10 +40,10 @@ class Indicator extends PanelMenu.SystemIndicator {
|
|||||||
(proxy, error) => {
|
(proxy, error) => {
|
||||||
if (error) {
|
if (error) {
|
||||||
log(error.message);
|
log(error.message);
|
||||||
return;
|
} else {
|
||||||
|
this._proxy.connect('g-properties-changed',
|
||||||
|
this._sync.bind(this));
|
||||||
}
|
}
|
||||||
this._proxy.connect('g-properties-changed',
|
|
||||||
this._sync.bind(this));
|
|
||||||
this._sync();
|
this._sync();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user