Open
Bug 190101
Opened 22 years ago
Updated 4 years ago
focus() not working properly when used to simulate a disabled text field.
Categories
(Core :: DOM: Selection, defect, P5)
Tracking
()
NEW
People
(Reporter: samuel.reinman, Unassigned)
Details
Attachments
(1 file, 1 obsolete file)
217 bytes,
text/html
|
Details |
User-Agent: Mozilla/5.0 (Windows; U; WinNT4.0; en-US; rv:1.3a) Gecko/20021207 Phoenix/0.5
Build Identifier: Mozilla/5.0 (Windows; U; WinNT4.0; en-US; rv:1.3a) Gecko/20021207 Phoenix/0.5
In Netscape 4.x, and IE 5.x, this code will simulate a disabled field by causing
the cursor to jump to the 2nd field when the first field is clicked.
In Phoenix, when you click in the first field and type, the text correctly shows
up in the 2nd field, but the cursor remains in the first field.
Once this happens the first time, the cursor always remains in the first field,
even if you click in the second field.
I do not have Mozilla so I cannot test it there. (sorry! kinda busy at work)
Here is the HTML:
<html>
<body>
<h3> Test Page to demonstrate possible issue with the JavaScript focus()
function in Phoenix 0.5</h3>
<form name="test" method="post">
<table border="1" cellspacing="0" cellpadding="2" bgcolor="#CECECE" width="672">
<tr>
<td width="160"align="right"><b>Disabled: </b></td>
<td width="224">
<input align=left size="15" type="text" maxlength="15" name="one" value=""
onfocus="javascript:test.two.focus();">
</td>
</tr>
<tr>
<td width="160" align="right"><b>Enabled: </b></td>
<td width="224">
<input class=tenBk align=left size="10" type="text" maxlength="10"
name="two" value = "" >
</td>
</tr>
</table>
</form>
</body>
</html>
Reproducible: Always
Steps to Reproduce:
1. Click in the first text box and type
2.
3.
Actual Results:
See above
Expected Results:
The cursor should have displayed in the text box that has the focus.
Comment 1•22 years ago
|
||
O'k. One notice -- it you switch tab or windows, and than back again you would
see cursor in correct position.
Comment 2•22 years ago
|
||
Comment on attachment 112290 [details]
focus() don't move cursor.
Work for me on Linux 1.3b 20030120 and 1.2.1 20021226.
Dont' work for me on 1.3b Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US;
rv:1.3b) Gecko/20030121. So I think it is Win32 specific bug.
Updated•22 years ago
|
Attachment #112290 -
Attachment filename: testcase1.html → testcase.html
Comment 3•22 years ago
|
||
Updated•22 years ago
|
Attachment #112290 -
Attachment is obsolete: true
Updated•22 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Updated•22 years ago
|
Component: Browser-General → Form Manager
Comment 4•22 years ago
|
||
To selection.
Assignee: asa → mjudge
Component: Form Manager → Selection
QA Contact: asa → pmac
Updated•15 years ago
|
Assignee: mjudge → nobody
QA Contact: pmac → selection
Comment 6•4 years ago
|
||
Bulk-downgrade of unassigned, >=5 years untouched DOM/Storage bugs' priority.
If you have reason to believe this is wrong (especially for the severity), please write a comment and ni :jstutte.
Severity: normal → S4
Priority: -- → P5
You need to log in
before you can comment on or make changes to this bug.
Description
•