Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9)

Issue 637323002: Focus unfocusable node upon reference fragment navigation (Closed)

Created:
6 years, 2 months ago by robwu
Modified:
6 years, 2 months ago
Reviewers:
dmazzoni, Mike West
CC:
blink-reviews
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Project:
blink
Visibility:
Public.

Description

Focus unfocusable node upon reference fragment navigation Currently, when the page navigates to a non-focusable reference fragment, the currently focused element does not change. In Firefox/IE, the focus is moved to the referenced element even when this element is non-focusable. This mismatch in behavior became apparent when Blink started supporting a:focus (https://crbug.com/388666). In IE/FF, clicking on <a href="#ref"> causes the link to loose focus, and therefore :focus does not get applied any more. In Chrome, however, :focus remains activated because the focus does not change. This patch changes the behavior of Blink: When the pages navigates to a reference fragment that refers to a non-focusable node, then the focus is removed from the previously focused element. See also https://www.w3.org/Bugs/Public/show_bug.cgi?id=26907. BUG=417636, 262171 TEST=Tools/Scripts/run-webkit-tests fast/dom/fragment-activation-focuses-target.html Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=183455

Patch Set 1 #

Patch Set 2 : Fix typos in layout tests (note: the focusable-node test fails, will investigate) #

Patch Set 3 : Remove tab-to-focusable_node test #

Total comments: 4

Patch Set 4 : edit comment #

Patch Set 5 : Remove "focusable node" from test expectation #

Unified diffs Side-by-side diffs Delta from patch set Stats (+40 lines, -6 lines) Patch
M LayoutTests/fast/dom/fragment-activation-focuses-target.html View 1 2 2 chunks +26 lines, -2 lines 0 comments Download
M LayoutTests/fast/dom/fragment-activation-focuses-target-expected.txt View 1 2 3 4 1 chunk +12 lines, -3 lines 0 comments Download
M Source/core/frame/FrameView.cpp View 1 2 3 1 chunk +2 lines, -1 line 0 comments Download

Messages

Total messages: 22 (7 generated)
robwu
6 years, 2 months ago (2014-10-08 10:12:59 UTC) #2
Mike West
Can you add some text to the CL description outlining the change you're making and ...
6 years, 2 months ago (2014-10-08 10:21:20 UTC) #3
robwu
On 2014/10/08 10:21:20, Mike West wrote: > Can you add some text to the CL ...
6 years, 2 months ago (2014-10-08 10:49:37 UTC) #4
Mike West
+dmazzoni This change LGTM, but please wait for Dominic to take a look at the ...
6 years, 2 months ago (2014-10-08 11:05:43 UTC) #6
Mike West
On 2014/10/08 11:05:43, Mike West wrote: > +dmazzoni > > This change LGTM, but please ...
6 years, 2 months ago (2014-10-08 11:08:14 UTC) #7
robwu
I've removed the test and comment about accessibility (sequential focus navigation (SFN) as defined at ...
6 years, 2 months ago (2014-10-08 16:32:24 UTC) #10
dmazzoni
I think this is bug 262171, right? That seems like a better primary bug for ...
6 years, 2 months ago (2014-10-08 18:08:29 UTC) #11
dmazzoni
First of all, thank you for looking into this issue. I would very much like ...
6 years, 2 months ago (2014-10-08 18:19:06 UTC) #12
robwu
2014/10/08 18:08:29, dmazzoni wrote: > I think this is bug 262171, right? That seems like ...
6 years, 2 months ago (2014-10-08 20:10:23 UTC) #13
dmazzoni
lgtm https://codereview.chromium.org/637323002/diff/80001/Source/core/frame/FrameView.cpp File Source/core/frame/FrameView.cpp (right): https://codereview.chromium.org/637323002/diff/80001/Source/core/frame/FrameView.cpp#newcode1365 Source/core/frame/FrameView.cpp:1365: // If it does not accept keyboard focus, ...
6 years, 2 months ago (2014-10-08 20:26:28 UTC) #14
robwu
https://codereview.chromium.org/637323002/diff/80001/Source/core/frame/FrameView.cpp File Source/core/frame/FrameView.cpp (right): https://codereview.chromium.org/637323002/diff/80001/Source/core/frame/FrameView.cpp#newcode1365 Source/core/frame/FrameView.cpp:1365: // If it does not accept keyboard focus, then ...
6 years, 2 months ago (2014-10-09 06:12:57 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/637323002/100001
6 years, 2 months ago (2014-10-09 06:13:58 UTC) #17
commit-bot: I haz the power
Try jobs failed on following builders: linux_blink_rel on tryserver.blink (http://build.chromium.org/p/tryserver.blink/builders/linux_blink_rel/builds/28432)
6 years, 2 months ago (2014-10-09 07:22:21 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/637323002/120001
6 years, 2 months ago (2014-10-09 09:01:50 UTC) #21
commit-bot: I haz the power
6 years, 2 months ago (2014-10-09 11:30:41 UTC) #22
Message was sent while issue was closed.
Committed patchset #5 (id:120001) as 183455

Powered by Google App Engine
This is Rietveld 408576698