mirror of
https://github.com/edu4rdshl/gnome-shell.git
synced 2026-07-18 07:34:54 +00:00
ShellUserVerifier: Add method to check if the service name is fingerprint
We have multiple places where we check if we're handling a fingerprint event, so let's add a common public function so that it can be used also by the authPrompt. Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1784>
This commit is contained in:
parent
13a441d0ee
commit
4585acdf25
1 changed files with 6 additions and 2 deletions
|
|
@ -409,6 +409,11 @@ var ShellUserVerifier = class {
|
|||
return serviceName == this._defaultService;
|
||||
}
|
||||
|
||||
serviceIsFingerprint(serviceName) {
|
||||
return serviceName === FINGERPRINT_SERVICE_NAME &&
|
||||
this._haveFingerprintReader;
|
||||
}
|
||||
|
||||
_updateDefaultService() {
|
||||
if (this._settings.get_boolean(PASSWORD_AUTHENTICATION_KEY))
|
||||
this._defaultService = PASSWORD_SERVICE_NAME;
|
||||
|
|
@ -474,8 +479,7 @@ var ShellUserVerifier = class {
|
|||
_onInfo(client, serviceName, info) {
|
||||
if (this.serviceIsForeground(serviceName)) {
|
||||
this._queueMessage(info, MessageType.INFO);
|
||||
} else if (serviceName == FINGERPRINT_SERVICE_NAME &&
|
||||
this._haveFingerprintReader) {
|
||||
} else if (this.serviceIsFingerprint(serviceName)) {
|
||||
// We don't show fingerprint messages directly since it's
|
||||
// not the main auth service. Instead we use the messages
|
||||
// as a cue to display our own message.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue