Skip to content

Commit e8064f5

Browse files
committed
Fixed a bug that adaptation value error of IOS
1 parent 16e8a9d commit e8064f5

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

cocos2d/core/platform/CCEGLView.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,9 @@ cc.__BrowserGetter = {
6161
if(window.navigator.userAgent.indexOf("OS 8_1_") > -1) //this mistake like MIUI, so use of MIUI treatment method
6262
cc.__BrowserGetter.adaptationType = cc.sys.BROWSER_TYPE_MIUI;
6363

64+
if(cc.sys.os === cc.sys.OS_IOS) // All browsers are WebView
65+
cc.__BrowserGetter.adaptationType = cc.sys.BROWSER_TYPE_SAFARI;
66+
6467
switch(cc.__BrowserGetter.adaptationType){
6568
case cc.sys.BROWSER_TYPE_SAFARI:
6669
cc.__BrowserGetter.meta["minimal-ui"] = "true";

0 commit comments

Comments
 (0)