On 26/06/2015 08:58, Jan Lahoda wrote:

:


The native method readKeyEvent seems to do a FindClass per key event.
Maybe this is from the upstream project but I would think it would be
more efficient to cache this in a global ref. It would also be more

I will work on this.
Related to this is that you probably want the wide ReadConsoleInput rather than ReadConsoleInputA.


efficient if the INPUT_RECORD were just returned and avoid the upstream
to create the object but that might be too much to change when you are

I am sorry, but I don't follow - I don't have much experience with native programing for JDK. Are there some more details on what I should do?
If the subset of the KEY_EVENT_RECORD that you need will fit in a jlong then you could return that to avoid the upcall. I don't think this is important for the initial push, I think the main thing to fix here is the FindClass usage.

-Alan

Reply via email to