May 7, 201610 yr Tell me, how am i supposed to make it so that if the client is minimzed it'll still listen to keys ? Right now i have to have client in focus so that it'll listen to keys, welp. Programs running under pretty much any operating system function based on "focus" so that you only have 1 window focused at once, therefore all keyboard/mouse input will be sent to that specific window. There are some programs that can be used to record input while they are not focused called "keyloggers". They are generally written in low level programming languages though as you need more access to the architecture than what Java might provide. I have implementations for keyloggers in both C and assembly. The C implementation is rather easy as C provides functions for this. The assembly one is rather difficult and it's based entirely on interrupt redirection. I am not aware of a possible implementation of keyloggers in Java (especially because the code runs in the JVM which breaks the connection to the actual architecture), but you could link native code through the JNI. If you plan to do this on the SDN there is no way it will be allowed but you might get away with it in local scripts.
May 7, 201610 yr *EDIT* - removed, was replying to Token, misread. Edited May 7, 201610 yr by DragonAlpha
May 7, 201610 yr Via JNI: http://biletnikov-dev.blogspot.be/2009/09/global-hotkeys-for-java-applications_25.html Will only work on Windows (unless you're up to writing implementations for other OSes yourself). I would not recommend un-focused command anyways. Edited May 7, 201610 yr by Botre
May 8, 201610 yr OP probably wants something that will fly with the SDN :E.. I don't think possible jabba solution will
Create an account or sign in to comment