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

Unified Diff: java/org/chromium/distiller/webdocument/WebFigure.java

Issue 2285133003: Use .innerText in text-only mode (Closed) Base URL: git@github.com:chromium/dom-distiller.git@master
Patch Set: Created 4 years, 4 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 | java/org/chromium/distiller/webdocument/WebText.java » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: java/org/chromium/distiller/webdocument/WebFigure.java
diff --git a/java/org/chromium/distiller/webdocument/WebFigure.java b/java/org/chromium/distiller/webdocument/WebFigure.java
index a9d6dbc95698f9d73cb1918520fff7fbdaa8c817..0bb0d2b2330bade2f9df3f969442b0ae73c2fc73 100644
--- a/java/org/chromium/distiller/webdocument/WebFigure.java
+++ b/java/org/chromium/distiller/webdocument/WebFigure.java
@@ -32,9 +32,7 @@ public class WebFigure extends WebImage {
@Override
public String generateOutput(boolean textOnly) {
Element figcaption = DomUtil.cloneAndProcessTree(figCaption);
- // TODO(wychen): .textContent should be identical to .innerText
- // in our use cases, but needs verification.
- if (textOnly) return DomUtil.javascriptTextContent(figcaption);
+ if (textOnly) return DomUtil.getInnerText(figcaption);
Element figure = Document.get().createElement("FIGURE");
figure.appendChild(getProcessedNode());
« no previous file with comments | « no previous file | java/org/chromium/distiller/webdocument/WebText.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698