File tree 1 file changed +3
-16
lines changed
1 file changed +3
-16
lines changed Original file line number Diff line number Diff line change 1
- using System ;
2
- using System . Collections . Generic ;
3
- using System . Diagnostics . Tracing ;
4
1
using LitJson ;
5
2
using UnityEngine ;
6
3
using WeChatWASM ;
@@ -24,12 +21,12 @@ protected override void TestAPI(string[] args)
24
21
{
25
22
setMenuStyle ( ) ;
26
23
}
27
-
24
+
28
25
public void setMenuStyle ( )
29
26
{
30
27
string style = isMenuStyleDark ? "light" : "dark" ;
31
28
string toastMessage = $ "设置{ ( isMenuStyleDark ? "浅色" : "深色" ) } 菜单样式完成";
32
-
29
+
33
30
WX . SetMenuStyle (
34
31
new SetMenuStyleOption
35
32
{
@@ -61,7 +58,7 @@ public void getMenuButtonBoundingClientRect()
61
58
62
59
// 访问成功,显示结果
63
60
WX . ShowModal (
64
- new ShowModalOption ( ) { content = "GetMenuButtonBoundingClientRect, Result: " + JsonMapper . ToJson ( res ) }
61
+ new ShowModalOption ( ) { content = "GetMenuButtonBoundingClientRect Success , Result: " + JsonMapper . ToJson ( res ) }
65
62
) ;
66
63
}
67
64
@@ -94,14 +91,4 @@ public void setStatusBarStyle()
94
91
! isStatusBarStyleBlack ? "设置状态栏深色" : "设置状态栏白色" // 修改逻辑
95
92
) ;
96
93
}
97
-
98
- private void OnDestroy ( )
99
- {
100
- WX . SetStatusBarStyle (
101
- new SetStatusBarStyleOption
102
- {
103
- style = "white" ,
104
- }
105
- ) ;
106
- }
107
94
}
You can’t perform that action at this time.
0 commit comments