Пример #1
0
 private void PluginCurrentStateChanged(Microsoft.SilverlightMediaFramework.Plugins.IMediaPlugin arg1, MediaPluginState arg2)
 {
     if (arg2 == MediaPluginState.Paused)
     {
         this.ResetSeekTimer();
     }
 }
Пример #2
0
 private void OnMediaOpened(Microsoft.SilverlightMediaFramework.Plugins.IMediaPlugin obj)
 {
     if (this.position != this.plugin.Position)
     {
         this.plugin.Position = this.position;
     }
 }
Пример #3
0
        private void OnSeekCompleted(Microsoft.SilverlightMediaFramework.Plugins.IMediaPlugin arg1, bool arg2)
        {
            if (Math.Abs(arg1.Position.TotalMilliseconds - this.position.TotalMilliseconds) < 20)
            {
                this.plugin.VisualElement.Visibility = Visibility.Collapsed;

                if (arg1.CurrentState == MediaPluginState.Paused)
                {
                    this.ResetSeekTimer();
                }
                else
                {
                    this.plugin.CurrentStateChanged -= this.PluginCurrentStateChanged;
                    this.plugin.CurrentStateChanged += this.PluginCurrentStateChanged;
                }
            }
        }