Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion cocos2d/core/platform/CCSys.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ const isQttGame = (settingPlatform === 'qtt-game');
const isLinkSure = (settingPlatform === 'link-sure');
const isMigu = (settingPlatform === 'migu-runtime');
const isHonorGame = (settingPlatform === 'honor-minigame');
const isOpenpass = (settingPlatform === 'openpass');

const _global = typeof window === 'undefined' ? global : window;

Expand Down Expand Up @@ -485,6 +486,13 @@ function initSys () {
*/
sys.HONOR_MINIGAME = 123;

/**
* @property {Number} OPENPASS_MINIGAME
* @readOnly
* @default 124
*/
sys.OPENPASS_MINIGAME = 124;

/**
* BROWSER_TYPE_WECHAT
* @property {String} BROWSER_TYPE_WECHAT
Expand Down Expand Up @@ -747,6 +755,8 @@ function initSys () {
platform = sys.MIGU_MINIGAME;
} else if (isHonorGame) {
platform = sys.HONOR_MINIGAME;
} else if (isOpenpass) {
platform = sys.OPENPASS_MINIGAME;
}
else {
platform = __getPlatform();
Expand All @@ -766,7 +776,8 @@ function initSys () {
isJKWGame ||
isQttGame ||
isMigu ||
isHonorGame);
isHonorGame ||
isOpenpass);

sys.os = __getOS();
sys.language = __getCurrentLanguage();
Expand Down
Loading