creator 安卓打包竖屏转横屏配置问题
最近修改产品,从竖屏转横屏,在浏览器和模拟器调试都没问题,但是打出的安卓包居然出问题:
整体界面是横屏的,但是里面的scense内容居然是竖屏的,并且靠左,上面内容全都跑出屏幕没显示出来!!!
修改尝试多次终于发现问题根源,也可以说是creator打包的一个小bug导致,对比settings\builder.json文件如下:
问题配置:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
| "orientation": { "landscapeLeft": true, "landscapeRight": true, "portrait": false, "upsideDown": false }, "packageName": "net.xxxxxxx", "privateKey": "", "qqplay": { "REMOTE_SERVER_ROOT": "", "orientation": "portrait" }, "startScene": "d3fba040-203f-4c0a-83f9-883afcec27cc", "title": "block", "webOrientation": "portrait",
|
正确配置:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
| "orientation": { "landscapeLeft": true, "landscapeRight": true, "portrait": false, "upsideDown": false }, "packageName": "net.xxxxxxx", "privateKey": "", "qqplay": { "REMOTE_SERVER_ROOT": "", "orientation": "portrait" }, "startScene": "d3fba040-203f-4c0a-83f9-883afcec27cc", "title": "block", "webOrientation": "landscape",
|
居然是 “webOrientation”: “portrait”, 导致的!
安卓打包居然还要看web-mobile配置里的眼色!!!!请问这是什么逻辑!!!!
把配置改成以下即可:
1
| "webOrientation": "landscape",
|