mirror of
https://github.com/photonstorm/phaser
synced 2024-09-21 15:01:57 +00:00
Swapped the ScaleManager creation order in Game, so both start and stop fullScreen requests work now.
This commit is contained in:
parent
7c7e924b7a
commit
db22b019be
2 changed files with 5 additions and 1 deletions
|
@ -426,10 +426,11 @@ Phaser.Game.prototype = {
|
|||
this.math = Phaser.Math;
|
||||
|
||||
this.stage = new Phaser.Stage(this, this.width, this.height);
|
||||
this.scale = new Phaser.ScaleManager(this, this.width, this.height);
|
||||
|
||||
this.setUpRenderer();
|
||||
|
||||
this.scale = new Phaser.ScaleManager(this, this.width, this.height);
|
||||
|
||||
this.device.checkFullScreenSupport();
|
||||
|
||||
this.world = new Phaser.World(this);
|
||||
|
|
|
@ -506,9 +506,11 @@ Phaser.Device.prototype = {
|
|||
for (var i = 0; i < fs.length; i++)
|
||||
{
|
||||
if (this.game.canvas[fs[i]])
|
||||
// if (document[fs[i]])
|
||||
{
|
||||
this.fullscreen = true;
|
||||
this.requestFullscreen = fs[i];
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -530,6 +532,7 @@ Phaser.Device.prototype = {
|
|||
if (document[cfs[i]])
|
||||
{
|
||||
this.cancelFullscreen = cfs[i];
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue