Update onPause documentation
onPause() method documentation wrongly claims it stops JS. This could
have been true for very early implementations of Webview which does
not use V8 (pre-honeycomb) however it is not the case anymore
since V8 does not provide a way to stop JS safely for a particular Webview.
Change-Id: I6363dc2ef47c463da6baa417832da750225f5cf2
diff --git a/core/java/android/webkit/WebView.java b/core/java/android/webkit/WebView.java
index aa72eb3..057b701 100644
--- a/core/java/android/webkit/WebView.java
+++ b/core/java/android/webkit/WebView.java
@@ -1470,11 +1470,12 @@
}
/**
- * Pauses any extra processing associated with this WebView and its
- * associated DOM, plugins, JavaScript etc. For example, if this WebView is
- * taken offscreen, this could be called to reduce unnecessary CPU or
- * network traffic. When this WebView is again "active", call onResume().
- * Note that this differs from pauseTimers(), which affects all WebViews.
+ * Does a best-effort attempt to pause any processing that can be paused
+ * safely, such as animations and geolocation. Note that this call
+ * does not pause JavaScript. To pause JavaScript globally, use
+ * {@link #pauseTimers}.
+ *
+ * To resume WebView, call {@link #onResume}.
*/
public void onPause() {
checkThread();
@@ -1482,7 +1483,7 @@
}
/**
- * Resumes a WebView after a previous call to onPause().
+ * Resumes a WebView after a previous call to {@link #onPause}.
*/
public void onResume() {
checkThread();