polkitAgent: Return GLib.SOURCE_REMOVE on timeout callback
resetDialog is used (also) as GLib timeout function, so while just returning an undefined value will stop the timeout anyways, it's just cleaner to use the GSource expected return values https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1203
This commit is contained in:
parent
8d1e4659d1
commit
bfa34914db
@ -328,11 +328,13 @@ var AuthenticationDialog = GObject.registerClass({
|
|||||||
|
|
||||||
let resetDialog = () => {
|
let resetDialog = () => {
|
||||||
if (this.state != ModalDialog.State.OPENED)
|
if (this.state != ModalDialog.State.OPENED)
|
||||||
return;
|
return GLib.SOURCE_REMOVE;
|
||||||
|
|
||||||
this._passwordEntry.hide();
|
this._passwordEntry.hide();
|
||||||
this._cancelButton.grab_key_focus();
|
this._cancelButton.grab_key_focus();
|
||||||
this._okButton.reactive = false;
|
this._okButton.reactive = false;
|
||||||
|
|
||||||
|
return GLib.SOURCE_REMOVE;
|
||||||
};
|
};
|
||||||
|
|
||||||
if (delay) {
|
if (delay) {
|
||||||
|
Loading…
Reference in New Issue
Block a user