public void ShowDetailFun() { if (LauncherUIManager.instance.columnType == ColumnType.RecommendVideo) { VideoPoster.texture = JsonDataManager.VideosDic[JsonDataManager.currentId].coverTexture; VideoDetailName.text = JsonDataManager.VideosDic[JsonDataManager.currentId].title; IntroduceText.text = JsonDataManager.VideosDic[JsonDataManager.currentId].subscript; CountryName.text = ""; //表示该视频是否被收藏了 } else { ClassifyVideoItem item = TV189MsgReciver.classifyVideosDic[JsonDataManager.currentId]; TV189MsgReciver.instance.SetImage(item.imgM0, VideoPoster); VideoDetailName.text = item.title; IntroduceText.text = item.description; CountryName.text = item.countryName; } VideoDetailRoot.gameObject.SetActive(true); if (JsonDataManager.VideosDic[JsonDataManager.currentId].isCollected == false) { CollectionButton.GetComponent <Image>().sprite = NormalCollectedSprite; } else { CollectionButton.GetComponent <Image>().sprite = CollectedSprite; } }
public override void ProcessEvent(MsgBase tmpMag) { switch (tmpMag.msgid) { case (ushort)UIEvent.HideVideoDetailRoot: { VideoDetailRoot.gameObject.SetActive(false); } break; case (ushort)UIEvent.ShowVideoDetailRoot: { Debug.Log("ShowVideoDetailRoot"); if (LauncherUIManager.instance.columnType == ColumnType.RecommendVideo) { VideoPoster.texture = JsonDataManager.VideosDic[JsonDataManager.currentId].coverTexture; VideoDetailName.text = JsonDataManager.VideosDic[JsonDataManager.currentId].title; IntroduceText.text = JsonDataManager.VideosDic[JsonDataManager.currentId].subscript; CountryName.text = ""; //表示该视频是否被收藏了 } else { ClassifyVideoItem item = TV189MsgReciver.classifyVideosDic[JsonDataManager.currentId]; TV189MsgReciver.instance.SetImage(item.imgM0, VideoPoster); VideoDetailName.text = item.title; IntroduceText.text = item.description; CountryName.text = item.countryName; } VideoDetailRoot.gameObject.SetActive(true); if (JsonDataManager.VideosDic[JsonDataManager.currentId].isCollected == false) { CollectionButton.GetComponent <Image>().sprite = NormalCollectedSprite; } else { CollectionButton.GetComponent <Image>().sprite = CollectedSprite; } } break; } }