private void Window_Loaded(Object sender, RoutedEventArgs e)
        {
            this.Background  = new SolidColorBrush(Color.FromArgb(10, 0, 0, 0));
            this.WindowState = WindowState.Maximized;

            this._Macros   = XmlSerializer.Load <MacroSet>(@".\Macro.xml");
            this._KeyCodes = new HashSet <Int32>(this._Macros.Macros.Select(x => x.KeyCode));
        }
        public MainWindow()
        {
            InitializeComponent();

            _Keyhook = new LLKeyHook();
            _Keyhook.SetKeyHook();
            _Keyhook.SetMouseHook();
            _Keyhook.KeyDown       += new KeyEvent(KeyDownEvetAsync);
            _Keyhook.KeyUp         += new KeyEvent(KeyUpEvet);
            _Keyhook.MouseMove     += new MouseEvent(Mousehook_MouseMove);
            _Keyhook.MouseLeftDown += new MouseEvent(Mousehook_MouseLeftDown);

            this._MacroRecord = new MacroSet {
                Macros = new List <Macro> {
                    new Macro()
                }
            };
            this._MacroRecord.Macros[0].MacroCommands = new List <Command>();
        }