Ejemplo n.º 1
0
 private void MainWindow_KeyDown(object sender, KeyEventArgs e)
 {
     // Go to next/previous frame
     if (e.Key == Key.Right)
     {
         FrameDisplay.Frame = Pattern.NextFrame();
     }
     if (e.Key == Key.Left)
     {
         FrameDisplay.Frame = Pattern.PreviousFrame();
     }
     if (e.Key == Key.C && Keyboard.Modifiers == ModifierKeys.Control)
     {
         _clipBoard = DeepCopy.CreateCopy <Pixel>(FrameDisplay.Frame.Pixels);
     }
     if (e.Key == Key.V && Keyboard.Modifiers == ModifierKeys.Control)
     {
         if (_clipBoard != null)
         {
             FrameDisplay.Frame.Pixels = DeepCopy.CreateCopy <Pixel>(_clipBoard);
             FrameDisplay.Update();
         }
     }
 }