private IOperation BuildKeyboardInterceptorOperation()
        {
            var keyboardInterceptor = new KeyboardInterceptor(ModuleLogger(nameof(KeyboardInterceptor)), nativeMethods, context.Settings.Keyboard);
            var operation           = new KeyboardInterceptorOperation(context, keyboardInterceptor, logger);

            return(operation);
        }
Exemplo n.º 2
0
        private IOperation BuildKeyboardInterceptorOperation()
        {
            var keyboardInterceptor = new KeyboardInterceptor(configuration.Settings.Keyboard, new ModuleLogger(logger, nameof(KeyboardInterceptor)));
            var operation           = new KeyboardInterceptorOperation(keyboardInterceptor, logger, nativeMethods);

            return(operation);
        }
Exemplo n.º 3
0
 static void Main()
 {
     KeyboardInterceptor.Start();
     MouseInterceptor.Start();
     Application.EnableVisualStyles();
     Application.SetCompatibleTextRenderingDefault(false);
     Application.Run(new Form1());
     KeyboardInterceptor.Stop();
     MouseInterceptor.Stop();
 }
Exemplo n.º 4
0
        protected override void Initialize()
        {
            keyboardInterceptor              = new KeyboardInterceptor();
            keyboardInterceptor.OnKeyAction += OnKeyboardIntercept;
#if RELEASE
            graphics.PreferredBackBufferWidth  = GraphicsAdapter.DefaultAdapter.CurrentDisplayMode.Width;
            graphics.PreferredBackBufferHeight = GraphicsAdapter.DefaultAdapter.CurrentDisplayMode.Height;
            graphics.ToggleFullScreen();
#endif

            base.Initialize();
        }
Exemplo n.º 5
0
        public void Start()
        {
            key = new KeyboardInterceptor();

            key.KeyDown  += key_KeyDown;
            key.KeyUp    += key_KeyUp;
            key.KeyPress += key_KeyPress;

            key.StartCapturing();

            Console.WriteLine("[Hooky] Started Hooky.");
            Application.Run();
        }
Exemplo n.º 6
0
        public void Start()
        {
            _key = new KeyboardInterceptor();

            _key.KeyDown  += Key_KeyDown;
            _key.KeyUp    += Key_KeyUp;
            _key.KeyPress += Key_KeyPress;

            _key.StartCapturing();

            _logger.LogInformation("Started.");
            Application.Run();
        }
        public WindowsEnhancementApplicationContext()
        {
            // Hotkeys initialisieren
            this.keyboadHook          = new KeyboardInterceptor();
            this.keyboadHook.KeyDown += keyboadHookOnKeyDown;

            this.keyboadHook.StartCapturing();

            // Services initialisieren
            this.fileAndImageSaveService = new FileAndImageSaveService();
            this.fileCreateService       = new FileCreateService();
            this.fileAndImageViewService = new FileAndImageViewService();
            this.explorerBrowserService  = new ExplorerBrowserService();

            // TrayIcon etc. initalisieren
            this.initializeComponents();

            // Events hinzufügen
            Application.ApplicationExit += this.applicationOnApplicationExit;
        }
Exemplo n.º 8
0
 public static void SetupKeyboardHook()
 {
     _interceptor          = new KeyboardInterceptor();
     _interceptor.KeyDown += VirtualKeyboardOnKeyDown;
     _interceptor.StartCapturing();
 }
Exemplo n.º 9
0
 public KeyboardHookClass(ILoger Loger)
 {
     this.Loger        = Loger;
     Capturer          = new KeyboardInterceptor();
     Capturer.KeyDown += Capturer_KeyDown;
 }
Exemplo n.º 10
0
        static void SetupKeyboardInterceptor()
        {
            KeyboardInterceptor keyboardInterceptor = new KeyboardInterceptor();

            keyboardInterceptor.Start();
        }