52 lines
1.2 KiB
C#
52 lines
1.2 KiB
C#
using System;
|
|
using System.Linq;
|
|
using JD.Application.View;
|
|
using JD.Application.View.Actions;
|
|
using JD.Interfaces.Player;
|
|
using JD.Collections;
|
|
using JD.Sequencers.Windowlesses;
|
|
|
|
namespace JD.VideoPlayer.Project
|
|
{
|
|
|
|
public abstract class WaveControlledVideoPad : AbstractVideoPad
|
|
{
|
|
|
|
#region Properties
|
|
|
|
public override IPlayerProvider PlayerProvider
|
|
{
|
|
set
|
|
{
|
|
var waveControl = PlayerProvider as WaveControl;
|
|
if (waveControl != null)
|
|
{
|
|
waveControl.Selection.CollectionChanged -= Selection_CollectionChanged;
|
|
}
|
|
|
|
base.PlayerProvider = value;
|
|
|
|
if (waveControl != null)
|
|
{
|
|
waveControl.Selection.CollectionChanged += Selection_CollectionChanged;
|
|
}
|
|
|
|
}
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region Private
|
|
|
|
private void Selection_CollectionChanged(object sender, CollectionChangedEventArgs<WindowlessControl> e)
|
|
{
|
|
if (e.Action != CollectionChangeAction.EndUpdated) return;
|
|
|
|
UpdateConductors();
|
|
}
|
|
|
|
#endregion
|
|
|
|
}
|
|
|
|
}
|