diff options
Diffstat (limited to 'Client/Assets/Scripts/XMainClient/UI/UICommon')
| -rw-r--r-- | Client/Assets/Scripts/XMainClient/UI/UICommon/DlgBase.cs | 7 | 
1 files changed, 5 insertions, 2 deletions
| diff --git a/Client/Assets/Scripts/XMainClient/UI/UICommon/DlgBase.cs b/Client/Assets/Scripts/XMainClient/UI/UICommon/DlgBase.cs index 234b0f2c..0d90e4b0 100644 --- a/Client/Assets/Scripts/XMainClient/UI/UICommon/DlgBase.cs +++ b/Client/Assets/Scripts/XMainClient/UI/UICommon/DlgBase.cs @@ -6,6 +6,7 @@ using XUtliPoolLib;  namespace XMainClient.UI.UICommon
  {
 +    //c  界面逻辑控制器基类
  	public abstract class DlgBase<TDlgClass, TUIBehaviour> : IXUIDlg, IDlgHandlerMgr where TDlgClass : IXUIDlg, new() where TUIBehaviour : DlgBehaviourBase
  	{
  		public static TDlgClass singleton
 @@ -580,6 +581,8 @@ namespace XMainClient.UI.UICommon  		private void OnLoadUIFinishedEventHandler(string location)
  		{
 +            Debug.Log("加载界面prfab: " + location);
 +            //c 加载prefab
  			GameObject gameObject = XSingleton<XResourceLoaderMgr>.singleton.CreateFromPrefab("UI/" + location, true, false) as GameObject;
  			bool flag = null != gameObject;
  			if (flag)
 @@ -587,8 +590,8 @@ namespace XMainClient.UI.UICommon  				gameObject.transform.parent = XSingleton<UIManager>.singleton.UIRoot;
  				gameObject.transform.localPosition = new Vector3(0f, 0f, 0f);
  				gameObject.transform.localScale = new Vector3(1f, 1f, 1f);
 -				this.m_uiBehaviour = gameObject.AddComponent<TUIBehaviour>();
 -				this.m_uiBehaviour.uiDlgInterface = this;
 +				this.m_uiBehaviour = gameObject.AddComponent<TUIBehaviour>(); //c 这里给界面挂上对应的脚本
 +                this.m_uiBehaviour.uiDlgInterface = this;
  				bool flag2 = !this.m_bBindedReverse;
  				if (flag2)
  				{
 | 
