Copy link to clipboard
Copied
How to make fullscreen directly when I test movie in animate CC ?
I try this script, but it seems doesnt work :
//here's the code
this.on("tick", full.bind(this));
var ancs = 0
function full(e) {
fullscreen()
}
var isInFullScreen = (document.fullscreenElement && document.fullscreenElement !== null) ||
(document.webkitFullscreenElement && document.webkitFullscreenElement !== null) ||
(document.mozFullScreenElement && document.mozFullScreenElement !== null) ||
(document.msFullscreenElement && document.msFullscreenElement !== null);
var docElm = document.documentElement;
function fullscreen() {
if (!isInFullScreen) {
if (docElm.requestFullscreen) {
docElm.requestFullscreen();
} else if (docElm.mozRequestFullScreen) {
docElm.mozRequestFullScreen();
} else if (docElm.webkitRequestFullScreen) {
docElm.webkitRequestFullScreen();
} else if (docElm.msRequestFullscreen) {
docElm.msRequestFullscreen();
}
}
}
//end of code
I need some help, please...
you can't do that. (thankfully) browsers prevent that. you must have user interaction with a browser displayed stage.
Copy link to clipboard
Copied
put something on stage to click (it can have alpha = 0).
and you probably want to edit your publish settings to center your stage and possibly make your stage responsive and fit. ie, test the various settings to get the effect you want.
Copy link to clipboard
Copied
Hi, Kglad...
I want my project directly in fullscreen view, without any click of button. The 'tick' function seems not working.
Copy link to clipboard
Copied
you can't do that. (thankfully) browsers prevent that. you must have user interaction with a browser displayed stage.
Copy link to clipboard
Copied
Oh, I didn't know browsers prevent that.
Thanks anyway... Kglad. You're the best
Copy link to clipboard
Copied
you're welcome.
(and think how would you like opening some web page and finding an ad on that page caused your browser to go fullscreen and all you see is that ad until you press the esc key.)
Get ready! An upgraded Adobe Community experience is coming in January.
Learn more