Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

requestFullScreen() does not work #279

Closed
jduncanator opened this issue Jan 3, 2013 · 14 comments
Closed

requestFullScreen() does not work #279

jduncanator opened this issue Jan 3, 2013 · 14 comments

Comments

@jduncanator
Copy link

In Chrome 23.0.1271.97 no matter what I try, calling requestFullScreen() does not work! The fullscreen button on the controls works as expected and opens the video in fullscreen however calling requestFullScreen() does nothing. Calling it does set the isFullscreen to true but does nothing.

@erixtekila
Copy link

After some tests, the production version of the source doesn't contain the requestFullScreen() method, while the dev do. Try using this one.

heff added a commit to heff/video.js that referenced this issue Jun 3, 2013
…ixes videojs#503

Other html5 video properties are covered by closure compiler's internal exports set, but not the fullscreen options which are still being designed/approved by w3c.
@jduncanator
Copy link
Author

Thanks! It's working now 👍

@heff
Copy link
Member

heff commented Jun 6, 2013

Great!

@heff heff closed this as completed Jun 6, 2013
@aberloni
Copy link

Hey heff,

Is that fix in the 4.0.4 release of video.js ? I can't find it in the video.js/ video.dev.js file.

Thx

@heff
Copy link
Member

heff commented Jun 27, 2013

No, not yet. It'll go out with 4.1. It is in master though.
https://github.com/videojs/video.js/blob/master/src/js/exports.js#L62

@CAJensen01
Copy link

What is the eta for 4.1?

@heff
Copy link
Member

heff commented Jun 27, 2013

I think next week.

On Jun 27, 2013, at 11:16 AM, Casey Jensen [email protected] wrote:

What is the eta for 4.1?


Reply to this email directly or view it on GitHub.

@CAJensen01
Copy link

Great, thanks Steve. I'm looking forward to seeing this resolved.

@CAJensen01
Copy link

Hi Steve. I've downloaded the 4.1 update, and am including the call, but it still appears to not work. The call I'm using is:

_V_("main_video").ready(function(){
    var myPlayer = this;

    myPlayer.on("ended", function test(){
        myPlayer.posterImage.show();
    }); 
    myPlayer.on("play", function(){ 
        myPlayer.requestFullScreen(); 
    }); 
});

I've tried this in a variety of browsers (Chrome, Safari, MobileSafari), but none seem to work. Can you explain what I'm missing here?

Cheers.

@vakuzmin
Copy link

vakuzmin commented Apr 9, 2018

any updates on the issue since its still not working for me

"video.js": "^6.6.3",

$modalPlayer.on('shown.bs.modal', function () {
  self.player.play();
  self.player.requestFullScreen();
});

@gkatsev
Copy link
Member

gkatsev commented Apr 9, 2018

@vakuzmin the browsers require that requestFullscreen be called as part of a user gesture.

@vakuzmin
Copy link

@gkatsev ahh i see, thanks a lot for the getting back

@TrySpace
Copy link

PSA: note the capital S in requestFullScreen afaik is deprecated (but possibly still in firefox) and should have a small s; requestFullscreen.

This took me a while to figure out

@GalGurGurevich
Copy link

GalGurGurevich commented Apr 24, 2022

my working example

https://codepen.io/galgurevich/pen/JjMqXGO

https://codepen.io/galgurevich/pen/oNpRxGP

player.on("play", function(){
player.requestFullscreen();
});

should work

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants