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

Unified Diff: chrome/browser/resources/chromeos/select_to_speak/select_to_speak.js

Issue 2789583004: Add a color argument to accessibilityPrivate.setFocusRing (Closed)
Patch Set: Rebase Created 3 years, 9 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/select_to_speak/select_to_speak.js
diff --git a/chrome/browser/resources/chromeos/select_to_speak/select_to_speak.js b/chrome/browser/resources/chromeos/select_to_speak/select_to_speak.js
index 293f69d4d20f9a03aa4d9949186f73da77699827..21d3c20143460cc10d370b89c63822d445b6715f 100644
--- a/chrome/browser/resources/chromeos/select_to_speak/select_to_speak.js
+++ b/chrome/browser/resources/chromeos/select_to_speak/select_to_speak.js
@@ -81,6 +81,9 @@ var SelectToSpeak = function() {
/** @private { number } */
this.speechRate_ = 1.0;
+ /** @const { string } */
+ this.color_ = "#f73a98";
+
this.initPreferences_();
};
@@ -114,7 +117,7 @@ SelectToSpeak.prototype = {
var rect = rectFromPoints(
this.mouseStart_.x, this.mouseStart_.y,
evt.mouseX, evt.mouseY);
- chrome.accessibilityPrivate.setFocusRing([rect]);
+ chrome.accessibilityPrivate.setFocusRing([rect], this.color_);
},
/**
@@ -209,7 +212,8 @@ SelectToSpeak.prototype = {
'enqueue': true,
onEvent: (function(node, isLast, event) {
if (event.type == 'start') {
- chrome.accessibilityPrivate.setFocusRing([node.location]);
+ chrome.accessibilityPrivate.setFocusRing(
+ [node.location], this.color_);
} else if (event.type == 'interrupted' ||
event.type == 'cancelled') {
chrome.accessibilityPrivate.setFocusRing([]);
« no previous file with comments | « chrome/browser/chromeos/ui/focus_ring_layer.cc ('k') | chrome/common/extensions/api/accessibility_private.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698