mirror of
https://github.com/RandomityGuy/MBHaxe.git
synced 2025-10-30 08:11:25 +00:00
fix again
This commit is contained in:
parent
424127e527
commit
a33fb533df
2 changed files with 6 additions and 2 deletions
|
|
@ -47,8 +47,10 @@ class Main extends hxd.App {
|
|||
#end
|
||||
#if js
|
||||
var zoomRatio = (Util.isTouchDevice() && !Util.isTablet()) ? js.Browser.window.screen.height * js.Browser.window.devicePixelRatio / 768 : js.Browser.window.devicePixelRatio; // js.Browser.window.devicePixelRatio;
|
||||
if (Util.isIPhone() && js.Browser.window.devicePixelRatio > 2.001)
|
||||
if (Util.isIPhone())
|
||||
zoomRatio = 2;
|
||||
if (Util.isIPhone() && js.Browser.window.devicePixelRatio == 2)
|
||||
zoomRatio = 1.0;
|
||||
s2d.scaleMode = Zoom(zoomRatio);
|
||||
Settings.zoomRatio = zoomRatio;
|
||||
Settings.optionsSettings.screenWidth = cast Math.max(js.Browser.window.screen.width,
|
||||
|
|
|
|||
|
|
@ -453,8 +453,10 @@ class Settings {
|
|||
var zoomRatio = Window.getInstance().windowToPixelRatio;
|
||||
#if js
|
||||
var zoomRatio = (Util.isTouchDevice() && !Util.isTablet()) ? js.Browser.window.screen.height * js.Browser.window.devicePixelRatio / 768 : js.Browser.window.devicePixelRatio; // 768 / js.Browser.window.innerHeight; // js.Browser.window.innerHeight * js.Browser.window.devicePixelRatio / 768;
|
||||
if (Util.isIPhone() && js.Browser.window.devicePixelRatio > 2.001)
|
||||
if (Util.isIPhone())
|
||||
zoomRatio = 2;
|
||||
if (Util.isIPhone() && js.Browser.window.devicePixelRatio == 2)
|
||||
zoomRatio = 1.0;
|
||||
Settings.zoomRatio = zoomRatio;
|
||||
#end
|
||||
#if android
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue