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

Unified Diff: LayoutTests/fullscreen/full-screen-request-disallow-for-non-media-elements.html

Issue 428633004: Webkit setting for embedders that do not support fullscreen. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rename to fullscreenSupported 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 | « no previous file | LayoutTests/fullscreen/full-screen-request-disallow-for-non-media-elements-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fullscreen/full-screen-request-disallow-for-non-media-elements.html
diff --git a/LayoutTests/fullscreen/full-screen-request-disallow-for-non-media-elements.html b/LayoutTests/fullscreen/full-screen-request-disallow-for-non-media-elements.html
new file mode 100644
index 0000000000000000000000000000000000000000..4e2c0b5fa038caff96bd817fd108cbe73da82e87
--- /dev/null
+++ b/LayoutTests/fullscreen/full-screen-request-disallow-for-non-media-elements.html
@@ -0,0 +1,22 @@
+<body>
+<script src="full-screen-test.js"></script>
+<span id="span" width="300"></span>
+<video id="video" width="300"></video>
+<div>Tests for the disallowFullscreenForNonMediaElements setting which will be set
+in those platforms where fullscreen for non-media elements is not supported.
+<script>
+ if (window.internals) {
+ window.internals.settings.setDisallowFullscreenForNonMediaElements(true);
+
+ var testStep2 = function() {
+ // Fullscreen for media elements is supported, video in this case.
+ waitForEventAndEnd(document, 'webkitfullscreenchange');
+ runWithKeyDown(function(){document.getElementById('video').webkitRequestFullScreen()});
+ };
+
+ // Fullscreen for non media elements is not supported.
+ waitForEventOnce(document, 'webkitfullscreenerror', testStep2);
+ runWithKeyDown(function(){document.getElementById('span').webkitRequestFullScreen()})
+ }
+</script>
+</body>
« no previous file with comments | « no previous file | LayoutTests/fullscreen/full-screen-request-disallow-for-non-media-elements-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698