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

Unified Diff: chrome/browser/resources/chromeos/chromevox/chromevox/injected/live_regions.js

Issue 1137403003: Fix ChromeVox's detection of whether the current document has focus. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/chromeos/chromevox/chromevox/injected/live_regions.js
diff --git a/chrome/browser/resources/chromeos/chromevox/chromevox/injected/live_regions.js b/chrome/browser/resources/chromeos/chromevox/chromevox/injected/live_regions.js
index 2cb2c2efb781afb18823f713b35dd240016caa74..d4ed721a08ddcdf3a6b52b28357da18e8332b242 100644
--- a/chrome/browser/resources/chromeos/chromevox/chromevox/injected/live_regions.js
+++ b/chrome/browser/resources/chromeos/chromevox/chromevox/injected/live_regions.js
@@ -82,7 +82,7 @@ cvox.LiveRegions.nodesAlreadyHandled = [];
cvox.LiveRegions.init = function(pageLoadTime, queueMode, disableSpeak) {
cvox.LiveRegions.pageLoadTime = pageLoadTime;
- if (disableSpeak || !document.hasFocus()) {
+ if (disableSpeak || !cvox.ChromeVox.documentHasFocus()) {
return false;
}
@@ -379,7 +379,7 @@ cvox.LiveRegions.announceChange = function(
cvox.LiveRegions.lastAnnouncedMap[key] = now;
var assertive = cvox.AriaUtil.getAriaLive(liveRoot) == 'assertive';
- if (cvox.Interframe.isIframe() && !document.hasFocus()) {
+ if (cvox.Interframe.isIframe() && !cvox.ChromeVox.documentHasFocus()) {
cvox.Interframe.sendMessageToParentWindow(
{'command': 'speakLiveRegion',
'content': JSON.stringify(navDescriptions),

Powered by Google App Engine
This is Rietveld 408576698