sync-adapters/pull/219 (#8219)

This commit is contained in:
zhefeng.zhang
2021-01-27 18:33:11 +08:00
committed by GitHub
parent d3347dde1c
commit e7eaac6140
+7 -2
View File
@@ -67,8 +67,13 @@ Object.assign(game, {
}
}
__globalAdapter.onAudioInterruptionEnd && __globalAdapter.onAudioInterruptionEnd(onShown);
__globalAdapter.onAudioInterruptionBegin && __globalAdapter.onAudioInterruptionBegin(onHidden);
__globalAdapter.onAudioInterruptionEnd && __globalAdapter.onAudioInterruptionEnd(function () {
if (cc.audioEngine) cc.audioEngine._restore();
});
__globalAdapter.onAudioInterruptionBegin && __globalAdapter.onAudioInterruptionBegin(function () {
if (cc.audioEngine) cc.audioEngine._break();
});
__globalAdapter.onShow && __globalAdapter.onShow(onShown);
__globalAdapter.onHide && __globalAdapter.onHide(onHidden);