feat(minigame): 支付宝小程序添加安全区域获取功能 (#44)

This commit is contained in:
orchid-world
2026-02-11 11:22:30 +08:00
committed by GitHub
parent 315800edf9
commit 35e7bb2d5e
+5 -1
View File
@@ -149,8 +149,12 @@ minigame.stopAccelerometer = function (res: any): void {
// #region SafeArea
minigame.getSafeArea = function (): SafeArea {
if (typeof minigame.getWindowInfo === "function") {
const windowInfo = minigame.getWindowInfo();
return windowInfo.safeArea;
}
console.warn('getSafeArea is not supported on this platform');
const systemInfo = minigame.getSystemInfoSync();
const systemInfo = minigame.getSystemInfoSync();
return {
top: 0,
left: 0,