1234567891011121314151617181920212223242526272829303132333435 |
- import FguiMgr from "../../../frameWork/fgui/FguiMgr";
- import ClickAuEffect from "../../../utils/ClickAuEffect";
- export default class PopUpForthView {
- private MaskBg: fairygui.GButton;
-
- private closeUI: any;
- public constructor(vm: fgui.GComponent) {
- this.MaskBg = vm.getChild("MaskBg").asButton;
- }
- public onEnable(): void {
- this.MaskBg.onClick(this.OnClickCloseBtn, this);
- }
- public onDisable(): void {
- this.MaskBg.offClick(this.OnClickCloseBtn, this);
- }
- /**
- *
- * @param closeUI 关闭的界面
- */
- setData(closeUI: any) {
- this.closeUI = closeUI;
- }
- // 关闭
- @ClickAuEffect()
- private OnClickCloseBtn() {
- FguiMgr.Instance.closeUI(this.closeUI, true);
- }
- }
|