Exemplo n.º 1
0
        void keyboardHook_KeyUp(object sender, KeyEventArgs e)
        {
            Console.WriteLine("up: " + e.GetType());
            //KeyEventArgs keyArgs = (KeyEventArgs)macroEvent.EventArgs;
            //KeyboardSimulator.KeyDown(keyArgs.KeyCode);
            //globalEvent = new MacroEvent(MacroEventType.MouseDown, e, Environment.TickCount - lastTimeRecorded);

            events.Add(
                new MacroEvent(
                    MacroEventType.KeyUp,
                    e,
                    Environment.TickCount - lastTimeRecorded
                ));

            lastTimeRecorded = Environment.TickCount;
        }