Closed Bug 351591 Opened 18 years ago Closed 18 years ago

Pressing Enter in an exceptions dialog adds an unwanted 'scheme:http' entry in the list

Categories

(Firefox :: Settings UI, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
Firefox 3 alpha2

People

(Reporter: chbok, Assigned: Gavin)

References

Details

(Keywords: regression)

Attachments

(1 file)

User-Agent:       Mozilla/5.0 (X11; U; Linux i686; fr-FR; rv:1.7.2) Gecko/20040804
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; fr; rv:1.8.0.6) Gecko/20060728 Firefox/1.5.0.6

All dialogs called with the permissions.xul file have a wrong behaviour with the Enter key. This bug is not the same as bug 324187.

Reproducible: Always

Steps to Reproduce:
1. Open the Preference/Options window
2. Click on any of the "Exceptions" buttons (in Content or Security)
3. Set the focus to the text field, type nothing and press Enter

Actual Results:  
Actual results: 'scheme:http' appears in the list

Expected Results:  
Expected: nothing happens

This behaviour also appears in Firefox 2.0 beta2

(I suggest a simple test with textbox.value in http://lxr.mozilla.org/mozilla1.8/source/browser/components/preferences/permissions.js#105 for instance)
Confirming on the latest bonecho/2.0b2 win xp nightly.
Status: UNCONFIRMED → NEW
Ever confirmed: true
I don't see it cause any harm. Although Enter should just close the window I assume.
Regression between 1.8b2_2005060806 and 1.8b2_2005060906:
http://bonsai.mozilla.org/cvsquery.cgi?module=PhoenixTinderbox&date=explicit&mindate=2005-06-08+05%3A00&maxdate=2005-06-09+07%3A00
Maybe caused by Bug 296865.
Blocks: 296865
Keywords: regression
Version: unspecified → Trunk
Attached patch patchSplinter Review
Makes it act like a button press, by not explicitly calling addPermission, to let the existing input validating code do its job.
Assignee: nobody → gavin.sharp
Status: NEW → ASSIGNED
Attachment #237083 - Flags: review?(mconnor)
Comment on attachment 237083 [details] [diff] [review]
patch

r=mano
Attachment #237083 - Flags: review?(mconnor) → review+
Whiteboard: [checkin needed]
Target Milestone: --- → Firefox 3 alpha1
mozilla/browser/components/preferences/permissions.js 	1.9
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Whiteboard: [checkin needed]
Target Milestone: Firefox 3 alpha1 → Firefox 3 alpha2
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: