/// <summary> /// 播放按钮点击事件 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void Btn_Download_MouseClick(object sender, DuiMouseEventArgs e) { //播放视频 DuiButton dbn = sender as DuiButton; Entity.MovieListEntity.DataItem moveInfo = new Entity.MovieListEntity.DataItem(); if (dbn.Tag != null) { moveInfo = dbn.Tag as Entity.MovieListEntity.DataItem; } string url = ""; try { API.TvAPI tva = new API.TvAPI(); Entity.MovePlayEntity plav = tva.getVideoUrl(userEntity.email, userEntity.psw, moveInfo.videoID.ToString(), "all", userEntity.imei); Console.WriteLine(plav.toJsonString()); Console.WriteLine(plav.data); PlayerForm plF = new PlayerForm(); url = plav.data.ToString(); plF.tvUrl = plav.data.ToString(); plF.tvName = moveInfo.videoName; plF.Show(); plF.AxPlayer_PlayOrPause(url); } catch (Exception ex) { Logger.Singleton.Error("name:" + moveInfo.videoName + "---地址:" + url, ex); throw; } }
private void Btn_Download_MouseEnter(object sender, EventArgs e) { Entity.MovieListEntity.DataItem moveinfo = (sender as DuiButton).Tag as Entity.MovieListEntity.DataItem; toolTip1.Show(moveinfo.videoName, this, PointToClient(MousePosition).X, PointToClient(MousePosition).Y + 15, 2000); }