Ejemplo n.º 1
0
 protected override void OnAwakeInitUI()
 {
     if (mUIMainModel == null)
     {
         mUIMainModel = UIModelMgr.Instance.GetModel <UIMainModel>();
         mUIMainModel.ValueUpdateEvent += OnValueUpdateEvent;
     }
     mUIWrapContent = CacheTrans.FindComponent <UIWrapContent>("Root/MessageGroup/ScrollView/Grid");
     mScrollGrid    = CacheTrans.FindComponent <ScrollGrid>("Root/MessageGroup/ScrollView/Grid");
     CacheTrans.GetUIEventListener("Root/TitleGroup/BtnReturn").onClick += OnReturnClick;
     mUIWrapContent.onInitializeItem = onInitializeItem;
 }
Ejemplo n.º 2
0
 private void Awake()
 {
     mCacheTransform  = this.transform;
     mUIGameModel     = UIModelMgr.Instance.GetModel <UIGameModel>();
     mHeadIcon        = mCacheTransform.FindComponent <UITexture>("HeadIcon");
     mOwnerIcon       = mCacheTransform.FindComponent <UISprite>("OwnerIcon");
     mBestGunner      = mCacheTransform.FindComponent <UISprite>("Group/ScrollView/BestGunner");
     mBigWinner       = mCacheTransform.FindComponent <UISprite>("BigWinner");
     mLabelName       = mCacheTransform.FindComponent <UILabel>("Name");
     mLabelId         = mCacheTransform.FindComponent <UILabel>("ID");
     mLabelTotalScore = mCacheTransform.FindComponent <UILabel>("LabelTotalScore");
     mScrollGrid      = mCacheTransform.FindComponent <ScrollGrid>("Group/ScrollView/Grid");
 }