public static void OnRemove(this UIEventComponent self, UIComponent uiComponent, string uiType) { try { self.UIEvents[uiType].OnRemove(uiComponent); } catch (Exception e) { throw new Exception($"on remove ui error: {uiType}", e); } }
public static async ETTask <UI> OnCreate(this UIEventComponent self, UIComponent uiComponent, string uiType, UILayer uiLayer) { try { UI ui = await self.UIEvents[uiType].OnCreate(uiComponent, uiLayer); return(ui); } catch (Exception e) { throw new Exception($"on create ui error: {uiType}", e); } }
public static Transform GetLayer(this UIEventComponent self, int layer) { return(self.UILayers[layer]); }