Exemple #1
0
        void keyboardHook_KeyPressed(object sender, KeyPressedEventArgs e)
        {
            Bitmap bmp;

            if (e.Modifier == Screenshotify.ModifierKeys.Alt)
                bmp = Screenshotify.Capture.ActiveWindow();
            else
                bmp = Screenshotify.Capture.Desktop();

            SaveScreenShot(bmp);
        }
        private void OnWindowKeyPressed(object sender, KeyPressedEventArgs args)
        {
            var handler = KeyPressed;

            if (handler != null)
                handler(this, args);
        }
 private void OnKeyPressed(KeyPressedEventArgs args)
 {
     var handler = KeyPressed;
     if (handler != null)
         handler(this, args);
 }