This commit is contained in:
2024-08-26 22:56:29 +08:00
parent 3a160fabfe
commit 2cdbd5c22d
18 changed files with 4968 additions and 484 deletions

15
app.js
View File

@@ -22,12 +22,21 @@ App({
const that = this;
// 获取系统信息
const systemInfo = wx.getSystemInfoSync();
// const systemInfo = wx.getSystemInfoSync();
const windowInfo = wx.getWindowInfo()
// 胶囊按钮位置信息
const menuButtonInfo = wx.getMenuButtonBoundingClientRect();
// 导航栏高度 = 状态栏高度 + 44
that.globalData.navBarHeight = systemInfo.statusBarHeight + 44;
that.globalData.menuRight = systemInfo.screenWidth - menuButtonInfo.right;
// that.globalData.navBarHeight = systemInfo.statusBarHeight + 44;
that.globalData.navBarHeight = windowInfo.statusBarHeight + 44;
// that.globalData.menuRight = systemInfo.screenWidth - menuButtonInfo.right;
that.globalData.menuRight = windowInfo.screenWidth - menuButtonInfo.right;
that.globalData.menuTop = menuButtonInfo.top;
that.globalData.menuHeight = menuButtonInfo.height;