import { ui } from "../ui/layaMaxUI";
import { SC, ViewManager, ViewType } from "./ViewManager";

export default class RankView extends ui.RankViewUI implements SC{
    private static ins:RankView;
    constructor(){
        super();
    }
    public static get Instance():RankView{
        if(RankView.ins){
            return RankView.ins
        }
        else{
            return new RankView();
        }
    }
    Show(){
        this.CloseBtn.clickHandler = Laya.Handler.create(this,this.ClickClose)
        this.height = Laya.stage.height; 
        Laya.stage.on(Laya.Event.RESIZE,this,()=>
        {
            this.height = Laya.stage.height;
        })
    }
    Close(){
        
    }
    ClickClose(){
        ViewManager.Instance.ShowView(ViewType.MainView);
    }

} 