Beispiel #1
0
        private void ToggleMute_Click(object sender, RoutedEventArgs e)
        {
            VMVolume model = DataContext as VMVolume;

            if (model != null)
            {
                model.ToggleMute();
            }
        }
Beispiel #2
0
        private void VolumeUp_Click(object sender, RoutedEventArgs e)
        {
            VMVolume model = DataContext as VMVolume;

            if (model != null)
            {
                model.VolumeUp();
            }
        }
Beispiel #3
0
 private void Slider_PreviewMouseUp(object sender, MouseButtonEventArgs e)
 {
     if (PreviousValue != volSlider.Value)
     {
         VMVolume model = DataContext as VMVolume;
         if (model != null)
         {
             model.ChangeVolume(volSlider.Value);
         }
     }
 }
Beispiel #4
0
 public VolumeControl()
 {
     InitializeComponent();
     vmVolume    = new VMVolume();
     DataContext = vmVolume;
 }