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

Unified Diff: chrome/browser/resources/chromeos/chromevox/common/editable_text_base.js

Issue 2312353002: Revert of Add support for rich output inside of content editables. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@editable_nav
Patch Set: Created 4 years, 3 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
« no previous file with comments | « no previous file | chrome/browser/resources/chromeos/chromevox/cvox2/background/automation_predicate.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/chromeos/chromevox/common/editable_text_base.js
diff --git a/chrome/browser/resources/chromeos/chromevox/common/editable_text_base.js b/chrome/browser/resources/chromeos/chromevox/common/editable_text_base.js
index 543d52cc0e3688391c21d0185c257702b9f9f1cd..74902a019dd4df412115810b179470c4f88104de 100644
--- a/chrome/browser/resources/chromeos/chromevox/common/editable_text_base.js
+++ b/chrome/browser/resources/chromeos/chromevox/common/editable_text_base.js
@@ -352,7 +352,14 @@
this.speak(Msgs.getMsg('Unselected'), evt.triggeredByUser);
} else if (this.getLineIndex(this.start) !=
this.getLineIndex(evt.start)) {
- this.describeLine(this.getLineIndex(evt.start), evt.triggeredByUser);
+ // Moved to a different line; read it.
+ var lineValue = this.getLine(this.getLineIndex(evt.start));
+ if (lineValue == '') {
+ lineValue = Msgs.getMsg('text_box_blank');
+ } else if (/^\s+$/.test(lineValue)) {
+ lineValue = Msgs.getMsg('text_box_whitespace');
+ }
+ this.speak(lineValue, evt.triggeredByUser);
} else if (this.start == evt.start + 1 ||
this.start == evt.start - 1) {
// Moved by one character; read it.
@@ -419,22 +426,6 @@
}
};
-/**
- * Describes a line given a line index and whether it was user triggered.
- * @param {number} lineIndex
- * @param {boolean} triggeredByUser
- */
-cvox.ChromeVoxEditableTextBase.prototype.describeLine =
- function(lineIndex, triggeredByUser) {
- var lineValue = this.getLine(lineIndex);
- if (lineValue == '') {
- lineValue = Msgs.getMsg('text_box_blank');
- } else if (/^\s+$/.test(lineValue)) {
- lineValue = Msgs.getMsg('text_box_whitespace');
- }
- this.speak(lineValue, triggeredByUser);
-};
-
/**
* Describe a change where the text changes.
« no previous file with comments | « no previous file | chrome/browser/resources/chromeos/chromevox/cvox2/background/automation_predicate.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698