Detect Keypress on Launch ?
Posted: Tue Oct 16, 2012 12:26 pm
Hi,
Just to be sure I did not overlooked something:
Is there a native PureBasic way of detecting key pressed on executable launch ?
Say I want to know if one of the SHIFT keys is pressed when the user launch the application.
I can't use ExamineKeyboard and the like as this require opening a screen. I want to detect keys even with Console applications (yet I'm not sure ExamineKeyboard would detect keys on application launch).
I'm well aware of the Windows API GetAsyncKeyState() which answers my question.
So if there is no native PureBasic way of doing this, what would be the equivalent of GetAsyncKeyState() on Linux and Mac OSX ?
Thanks.
Just to be sure I did not overlooked something:
Is there a native PureBasic way of detecting key pressed on executable launch ?
Say I want to know if one of the SHIFT keys is pressed when the user launch the application.
I can't use ExamineKeyboard and the like as this require opening a screen. I want to detect keys even with Console applications (yet I'm not sure ExamineKeyboard would detect keys on application launch).
I'm well aware of the Windows API GetAsyncKeyState() which answers my question.
So if there is no native PureBasic way of doing this, what would be the equivalent of GetAsyncKeyState() on Linux and Mac OSX ?
Thanks.