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

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

Issue 1265533004: Handle lists more appropriately (Closed) Base URL: https://github.com/chromium/dom-distiller.git@master
Patch Set: Created 5 years, 5 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: java/org/chromium/distiller/webdocument/WebDocumentBuilder.java
diff --git a/java/org/chromium/distiller/webdocument/WebDocumentBuilder.java b/java/org/chromium/distiller/webdocument/WebDocumentBuilder.java
index 36d384f4390ad3ecd2cfe67aa8b508df85cfb953..0b1b329757f473c26b6deea9722e6d496f230add 100644
--- a/java/org/chromium/distiller/webdocument/WebDocumentBuilder.java
+++ b/java/org/chromium/distiller/webdocument/WebDocumentBuilder.java
@@ -60,6 +60,8 @@ public class WebDocumentBuilder implements WebDocumentBuilderInterface {
if (a.isAnchor) {
enterAnchor();
+ } else if (a.isList) {
+ enterList();
}
flush |= a.flush;
@@ -80,6 +82,8 @@ public class WebDocumentBuilder implements WebDocumentBuilderInterface {
if (a.isAnchor) {
exitAnchor();
+ } else if (a.isList) {
+ exitList();
}
// Must be done after flushBlock() because the labels for the block come from the
@@ -146,6 +150,14 @@ public class WebDocumentBuilder implements WebDocumentBuilderInterface {
document.addText(tb);
}
+ public void enterList() {
+
+ }
+
+ public void exitList() {
+
+ }
+
/**
* Returns a {@link WebDocument} containing the extracted {@link WebText}
* s. NOTE: Only call this after parsing.
« no previous file with comments | « java/org/chromium/distiller/webdocument/ElementAction.java ('k') | java/org/chromium/distiller/webdocument/WebList.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698