Closed Bug 773639 Opened 12 years ago Closed 8 years ago

Focus outline freezes on element selected using javascript .focus() after press TAB button

Categories

(Core :: DOM: Core & HTML, defect)

x86_64
Windows 7
defect
Not set
minor

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: petr.ciml, Unassigned, NeedInfo)

References

Details

(Keywords: regression)

Attachments

(2 files)

User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.11 (KHTML, like Gecko) Chrome/20.0.1132.57 Safari/536.11

Steps to reproduce:

1) In page_load set focus (using JavaScript .focus() function) on input type="image" element. 
2) Press TAB key


Actual results:

Outline have both two elements - element focused using JavaScript and next element(in tabindex order).


Expected results:

Outline show only over next element
Severity: normal → minor
Component: Untriaged → Web Apps
Component: Web Apps → DOM: Core & HTML
Product: Firefox → Core
data:text/html,<!DOCTYPE html>
<input type="image" src="https://bugzilla.mozilla.org/extensions/BMO/web/producticons/dino.png">
<input type="image" src="https://bugzilla.mozilla.org/extensions/BMO/web/producticons/firefox.png">
<script>
onload = function() {
  document.body.firstChild.focus();
}
</script>

STR
1. Open testcase and Close tab (cache images) 
2. Open testcase again 
3. Press TAB

Regression window(m-c)
Good:
http://hg.mozilla.org/mozilla-central/rev/5c6d107ede5a
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:7.0a1) Gecko/20110601 Firefox/7.0a1 ID:20110601030746
Bad:
http://hg.mozilla.org/mozilla-central/rev/840644b2b6a2
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:7.0a1) Gecko/20110601 Firefox/7.0a1 ID:20110601011530
Pushlog:
http://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=5c6d107ede5a&tochange=840644b2b6a2


Regression window(cedar)
Good:
http://hg.mozilla.org/projects/cedar/rev/4a47b6944cb5
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:7.0a1) Gecko/20110531 Firefox/7.0a1 ID:20110531174638
Bad:
http://hg.mozilla.org/projects/cedar/rev/5ad2fcf8d9ed
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:7.0a1) Gecko/20110531 Firefox/7.0a1 ID:20110531185514


Suspected: Bug 598833
Blocks: 598833
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: regression
Version: 13 Branch → Trunk
Olli, Neil, any idea what's going on here?
> STR
> 1. Open testcase and Close tab (cache images) 
> 2. Open testcase again 
> 3. Press TAB

Here's what I'm doing:

1. Open two tabs.
2. Copy the data url into the location bar and press enter
3. Close the tab by clicking the close button
4. Copy the data url into the remaining tab and press enter
5. Press tab

I don't see any bug. Am I missing a step here?  And what is 'cache images' referring to?
This maybe windows only.
I can reproduce the problem with/without HWA in Nightly18.0a1 windows7.
http://hg.mozilla.org/mozilla-central/rev/96287ad60bef
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:18.0) Gecko/18.0 Firefox/18.0 ID:20120911030553

But I cannot reproduce in Ubuntu.
I can sometimes reproduce on Windows. It might have something to do with the delay in loading the image. After starting up Firefox and opening the test, the images appear after a moment but the focus ring around the first image doesn't appear. I've only been able to reproduce the double focus ring using the steps above when this happens, but not when loading the test afterwards when the images load quickly.
I add attachment with mostly simple test case. This is not minor issue for us. We are implementing WCAG/Section508 support, and two visible focus outlines is not valid use-case there.
Firefox: 50.0a1, Build ID: 20160630030207
User Agent: 	Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:50.0) Gecko/20100101 Firefox/50.0

I have tested this issue on the latest Firefox (47.0.1) release and the latest Nightly (50.0a1) build, but I could not reproduce it. For testing this I have used the provided steps from comment 1 and only one single image was focused while navigating with the "Tab" key.
I have also tested with the provided test case from comment 6, but only one link was focused while navigating with the "Tab" key. 

Petr, is this still reproducible on your end? If yes, can you please retest this using latest Firefox release and latest Nightly build (https://nightly.mozilla.org/) and report back the results?  When doing this, please use a new clean Firefox profile.

Alice, can you please check this too?
Flags: needinfo?(petr.ciml)
Flags: needinfo?(alice0775)
Reproduced on Firefox7 with STR comment#1.
But not on Nightly50.0a1.
Flags: needinfo?(alice0775)
Alice, thanks for retesting this bug.
Considering this, I will close this bug as Resolved - WFM.
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: