diff options
author | tobiasjs <tobiasjs@chromium.org> | 2015-03-12 13:49:08 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-03-12 20:49:40 +0000 |
commit | 5668d12d29ab659ad01dc0e0ffdf24f2eb5f187a (patch) | |
tree | 1da05955776ae58689f72a2b70002e8a70760b69 /android_webview/test | |
parent | 8d60881e5751ee5c7dbf54b4c40c0516407ffe78 (diff) | |
download | chromium_src-5668d12d29ab659ad01dc0e0ffdf24f2eb5f187a.zip chromium_src-5668d12d29ab659ad01dc0e0ffdf24f2eb5f187a.tar.gz chromium_src-5668d12d29ab659ad01dc0e0ffdf24f2eb5f187a.tar.bz2 |
[WebView] Add onPageCommitVisible callback.
This provides a convenience callback, onPageCommitVisible, that
makes use of the visual state listener API. It is called at the
earliest point at which the next draw will not render contents from
the previously loaded page.
BUG=457184, 458566
Review URL: https://codereview.chromium.org/984603002
Cr-Commit-Position: refs/heads/master@{#320361}
Diffstat (limited to 'android_webview/test')
-rw-r--r-- | android_webview/test/shell/assets/visual_state_on_page_commit_visible_test.html | 7 | ||||
-rw-r--r-- | android_webview/test/shell/src/org/chromium/android_webview/test/NullContentsClient.java | 4 |
2 files changed, 11 insertions, 0 deletions
diff --git a/android_webview/test/shell/assets/visual_state_on_page_commit_visible_test.html b/android_webview/test/shell/assets/visual_state_on_page_commit_visible_test.html new file mode 100644 index 0000000..5725e31 --- /dev/null +++ b/android_webview/test/shell/assets/visual_state_on_page_commit_visible_test.html @@ -0,0 +1,7 @@ +<html> +<head> +</head> +<body bgcolor="#0f0" style="margin: 0px; padding: 0px;"> + <img id="image" bgcolor="#0f0" width="256" height="256" src="intercepted://blue.png"> +</body> +</html> diff --git a/android_webview/test/shell/src/org/chromium/android_webview/test/NullContentsClient.java b/android_webview/test/shell/src/org/chromium/android_webview/test/NullContentsClient.java index 269597d7..6c8fa56 100644 --- a/android_webview/test/shell/src/org/chromium/android_webview/test/NullContentsClient.java +++ b/android_webview/test/shell/src/org/chromium/android_webview/test/NullContentsClient.java @@ -164,6 +164,10 @@ public class NullContentsClient extends AwContentsClient { } @Override + public void onPageCommitVisible(String url) { + } + + @Override public void onReceivedError(int errorCode, String description, String failingUrl) { } |