static void CommandOpenOSK(CommandArg[] args) { //这边操作必须要先把鼠标移开才能操作,不然会直接输入 KeyBoardEvent.DoMouseClick(Screen.width / 2, Screen.height / 2); //SuperInvoke.SkipFrames 等待帧数 SuperInvoke.SkipFrames(1, () => { KeyBoardEvent.ClickFNum(118); //鼠标恢复原位 KeyBoardEvent.DoMouseClick(KeyBoardEvent.lastPoint.X, KeyBoardEvent.lastPoint.Y); }); }
static void CommandSpeed(CommandArg[] args) { KeyBoardEvent.DoMouseClick(Screen.width / 2, Screen.height / 2); SuperInvoke.SkipFrames(1, () => { KeyBoardEvent.ClickFNum(123); KeyBoardEvent.DoMouseClick(KeyBoardEvent.lastPoint.X, KeyBoardEvent.lastPoint.Y); }); }