public virtual void CallKey(KeyMake.KeyEvent e) { LProcess process = LSystem.GetProcess(); if (process != null) { if (e.down) { finalKey.timer = e.time; finalKey.keyChar = e.keyChar; finalKey.keyCode = e.keyCode; finalKey.type = SysKey.DOWN; SysKey.only_key.Press(); SysKey.AddKey(finalKey.keyCode); process.KeyDown(finalKey); } else { finalKey.timer = e.time; //finalKey.keyChar = e.keyChar; //finalKey.keyCode = e.keyCode; finalKey.type = SysKey.UP; SysKey.RemoveKey(finalKey.keyCode); process.KeyUp(finalKey); } } }
protected internal virtual void EmitKeyPress(double time, int keyCode, char keyChar, bool down, int flags) { KeyMake.KeyEvent e = new KeyMake.KeyEvent(0, time, keyChar, keyCode, down); e.SetFlag(flags); keyboardEvents.Emit(e); }