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

Side by Side Diff: third_party/WebKit/Source/core/html/HTMLVideoElement.cpp

Issue 2565203002: Add a requestFullscreen variant with a default (prefixed) type (Closed)
Patch Set: Created 4 years 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007, 2008, 2009, 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 2008, 2009, 2010 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after
248 if (!webMediaPlayer()) 248 if (!webMediaPlayer())
249 return false; 249 return false;
250 250
251 return webMediaPlayer()->hasVideo() && 251 return webMediaPlayer()->hasVideo() &&
252 webMediaPlayer()->getReadyState() >= 252 webMediaPlayer()->getReadyState() >=
253 WebMediaPlayer::ReadyStateHaveCurrentData; 253 WebMediaPlayer::ReadyStateHaveCurrentData;
254 } 254 }
255 255
256 void HTMLVideoElement::webkitEnterFullscreen() { 256 void HTMLVideoElement::webkitEnterFullscreen() {
257 if (!isFullscreen()) 257 if (!isFullscreen())
258 enterFullscreen(); 258 Fullscreen::requestFullscreen(*this, Fullscreen::RequestType::Prefixed);
259 } 259 }
260 260
261 void HTMLVideoElement::webkitExitFullscreen() { 261 void HTMLVideoElement::webkitExitFullscreen() {
262 if (isFullscreen()) 262 if (isFullscreen())
263 exitFullscreen(); 263 Fullscreen::exitFullscreen(document());
264 } 264 }
265 265
266 bool HTMLVideoElement::webkitSupportsFullscreen() { 266 bool HTMLVideoElement::webkitSupportsFullscreen() {
267 return Fullscreen::fullscreenEnabled(document()); 267 return Fullscreen::fullscreenEnabled(document());
268 } 268 }
269 269
270 bool HTMLVideoElement::webkitDisplayingFullscreen() { 270 bool HTMLVideoElement::webkitDisplayingFullscreen() {
271 return isFullscreen(); 271 return isFullscreen();
272 } 272 }
273 273
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
376 return ScriptPromise(); 376 return ScriptPromise();
377 if (!ImageBitmap::isResizeOptionValid(options, exceptionState)) 377 if (!ImageBitmap::isResizeOptionValid(options, exceptionState))
378 return ScriptPromise(); 378 return ScriptPromise();
379 return ImageBitmapSource::fulfillImageBitmap( 379 return ImageBitmapSource::fulfillImageBitmap(
380 scriptState, 380 scriptState,
381 ImageBitmap::create(this, cropRect, 381 ImageBitmap::create(this, cropRect,
382 eventTarget.toLocalDOMWindow()->document(), options)); 382 eventTarget.toLocalDOMWindow()->document(), options));
383 } 383 }
384 384
385 } // namespace blink 385 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLMediaElement.cpp ('k') | third_party/WebKit/Source/core/html/shadow/MediaControls.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698