コード例 #1
0
ファイル: XbmcHandler.cs プロジェクト: annaeymnd/xbmc-on-imon
        private void xbmcPlaybackPaused(object sender, XbmcPlayerPlaybackPositionChangedEventArgs e)
        {
            if (e == null || e.Player == null)
            {
                return;
            }

            Logging.Log(LoggingArea, "Playback paused");

            if (Settings.Default.XbmcOnPauseText.CompareTo("") != 0)
            {
                // TODO: Display the text exactly as desired (i.e. introduce the line breaker into patterns to be able to display 2 lines on VFD displays)
                this.display.SetText(Settings.Default.XbmcOnPauseText, Settings.Default.XbmcOnPauseText, e.Position.ToString(), Settings.Default.XbmcOnEventTextDelayMS);
            }

            this.playerState = PlayerState.Paused;

            this.progressTimer.Stop();
            this.position = e.Position;
            this.updateProgress();

            this.update();
        }
コード例 #2
0
ファイル: XbmcHandler.cs プロジェクト: annaeymnd/xbmc-on-imon
        //private void xbmcPlaybackEnded(object sender, EventArgs e)
        //{
        //    Logging.Log(LoggingArea, "Playback ended");
        //    if (Settings.Default.XbmcOnEndText.CompareTo("") != 0)
        //    {
        //        this.display.SetText(Settings.Default.XbmcOnEndText, Settings.Default.XbmcOnEventTextDelayMS);
        //    }
        //    this.playbackStopped();
        //    this.update();
        //}
        private void xbmcPlaybackSeek(object sender, XbmcPlayerPlaybackPositionChangedEventArgs e)
        {
            if (e == null || e.Player == null)
            {
                return;
            }

            Logging.Log(LoggingArea, "Playback seek");

            this.length = e.Length;
            this.position = e.Position;
            if (this.position.TotalMilliseconds < 0)
            {
                this.position = new TimeSpan();
            }

            this.updateProgress();
        }
コード例 #3
0
 private static void xbmc_PlaybackSeek(object sender, XbmcPlayerPlaybackPositionChangedEventArgs e)
 {
     Console.Out.WriteLine("Playback in {0} seeked to {1} of {2}", e.Player.ToString(), e.Position, e.Length);
 }
コード例 #4
0
 private static void xbmc_PlaybackSeek(object sender, XbmcPlayerPlaybackPositionChangedEventArgs e)
 {
     Console.Out.WriteLine("Playback in {0} seeked to {1} of {2}", e.Player.ToString(), e.Position, e.Length);
 }
コード例 #5
0
        private void xbmcPlaybackSeek(object sender, XbmcPlayerPlaybackPositionChangedEventArgs e)
        {
            if (e == null || e.Player == null)
            {
                return;
            }

            Logging.Log("XBMC Handler", "Playback seek");

            this.length = e.Length;
            this.position = e.Position;
            this.updateProgress();
        }
コード例 #6
0
        private void xbmcPlaybackResumed(object sender, XbmcPlayerPlaybackPositionChangedEventArgs e)
        {
            if (e == null || e.Player == null)
            {
                return;
            }

            Logging.Log("XBMC Handler", "Playback resumed");

            this.position = e.Position;
            this.updateProgress();
            this.progressTimer.Start();

            this.update();
        }
コード例 #7
0
        private void xbmcPlaybackPaused(object sender, XbmcPlayerPlaybackPositionChangedEventArgs e)
        {
            if (e == null || e.Player == null)
            {
                return;
            }

            Logging.Log("XBMC Handler", "Playback paused");

            this.progressTimer.Stop();
            this.position = e.Position;
            this.updateProgress();

            this.display.SetText("Pause", "Pause", e.Position.ToString());
        }