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

Issue 2479563004: automation_custom_bindings needs to handle blur events too. (Closed)

Created:
4 years, 1 month ago by dmazzoni
Modified:
4 years, 1 month ago
Reviewers:
David Tseng
CC:
chromium-reviews, chromium-apps-reviews_chromium.org, extensions-reviews_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

automation_custom_bindings needs to handle blur events too. In the automation API used by ChromeVox, focus events are handled specially, because windows tend to fire focus events due to local focus changes even when they don't have focus globally - so when we get a focus event we use that as a signal to compute which node really has focus and fire the focus event on the proper node if needed. However, Chrome also fires "blur" events, and when focus is lost that's the only event that will fire, and it needs to be handled the same way. Leaving out "blur" led to a bug where calling setSequentialFocusNavigationStartingPoint on a node would cause focus to be lost (correctly), but ChromeVox wouldn't get the notification that focus was lost right away with eventFrom=action. So when focus was checked later, ChromeVox would discover that focus was suddenly on the root of the document and mistakenly treat that as a real focus event. When blur is handled the same way as focus in automation_custom_bindings, ChromeVox gets the blur event immediately in response to calling setSequentialFocusNavigationStartingPoint, and because eventFrom=action is set, it ignores it (correctly), and navigation of the page is unaffected. BUG=662441 TESTED=Manually tested all three repros from bug 662441 Committed: https://crrev.com/5e5850d17ba180e02b1e7bd6d5fb1d3bdb01972e Cr-Commit-Position: refs/heads/master@{#430368}

Patch Set 1 #

Patch Set 2 : Only handle blur events on root #

Unified diffs Side-by-side diffs Delta from patch set Stats (+13 lines, -1 line) Patch
M chrome/renderer/resources/extensions/automation_custom_bindings.js View 1 1 chunk +13 lines, -1 line 0 comments Download

Messages

Total messages: 14 (10 generated)
David Tseng
lgtm
4 years, 1 month ago (2016-11-04 16:42:29 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2479563004/20001
4 years, 1 month ago (2016-11-07 19:48:39 UTC) #10
commit-bot: I haz the power
Committed patchset #2 (id:20001)
4 years, 1 month ago (2016-11-07 20:46:32 UTC) #12
commit-bot: I haz the power
4 years, 1 month ago (2016-11-07 21:19:01 UTC) #14
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/5e5850d17ba180e02b1e7bd6d5fb1d3bdb01972e
Cr-Commit-Position: refs/heads/master@{#430368}

Powered by Google App Engine
This is Rietveld 408576698