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

Unified Diff: chrome/test/data/prerender/prerender_visibility_hidden_quick.html

Issue 8392041: Prerendered tabs use the same SessionStorage namespace as the tab that triggered the prerender. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove check Created 9 years, 1 month 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: chrome/test/data/prerender/prerender_visibility_hidden_quick.html
diff --git a/chrome/test/data/prerender/prerender_visibility_hidden_quick.html b/chrome/test/data/prerender/prerender_visibility_hidden_quick.html
deleted file mode 100644
index 3495a505ecb4a8363b35b23eb5662d86fa836c76..0000000000000000000000000000000000000000
--- a/chrome/test/data/prerender/prerender_visibility_hidden_quick.html
+++ /dev/null
@@ -1,82 +0,0 @@
-<html>
-<!--
-This test checks the visibility API when a prerendered page is visited without
-being displayed, before the page has finished loading.
--->
-<head>
-<title>Prerender Visibility Hidden Quick Switch</title>
-
-<script>
-// Checks visibility state while the page is still loading.
-var lastState = document.webkitVisibilityState;
-var loadingStatePassed = document.webkitHidden && lastState != 'visible';
-var unexpectedStateChange = false;
-
-function onVisibilityChange(event) {
- if (lastState == 'hidden' ||
- document.webkitVisibilityState != 'hidden') {
- unexpectedStateChange = true;
- return;
- }
- lastState = document.webkitVisibilityState;
-}
-
-document.addEventListener('webkitvisibilitychange',
- onVisibilityChange,
- false);
-
-// Checks that either the first visibility state was 'prerender' and there
-// was one and only one visibility change event to 'hidden', or visibility
-// was always 'hidden'.
-function DidDisplayPass() {
- return loadingStatePassed &&
- !unexpectedStateChange &&
- 'hidden' == document.webkitVisibilityState &&
- document.webkitHidden;
-}
-</script>
-
-</head>
-<body></body>
-</html>
-<html>
-<!--
-This test checks the visibility API when a prerendered page is visited without
-being displayed, before the page has finished loading.
--->
-<head>
-<title>Prerender Visibility Hidden Quick Switch</title>
-
-<script>
-// Checks visibility state while the page is still loading.
-var lastState = document.webkitVisibilityState;
-var loadingStatePassed = document.webkitHidden && lastState != 'visible';
-var unexpectedStateChange = false;
-
-function onVisibilityChange(event) {
- if (lastState == 'hidden' ||
- document.webkitVisibilityState != 'hidden') {
- unexpectedStateChange = true;
- return;
- }
- lastState = document.webkitVisibilityState;
-}
-
-document.addEventListener('webkitvisibilitychange',
- onVisibilityChange,
- false);
-
-// Checks that either the first visibility state was 'prerender' and there
-// was one and only one visibility change event to 'hidden', or visibility
-// was always 'hidden'.
-function DidDisplayPass() {
- return loadingStatePassed &&
- !unexpectedStateChange &&
- 'hidden' == document.webkitVisibilityState &&
- document.webkitHidden;
-}
-</script>
-
-</head>
-<body></body>
-</html>
« no previous file with comments | « chrome/test/data/prerender/prerender_visibility_hidden.html ('k') | chrome/test/data/webui/net_internals/prerender_view.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698