UI_NewYearRedEnvelopeUI.cs 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. /** This is an automatically generated class by FairyGUI. Please do not modify it. **/
  2. using FairyGUI;
  3. namespace UI.NewYearRedEnvelope
  4. {
  5. public partial class UI_NewYearRedEnvelopeUI
  6. {
  7. public GComponent target;
  8. public Controller m_titleImgType;
  9. public Controller m_openType;
  10. public GButton m_btnOpen;
  11. public GRichTextField m_txtTime;
  12. public const string URL = "ui://pt3t9f1ujsko0";
  13. public const string PACKAGE_NAME = "NewYearRedEnvelope";
  14. public const string RES_NAME = "NewYearRedEnvelopeUI";
  15. private static UI_NewYearRedEnvelopeUI _proxy;
  16. public static UI_NewYearRedEnvelopeUI Create(GObject gObject = null)
  17. {
  18. var ui = new UI_NewYearRedEnvelopeUI();
  19. if(gObject == null)
  20. ui.target = (GComponent)UIPackage.CreateObject(PACKAGE_NAME, RES_NAME);
  21. else
  22. ui.target = (GComponent)gObject;
  23. ui.Init(ui.target);
  24. return ui;
  25. }
  26. public static UI_NewYearRedEnvelopeUI Proxy(GObject gObject = null)
  27. {
  28. if(_proxy == null)
  29. {
  30. _proxy = new UI_NewYearRedEnvelopeUI();
  31. }
  32. var ui = _proxy;
  33. if(gObject == null)
  34. ui.target = (GComponent)UIPackage.CreateObject(PACKAGE_NAME, RES_NAME);
  35. else
  36. ui.target = (GComponent)gObject;
  37. ui.Init(ui.target);
  38. return ui;
  39. }
  40. public static void ProxyEnd()
  41. {
  42. if (_proxy != null)
  43. {
  44. _proxy.Dispose();
  45. }
  46. }
  47. public static void ClearProxy()
  48. {
  49. ProxyEnd();
  50. _proxy = null;
  51. }
  52. private void Init(GComponent comp)
  53. {
  54. m_titleImgType = comp.GetController("titleImgType");
  55. m_openType = comp.GetController("openType");
  56. m_btnOpen = (GButton)comp.GetChild("btnOpen");
  57. m_txtTime = (GRichTextField)comp.GetChild("txtTime");
  58. }
  59. public void Dispose(bool disposeTarget = false)
  60. {
  61. m_titleImgType = null;
  62. m_openType = null;
  63. m_btnOpen = null;
  64. m_txtTime = null;
  65. if(disposeTarget && target != null)
  66. {
  67. target.RemoveFromParent();
  68. target.Dispose();
  69. }
  70. target = null;
  71. }
  72. }
  73. }