Closed Bug 733754 Opened 12 years ago Closed 12 years ago

Deactivate the 'OK' button if there is no text entered in Master Password credentials textbox

Categories

(Firefox for Android Graveyard :: General, defect)

ARM
Android
defect
Not set
minor

Tracking

(firefox20 verified)

VERIFIED FIXED
Firefox 20
Tracking Status
firefox20 --- verified

People

(Reporter: paul.feher, Assigned: mkohler)

Details

Attachments

(2 files, 1 obsolete file)

Build: Nightly:Fennec/13.0a1 (2012-03-06)
Device: HTC Desire Z 
OS: Android 2.3.3

Steps to reproduce:
1. Open Fennec App
2. Tap on device Menu button > More > Settings
3. Tap on Use Master Password option and add one
4. Tap on Use Master Password option again

Expected Result:
The OK button should be inactive if the text field is empty.

Actual Result: 
The OK button is active.
Does this really matter? If it's blank, you'll get a toast notification saying "Incorrect Password".
Severity: normal → trivial
note from screenshot, there is no text in the password box, but the OK button is active.   From the bug, this button should be inactive
Summary: Don't allow user to use empty password to remove master password → Deactive the OK button if there's no text entered in Master password textbox
Severity: trivial → minor
Summary: Deactive the OK button if there's no text entered in Master password textbox → Deactivate the 'OK' button if there is no text entered in Master Password credentials textbox
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → DUPLICATE
Status: RESOLVED → UNCONFIRMED
Ever confirmed: false
Resolution: DUPLICATE → ---
Status: UNCONFIRMED → NEW
Ever confirmed: true
Attached patch Patch v1 (obsolete) — Splinter Review
I couldn't do the same for the "Enter Master Password" dialog which appears after clicking the "Remember" password after you login to a site (http://mxr.mozilla.org/mozilla-central/source/mobile/android/components/LoginManagerPrompter.js#216). Where does this code live? I'd be glad to fix that too.

(In reply to Aaron Train [:aaronmt] from comment #1)
> Does this really matter? If it's blank, you'll get a toast notification
> saying "Incorrect Password".

Actually, this is not the case. The window just appears again. Should we fix this? (Should also be fixed in the above mentioned dialog.
Assignee: nobody → michaelkohler
Status: NEW → ASSIGNED
Attachment #661511 - Flags: review?(mark.finkle)
Comment on attachment 661511 [details] [diff] [review]
Patch v1

Brian is a good reviewer for this
Attachment #661511 - Flags: review?(mark.finkle) → review?(bnicholson)
(In reply to Michael Kohler [:michaelkohler] from comment #4)
> I couldn't do the same for the "Enter Master Password" dialog which appears
> after clicking the "Remember" password after you login to a site
> (http://mxr.mozilla.org/mozilla-central/source/mobile/android/components/
> LoginManagerPrompter.js#216). Where does this code live? I'd be glad to fix
> that too.

That will require basically rewriting the prompt service, or rewriting loginManagerPrompter to send its own messages to Java and then writing up a more advanced bridge between the java prompt service and gecko.... Or we could force any prompts showing a password to disable the "positive" button if the password is blank, but I think there are probably valid use cases for allowing blank passwords. I don't think I'd accept the simple solution (special prompts for the LoginManager). I'd like to remove more of the special native UI code than add more.

i.e. its non-trivial in any case.
Comment on attachment 661511 [details] [diff] [review]
Patch v1

+        EditText input1 = null;
...
+            String text1 = input1.getText().toString();

nit: I'd remove the 1 after the variable names.

+                                input.requestFocus();

What is this doing? I don't see any difference if I remove this line.
Comment on attachment 661511 [details] [diff] [review]
Patch v1

r- until comments are answered
Attachment #661511 - Flags: review?(bnicholson) → review-
You're absolutely right.
Attachment #661511 - Attachment is obsolete: true
Attachment #684866 - Flags: review?(bnicholson)
Attachment #684866 - Flags: review?(bnicholson) → review+
Attachment #684866 - Flags: checkin?
Keywords: checkin-needed
Attachment #684866 - Flags: checkin? → checkin+
https://hg.mozilla.org/mozilla-central/rev/70e1fa924492
Status: ASSIGNED → RESOLVED
Closed: 12 years ago12 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 20
OK button is deactivated on the latest Nightly for the Master Password popup. Closing bug as verified fixed on:

Firefox 20.0a1 (2012-12-06)
Device: Galaxy Tab2 7"
OS: Android 4.0.3
Status: RESOLVED → VERIFIED
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: