Esempio n. 1
0
        private void AddVideoPlaybackControl(WindowsPoint location, string videoFile)
        {
            var control = new ShowComposer.UserControls.VideoPlaybackControl();

            control.IsRelativePath = false;
            control.VideoFile      = videoFile;
            control.SoundVolume    = 0.5;

            ((VideoPlaybackControl)control).OnRemove += VideoPlaybackControl_OnRemove;

            Canvas.SetTop(control, location.Y);
            Canvas.SetLeft(control, location.X);

            AddCanvasElement(control, new WindowsPoint());
        }
Esempio n. 2
0
        private void AddVideoPlaybackControl(VideoPlayerInfo info)
        {
            if (Properties.Settings.Default.AudioPlaybackOneOutput)
            {
                AudioControls.All((i) => i.Stop());
            }

            var control = new ShowComposer.UserControls.VideoPlaybackControl();

            control.IsRelativePath = info.IsRelativePath;
            control.VideoFile      = info.VideoFile;
            control.SoundVolume    = info.AudioVolume;

            ((VideoPlaybackControl)control).OnRemove += VideoPlaybackControl_OnRemove;

            Canvas.SetTop(control, info.Top);
            Canvas.SetLeft(control, info.Left);

            AddCanvasElement(control, new WindowsPoint());
        }