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

Unified Diff: src/com/dom_distiller/client/DomUtil.java

Issue 499623002: Instrument DomDistiller with timing information. (Closed) Base URL: https://code.google.com/p/dom-distiller/@master
Patch Set: Created 6 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 | « src/com/dom_distiller/client/DomDistiller.java ('k') | src/de/l3s/boilerpipe/document/TextDocument.java » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/com/dom_distiller/client/DomUtil.java
diff --git a/src/com/dom_distiller/client/DomUtil.java b/src/com/dom_distiller/client/DomUtil.java
index 23122a778d9f38e33ef8183e870483f66507187c..12ebadf819606c4ed10a7c4d1ada796b78c2af3c 100644
--- a/src/com/dom_distiller/client/DomUtil.java
+++ b/src/com/dom_distiller/client/DomUtil.java
@@ -96,6 +96,11 @@ public class DomUtil {
return node.innerText;
}-*/;
+ public static native double getTime() /*-{
+ // window.performance is unavailable in Gwt's dev environment.
+ return window.performance ? window.performance.now() : 0;
+ }-*/;
+
/**
* Use jsni for direct access to javascript's textContent. textContent is different from
* innerText (see http://www.kellegous.com/j/2013/02/27/innertext-vs-textcontent):
« no previous file with comments | « src/com/dom_distiller/client/DomDistiller.java ('k') | src/de/l3s/boilerpipe/document/TextDocument.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698