Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

adapt pc wechat game #87

Merged
merged 4 commits into from Feb 18, 2020
Merged

adapt pc wechat game #87

merged 4 commits into from Feb 18, 2020

Conversation

PPpro
Copy link
Collaborator

@PPpro PPpro commented Feb 18, 2020

Re: cocos/2d-tasks#2513

changeLog:

  • 适配微信 pc 版小游戏,windows 版本

关联:cocos/cocos-engine#6183

@PPpro PPpro changed the base branch from master to v2.3.1 Feb 18, 2020
platforms/wechat/wrapper/engine/index.js Outdated Show resolved Hide resolved
platforms/wechat/wrapper/engine/pcAdapter.js Outdated Show resolved Hide resolved
platforms/wechat/wrapper/engine/pcAdapter.js Outdated Show resolved Hide resolved
platforms/wechat/wrapper/engine/pcAdapter.js Outdated Show resolved Hide resolved
platforms/wechat/wrapper/engine/pcAdapter.js Outdated Show resolved Hide resolved
platforms/wechat/wrapper/systemInfo.js Outdated Show resolved Hide resolved
else if (platform === 'devtools') {
sys.isMobile = false;
if (system.indexOf('android') > -1) {
sys.os = sys.OS_ANDROID;
}
else if (system.indexOf('ios') > -1) {
sys.os = sys.OS_IOS;
}
}
Copy link
Collaborator Author

@PPpro PPpro Feb 18, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这块是微信开发者工具里做的判断,应该移到 微信的 wrapper 里
且开发者工具模拟的是移动端环境,isMobile 应该默认为 true

@PPpro PPpro merged commit 9aa9dae into cocos-creator-packages:v2.3.1 Feb 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants