mirror of
https://github.com/Gongxh0901/kunpolibrary
synced 2025-12-06 04:39:10 +00:00
仓库中添加内置的demo
This commit is contained in:
22
demo/assets/script/UI/Window/PopWindow.ts
Normal file
22
demo/assets/script/UI/Window/PopWindow.ts
Normal file
@@ -0,0 +1,22 @@
|
||||
/**
|
||||
* @Author: Gongxh
|
||||
* @Date: 2025-01-12
|
||||
* @Description:
|
||||
*/
|
||||
|
||||
import { fgui, kunpo } from "../../header";
|
||||
const { uiclass, uiprop, uiclick } = kunpo._uidecorator;
|
||||
|
||||
@uiclass("Window", "Window", "PopWindow")
|
||||
export class PopWindow extends kunpo.Window {
|
||||
@uiprop btn_close: fgui.GButton;
|
||||
protected onInit(): void {
|
||||
this.adapterType = kunpo.AdapterType.Bang;
|
||||
this.type = kunpo.WindowType.Normal;
|
||||
}
|
||||
|
||||
@uiclick
|
||||
private onCloseWindow(): void {
|
||||
kunpo.WindowManager.closeWindow(this.name);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user