Пример #1
0
        private void AddSoundEffectControl(SoundEffect soundEffect)
        {
            SoundEffectControl soundEffectControl = new SoundEffectControl(soundEffect);

            SoundEffectsStackPanel.Children.Add(soundEffectControl);
            soundEffectControl.Removed += new EventHandler(soundEffectControl_Removed);
        }
Пример #2
0
 void soundEffectControl_Removed(object sender, EventArgs e)
 {
     if (Scene.SoundEffects.Count > 1)
     {
         SoundEffectControl soundEffectControl = sender as SoundEffectControl;
         Scene.SoundEffects.Remove(soundEffectControl.SoundEffect);
         SoundEffectsStackPanel.Children.Remove(soundEffectControl);
     }
 }
Пример #3
0
 private void AddSoundEffectControl(SoundEffect soundEffect)
 {
     SoundEffectControl soundEffectControl = new SoundEffectControl(soundEffect);
     SoundEffectsStackPanel.Children.Add(soundEffectControl);
     soundEffectControl.Removed += new EventHandler(soundEffectControl_Removed);
 }