Commit b5f88d29 authored by wjf's avatar wjf

l

parent c3b6da04
......@@ -53,7 +53,7 @@ export default class PanelCtrl {
show<T extends Panel>(cls: any, data?: any): T {
showWaiting()
const panel: T = new cls(data);
this.add(panel);
this.add(panel);//必须得先加入栈,否则多重弹框重叠顺序就按加载熟读了
this.stacks.push(panel);
panel.onLoaded = () => {
hideWaiting();
......@@ -61,10 +61,11 @@ export default class PanelCtrl {
//start只执行一边,考虑什么时候执行,多弹框的时候
panel.start(data);
}
//资源加载失败时
//资源加载失败时,RES的加载失败策略有问题,再检查
panel.onLoadError = () => {
hideWaiting();
showToast("资源加载失败")
panel.removeEventListener('onDestroy', this.onPanelHide, this);
this.remove(panel);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment