authPrompt: don't muck with cancelButton in onAskQuestion

onAskQuestion has this code:

    if (this.verifyingUser)
        this.cancelButton.show();
    else
        this.cancelButton.hide();

but onAskQuestion can only be called when this.verifyingUser is true.
Also, cancelButton is public, and it only ever otherwise gets hidden
from callers.

This commit drops mucking with cancelButton visibility, leaving it
entirely up to the callers to deal with.

https://bugzilla.gnome.org/show_bug.cgi?id=683437
This commit is contained in:
Ray Strode 2013-07-28 16:15:43 -04:00
parent a04895383a
commit 3a13e7484a

View File

@ -195,11 +195,6 @@ const AuthPrompt = new Lang.Class({
this.setPasswordChar(passwordChar); this.setPasswordChar(passwordChar);
this.setQuestion(question); this.setQuestion(question);
if (this.verifyingUser)
this.cancelButton.show();
else
this.cancelButton.hide();
if (passwordChar) { if (passwordChar) {
if (this._userVerifier.reauthenticating) if (this._userVerifier.reauthenticating)
this.nextButton.label = _("Unlock"); this.nextButton.label = _("Unlock");