selected and defaultSelected don't work

VERIFIED FIXED

Status

()

Core
DOM
P3
normal
VERIFIED FIXED
19 years ago
17 years ago

People

(Reporter: David Baron, Assigned: Eric Pollmann)

Tracking

Trunk
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: Should Selected be readonly?, URL)

(Reporter)

Description

19 years ago
DESCRIPTION:  According to the DOM1 Errata,
http://www.w3.org/DOM/updates/REC-DOM-Level-1-19981001-errata.html ,
HTMLSelectElement::selected should NOT BE readonly (at least if you read into it
a little - it describes changing it) and HTMLSelectElement::defaultSelected
should reset the value of selected as well.  Right now, selected is always false
and defaultSelected can be changed, but the change has no effect.

STEPS TO REPRODUCE:
1) Load above URL
2) note that "four" is selected and "five" isn't.
3) press "test Errata" button

ACTUAL RESULTS:
 * 28th, 32d, 36th, 40th, and 42d lines of output are red
 * "four" is still selected and "five" isn't

EXPECTED RESULTS:
 * above mentioned lines of output are green
 * the options switch so "four" is not selected and "five" is

DOES NOT WORK CORRECTLY ON:
 * Linux, apprunner, 1999-08-20-13-M10
(Reporter)

Updated

19 years ago
Blocks: 8949

Updated

19 years ago
Assignee: vidur → pollmann

Comment 1

19 years ago
Another one for you, Eric. One day we'll get this right.
(Reporter)

Updated

19 years ago
OS: Linux → All
Hardware: PC → All
(Reporter)

Comment 2

19 years ago
ALSO DOES NOT WORK CORRECTLY ON:
 * Windows, apprunner, 1999-08-24-09-M10

Marking All/All
(Assignee)

Updated

19 years ago
Status: NEW → ASSIGNED
Whiteboard: Should Selected be readonly?
(Assignee)

Comment 3

19 years ago
I see two parts to this bug:
1) SelectElement::Selected is readonly.
2) Setting SelectElement::DefaultSelected does not update the widget.

1) We chose to do this as we have a fairly literal implementation of the spec.
Vidur just sent a message to the DOM group to get explicit confirmation that
this is a typo.  If it is, I will update and recompile the Option IDL file and
this should work.

2) I just checked in a fix.
(Assignee)

Updated

19 years ago
Status: ASSIGNED → RESOLVED
Last Resolved: 19 years ago
Resolution: --- → FIXED
(Assignee)

Comment 4

19 years ago
Just checked in a fix for 1.

To verify, go to this page:
http://www.fas.harvard.edu/~dbaron/dom/test/one-html/Errata

Click on the 'test Errata' button.  The results box should contain all green
lines.  If any line referring to 'selected' is red, this bug was not fixed.
(Reporter)

Updated

19 years ago
Status: RESOLVED → VERIFIED
(Reporter)

Comment 5

19 years ago
Verified fixed, Linux apprunner 1999-10-08-08-M11.
You need to log in before you can comment on or make changes to this bug.