Inheritance: Livet.ViewModel
Esempio n. 1
0
        public async void Initialize()
        {
            while (DescriptionBrowser == null)
            {
                Thread.Sleep(1);
            }
            await DispatcherHelper.UIDispatcher.BeginInvoke(new Action(() => {
                DescriptionBrowser.NavigateToString(Content.Description);
                Handler.LoadMovie();
            }));

            LiveCommentInstance = new NicoNicoLiveComment(Content.GetPlayerStatus.MesseageServerUrl, Content.GetPlayerStatus.MesseageServerPort, this);

            Time = new VideoTime();


            Time.VideoTimeString = NicoNicoUtil.GetTimeFromVpos(Content.GetPlayerStatus, (int.Parse(Content.GetPlayerStatus.EndTime) - int.Parse(Content.GetPlayerStatus.BaseTime)) * 100);
            Time.Length          = int.Parse(Content.GetPlayerStatus.EndTime) - int.Parse(Content.GetPlayerStatus.BaseTime);
            Time.BufferedTime    = Time.Length;

            Comment = new LiveCommentViewModel(this);


            OpenVideo();

            //タイムシフトじゃなかったらすぐに再生
            if (!Content.GetPlayerStatus.Archive)
            {
                foreach (var content in Content.GetPlayerStatus.ContentsList)
                {
                    Handler.InvokeScript("AsCommandExcute", "/liveplay", "0", content.Content);
                }
            }
        }
Esempio n. 2
0
        public async void Initialize() {

            while(DescriptionBrowser == null) {

                Thread.Sleep(1);
            }
            await DispatcherHelper.UIDispatcher.BeginInvoke(new Action(() => {

                DescriptionBrowser.NavigateToString(Content.Description);
                Handler.LoadMovie();
                
            }));
            LiveCommentInstance = new NicoNicoLiveComment(Content.GetPlayerStatus.MesseageServerUrl, Content.GetPlayerStatus.MesseageServerPort, this);

            Time = new VideoTime();


            //Time.VideoTimeString = NicoNicoUtil.GetTimeFromVpos(Content.GetPlayerStatus, (int.Parse(Content.GetPlayerStatus.EndTime) - int.Parse(Content.GetPlayerStatus.BaseTime)) * 100);
            Time.Length = int.Parse(Content.GetPlayerStatus.EndTime) - int.Parse(Content.GetPlayerStatus.BaseTime);
            //Time.BufferedTime = Time.Length;

            Comment = new LiveCommentViewModel(this);


            OpenVideo();

            //タイムシフトじゃなかったらすぐに再生
            if(!Content.GetPlayerStatus.Archive) {

                foreach(var content in Content.GetPlayerStatus.ContentsList) {

                }

  

            }
        }