UI_ProgressBar1.cs 2.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. /** This is an automatically generated class by FairyGUI. Please do not modify it. **/
  2. using FairyGUI;
  3. namespace UI.Main
  4. {
  5. public partial class UI_ProgressBar1
  6. {
  7. public GProgressBar target;
  8. public UI_Component2 m_comBar;
  9. public GTextField m_txtCount;
  10. public UI_ComScoreStage m_comFirstScore;
  11. public UI_ComScoreStage m_comSecondScore;
  12. public const string URL = "ui://mfvz4q8kvuz5bh";
  13. public const string PACKAGE_NAME = "Main";
  14. public const string RES_NAME = "ProgressBar1";
  15. private static UI_ProgressBar1 _proxy;
  16. public static UI_ProgressBar1 Create(GObject gObject = null)
  17. {
  18. var ui = new UI_ProgressBar1();
  19. if(gObject == null)
  20. ui.target = (GProgressBar)UIPackage.CreateObject(PACKAGE_NAME, RES_NAME);
  21. else
  22. ui.target = (GProgressBar)gObject;
  23. ui.Init(ui.target);
  24. return ui;
  25. }
  26. public static UI_ProgressBar1 Proxy(GObject gObject = null)
  27. {
  28. if(_proxy == null)
  29. {
  30. _proxy = new UI_ProgressBar1();
  31. }
  32. var ui = _proxy;
  33. if(gObject == null)
  34. ui.target = (GProgressBar)UIPackage.CreateObject(PACKAGE_NAME, RES_NAME);
  35. else
  36. ui.target = (GProgressBar)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_comBar = (UI_Component2)UI_Component2.Create(comp.GetChild("comBar"));
  55. m_txtCount = (GTextField)comp.GetChild("txtCount");
  56. m_comFirstScore = (UI_ComScoreStage)UI_ComScoreStage.Create(comp.GetChild("comFirstScore"));
  57. m_comSecondScore = (UI_ComScoreStage)UI_ComScoreStage.Create(comp.GetChild("comSecondScore"));
  58. }
  59. public void Dispose(bool disposeTarget = false)
  60. {
  61. m_comBar.Dispose();
  62. m_comBar = null;
  63. m_txtCount = null;
  64. m_comFirstScore.Dispose();
  65. m_comFirstScore = null;
  66. m_comSecondScore.Dispose();
  67. m_comSecondScore = null;
  68. if(disposeTarget && target != null)
  69. {
  70. target.RemoveFromParent();
  71. target.Dispose();
  72. }
  73. target = null;
  74. }
  75. }
  76. }