unlockDialog: Simplify sensitivity handling

We only call _updateSensitivity() to make elements sensitive, and
nothing ever touches the sensitivity of the switch-user button; so
just call the corresponding authPrompt method directly, which is the
only bit that has an actual effect.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1029
This commit is contained in:
Florian Müllner 2020-02-19 14:24:51 +01:00 committed by Florian Müllner
parent 104d1ae151
commit c6cf81f28b

View File

@ -666,7 +666,7 @@ var UnlockDialog = GObject.registerClass({
this._promptBox.add_child(this._authPrompt);
this._authPrompt.reset();
this._updateSensitivity(true);
this._authPrompt.updateSensitivity(true);
}
_maybeDestroyAuthPrompt() {
@ -682,13 +682,6 @@ var UnlockDialog = GObject.registerClass({
}
}
_updateSensitivity(sensitive) {
this._authPrompt.updateSensitivity(sensitive);
this._otherUserButton.reactive = sensitive;
this._otherUserButton.can_focus = sensitive;
}
_showClock() {
if (this._activePage === this._clock)
return;