perf: 支持跳转到分享页面
This commit is contained in:
@@ -15,6 +15,9 @@ export class main extends Component {
|
||||
@property({ type: Prefab, tooltip: '关卡页面预制体' })
|
||||
pageLevelPrefab: Prefab | null = null;
|
||||
|
||||
@property({ type: Prefab, tooltip: '写关卡页面预制体' })
|
||||
pageWriteLevelsPrefab: Prefab | null = null;
|
||||
|
||||
@property({ type: Prefab, tooltip: 'Toast 预制体' })
|
||||
toastPrefab: Prefab | null = null;
|
||||
|
||||
@@ -50,6 +53,14 @@ export class main extends Component {
|
||||
});
|
||||
}
|
||||
|
||||
if (this.pageWriteLevelsPrefab) {
|
||||
ViewManager.instance.register('PageWriteLevels', {
|
||||
prefab: this.pageWriteLevelsPrefab,
|
||||
cache: true,
|
||||
zIndex: 2
|
||||
});
|
||||
}
|
||||
|
||||
// 初始化 Toast 管理器
|
||||
if (this.toastPrefab) {
|
||||
ToastManager.instance.init(this.toastPrefab, this.node);
|
||||
|
||||
Reference in New Issue
Block a user