citadel #1
@ -676,14 +676,16 @@ var UnlockDialog = GObject.registerClass({
|
|||||||
}
|
}
|
||||||
|
|
||||||
_ensureAuthPrompt() {
|
_ensureAuthPrompt() {
|
||||||
if (!this._authPrompt) {
|
if (this._authPrompt)
|
||||||
|
return;
|
||||||
|
|
||||||
this._authPrompt = new AuthPrompt.AuthPrompt(this._gdmClient,
|
this._authPrompt = new AuthPrompt.AuthPrompt(this._gdmClient,
|
||||||
AuthPrompt.AuthPromptMode.UNLOCK_ONLY);
|
AuthPrompt.AuthPromptMode.UNLOCK_ONLY);
|
||||||
this._authPrompt.connect('failed', this._fail.bind(this));
|
this._authPrompt.connect('failed', this._fail.bind(this));
|
||||||
this._authPrompt.connect('cancelled', this._fail.bind(this));
|
this._authPrompt.connect('cancelled', this._fail.bind(this));
|
||||||
this._authPrompt.connect('reset', this._onReset.bind(this));
|
this._authPrompt.connect('reset', this._onReset.bind(this));
|
||||||
|
|
||||||
this._promptBox.add_child(this._authPrompt);
|
this._promptBox.add_child(this._authPrompt);
|
||||||
}
|
|
||||||
|
|
||||||
this._authPrompt.reset();
|
this._authPrompt.reset();
|
||||||
this._authPrompt.updateSensitivity(true);
|
this._authPrompt.updateSensitivity(true);
|
||||||
@ -870,11 +872,7 @@ var UnlockDialog = GObject.registerClass({
|
|||||||
}
|
}
|
||||||
|
|
||||||
finish(onComplete) {
|
finish(onComplete) {
|
||||||
if (!this._authPrompt) {
|
this._ensureAuthPrompt();
|
||||||
onComplete();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
this._authPrompt.finish(onComplete);
|
this._authPrompt.finish(onComplete);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user