示例#1
0
 public IWindow(string name, UIWindowData data)
 {
     mBaseNode   = null;
     mIsShow     = false;
     mIsLoad     = false;
     mName       = name;
     mData       = data;
     mExtraDatas = new Dictionary <string, string>();
 }
示例#2
0
        public UIWindowData GetData(string name)
        {
            UIWindowData ret = null;

            for (int i = 0; i < mDataList.Count; ++i)
            {
                if (mDataList [i].mName.Equals(name))
                {
                    ret = mDataList [i];
                }
            }

            return(ret);
        }
示例#3
0
        public void Load()
        {
            UIWindowData item = null;

            while (!FileReader.IsEnd())
            {
                FileReader.ReadLine();
                item               = new UIWindowData();
                item.mID           = FileReader.ReadInt();
                item.mName         = FileReader.ReadString();
                item.mScriptName   = FileReader.ReadString();
                item.mPrefabPath   = FileReader.ReadString();
                item.mAltasPath    = FileReader.ReadString();
                item.mParentName   = FileReader.ReadString();
                item.mUseFramework = FileReader.ReadBoolean();
                item.mExclusiveIDs = FileReader.ReadString();

                mDataList.Add(item);
            }

            /*// 加入注册所有窗口
             *          List<string> exclusive = new List<string>();
             *          List<int> eid;
             * foreach (var i in mDataList)
             * {
             *                  exclusive.Clear ();
             *                  eid = Converter.ConvertNumberList<int> (i.mExclusiveIDs);
             *                  foreach (var id in eid)
             *                  {
             *                          foreach (var j in mDataList)
             *                          {
             *                                  if (id == j.mID)
             *                                  {
             *                                          exclusive.Add (j.mName);
             *                                  }
             *                          }
             *                  }
             *
             *                  WindowManager.Instance.RegisterWindow(i.mName, i.mPrefabPath, i.mScriptName, exclusive);
             * }*/
        }
示例#4
0
        private void RegisterWindow(string name, UIWindowData data)
        {
            IWindow window = new IWindow(name, data);

            this.mWindowMap.Add(window.GetName(), window);
        }