mirror of
https://github.com/cocos/cocos4.git
synced 2026-11-21 08:02:39 +08:00
0a836ac458
* optimize sys info init in adapters update * update sys init update sys * fix sys access * optimize isWebIOS14OrIPadOS14Env * update * update * update QTT adapter * update sys.capacities update sys * update common && qtt * add downloadFile to job module * update engine-adapter * update DeviceMotionEvent adaption * remove legacy qtt * add link-sure adaption * fix some bug * update vivo adaption && fs-utils * remove legacy link-sure * remove dom-adapter * remove HTMLCanvas appended to document * update vivo * support COCOS_PLAY * update adapters to platforms * remove test code * add OPPO adapter * add huawei adapter * remove test code * rename folder oppo-mini-game * rename folder huawei-quick-game * rename folder vivo-mini-game
17 lines
526 B
JavaScript
17 lines
526 B
JavaScript
cc.game.restart = function () {
|
|
};
|
|
|
|
jsb.onHide(function (data) {
|
|
cc.game.emit(cc.Game.EVENT_HIDE);
|
|
});
|
|
|
|
jsb.onShow(function () {
|
|
cc.game.emit(cc.Game.EVENT_SHOW);
|
|
});
|
|
|
|
jsb.onWindowResize && jsb.onWindowResize(function (width, height) {
|
|
// Since the initialization of the creator engine may not take place until after the onWindowResize call,
|
|
// you need to determine whether the canvas already exists before you can call the setCanvasSize method
|
|
cc.game.canvas && cc.view.setCanvasSize(width, height);
|
|
});
|