Closed Bug 594737 Opened 14 years ago Closed 14 years ago

select list not greyed out when disabled, size and multiple attributes all set

Categories

(Core :: Layout: Form Controls, defect, P1)

x86
Windows XP
defect

Tracking

()

RESOLVED FIXED
mozilla2.0b7

People

(Reporter: beldaz.jalfrezi, Assigned: bzbarsky)

References

Details

(Keywords: testcase)

Attachments

(2 files)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9.2.2) Gecko/20100316 Firefox/3.6.2 ( .NET CLR 3.5.30729)
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9.2.2) Gecko/20100316 Firefox/3.6.2 ( .NET CLR 3.5.30729)

While creating an HTML form I found difficulty disabling portions using the "disabled" attribute. Further investigation showed that this attribute was not respected in select lists in conjunction with the "multiple" and "size" attributes.

Reproducible: Always

Steps to Reproduce:
1. Create a form containing a select list
2. Add the attribute disabled="disabled"
3. Add the attribute multiple="multiple"
4. Add the attribute size="4"
5. Try different combinations of the above attributes

Actual Results:  
The select box is disabled when the disabled attibute is set along with a combination of the other attributes, but when all attributes are set the box is no longer disabled.

Expected Results:  
Select box should be disabled in all cases where the diabled attibute is set. (Works correctly in IE8)
Attached file Simple HTML test case
This test case contains a form with three select lists holding the same options. All three lists have the "disabled" attribute set, and so should be disabled in the browser. In the reported bug, the first list (with "multiple" and "size" attributes also set) is not disabled.
Component: General → Layout: Form Controls
Keywords: testcase
Product: Firefox → Core
QA Contact: general → layout.form-controls
Version: unspecified → Trunk
Er... it's disabled just fine.  It just doesn't get the grayed-out coloring, right?
Attached patch FixSplinter Review
Assignee: nobody → bzbarsky
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Attachment #473659 - Flags: review?(dbaron)
Priority: -- → P1
(In reply to comment #2)
> Er... it's disabled just fine.  It just doesn't get the grayed-out coloring,
> right?

You're quite right: it's disabled but not grayed out accordingly. Sorry for not diagnosing the bug correctly.
Updated summary to avoid misleading reader
Summary: select disabled attribute not working when size and multiple attributes → select list not greyed out when disabled, size and multiple attributes all set
Thanks for double-checking that!
Comment on attachment 473659 [details] [diff] [review]
Fix

r=dbaron
Attachment #473659 - Flags: review?(dbaron)
Attachment #473659 - Flags: review+
Attachment #473659 - Flags: approval2.0+
Whiteboard: [need landing]
Pushed http://hg.mozilla.org/mozilla-central/rev/4817c29dc507
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Whiteboard: [need landing]
Target Milestone: --- → mozilla2.0b7
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: