Closed
Bug 252624
Opened 20 years ago
Closed 18 years ago
multiline SELECT with width style defined, in table cell doesn't make the selected item visible
Categories
(Core :: Layout: Form Controls, defect)
Tracking
()
RESOLVED
WORKSFORME
People
(Reporter: paul, Unassigned)
References
()
Details
(Keywords: testcase)
Attachments
(1 file)
4.30 KB,
text/html
|
Details |
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1) Opera 7.52 [en] Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7) Gecko/20040707 Firefox/0.9.2 If you put a multi-line SELECT element with a "STYLE='width:100%'" into a table cell, and have a pre-selected item in the SELECT list, the SELECT list will always show the top x lines of the SELECT list, even if that means that the pre- selected item isn't visible. (If the same SELECT element isn't in a table, or doesn't have the 'width' style, then it seems to work OK) In the page at http://www.pscs.co.uk/moztest2.php, the last line in each list should be selected and visible. In the first list, it is selected, but not visible. The other lists work OK. Reproducible: Always Steps to Reproduce: <table width="100%"><tr><td> <select size="10" style="width:100%;"> ..long list of options... <OPTION SELECTED>Last Line</OPTION> </select> </td></tr></table> Actual Results: The last line is selected, but not visible Expected Results: The last line should have been selected and the listbox scrolled until it was visible. A workaround is to select the last line after the page has loaded (in the onLoad event of the page). You have to make sure the last line isn't already selected though, eg function Loaded() { var x = document.myform.mylist.selectedIndex; document.myform.mylist.selectedIndex = 0; document.myform.mylist.selectedIndex = x; } (this shouldn't cause problems on other browsers either, but it shouldn't be needed)
Reporter | ||
Comment 1•20 years ago
|
||
Also see http://forums.mozillazine.org/viewtopic.php?t=103904 The problem seems to exist in versions of Mozilla as well as Firefox, but is reported to behave differently in different versions..
Reporter | ||
Updated•20 years ago
|
Component: General → Layout: Form Controls
Product: Firefox → Browser
Version: unspecified → 1.0 Branch
Updated•20 years ago
|
Whiteboard: DUPEME
Reporter | ||
Comment 3•20 years ago
|
||
Copy of the web page test case for future reference
Updated•18 years ago
|
Assignee: firefox → nobody
QA Contact: general → layout.form-controls
Comment 4•18 years ago
|
||
Fixed somewhere along the line, apparently: the testcase works for me in current trunk and branch builds.
Status: UNCONFIRMED → RESOLVED
Closed: 18 years ago
Resolution: --- → WORKSFORME
You need to log in
before you can comment on or make changes to this bug.
Description
•