Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Command key can sometimes always be a modifier (mac) #48

Closed
roberttyson opened this issue Apr 1, 2015 · 15 comments
Closed

Command key can sometimes always be a modifier (mac) #48

roberttyson opened this issue Apr 1, 2015 · 15 comments
Assignees
Labels
Milestone

Comments

@roberttyson
Copy link

On Mac OS-X there are times when command key is always a modifier on every key and mouse event. It might not start on the first event, but once it starts it will stay as a modifier key on every event after that until the program ends. I have not been about to figure out what triggers it to start. It seems to happen about 10-20% of the time.

I have not seen this in the windows version.

This is in version 2.0.0.

@kwhat
Copy link
Owner

kwhat commented Apr 5, 2015

What do you mean by "always a modifier on every key"? Is the modifier flag on but the key is not depressed? Does pressing and releasing the command key fix anything? I would try setting the logger to debug and see if anything useful comes out when the issue starts.

It could be that the modifier is getting stuck because the hook restarted, but that should correct it self. The other possibility is there maybe memory corruption on the event object, but I cant figure out how its happening. The debug log level should give me a better idea of what is going on.

@kwhat kwhat added the bug label Apr 5, 2015
@kwhat kwhat added this to the 2.0.2 milestone Apr 5, 2015
@kwhat kwhat self-assigned this Apr 5, 2015
@roberttyson
Copy link
Author

Yes I mean that the modifier flag is on but the key is not depressed. I do not know if pressing and releasing the command key fixes everything. I will try the next time it happens.

I have turned on debug logs, but of course I have not had it happen since then, if/when it does I will add the logs.

Below is an example of the log files at WARNING level. The CaptureEvents is from my Application. This is essentially showing what information from the Event.

INFO: Library extracted successfully: /var/folders/2z/6rnkzjzj2q55s6935mr329pc0000gp/T/libJNativeHook-2.0.0.dylib (0x14E29952E7A4EF4E15530C500082348FADEA1517).

JNativeHook: Global keyboard and mouse hooking for Java.
Copyright (C) 2006-2015 Alexander Barker. All Rights Received.
https://github.com/kwhat/jnativehook/

JNativeHook is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published
by the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

JNativeHook is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU Lesser General Public License
along with this program. If not, see http://www.gnu.org/licenses/.

Apr 06, 2015 8:32:00 AM java.lang.ClassLoader$NativeLibrary load
INFO: hook_get_auto_repeat_rate [107]: IOHIDGetParameter: 75.

Apr 06, 2015 8:32:00 AM java.lang.ClassLoader$NativeLibrary load
INFO: hook_get_auto_repeat_delay [189]: IOHIDGetParameter: 450.

Apr 06, 2015 8:32:00 AM java.lang.ClassLoader$NativeLibrary load
INFO: hook_get_pointer_acceleration_multiplier [270]: IOHIDGetAccelerationWithKey: 1.

Apr 06, 2015 8:32:00 AM java.lang.ClassLoader$NativeLibrary load
WARNING: jni_SetProperties [146]: Invalid result returned from hook_get_pointer_acceleration_threshold()!

Apr 06, 2015 8:32:00 AM java.lang.ClassLoader$NativeLibrary load
INFO: hook_get_pointer_sensitivity [356]: IOHIDGetAccelerationWithKey: 1.

Apr 06, 2015 8:32:00 AM java.lang.ClassLoader$NativeLibrary load
INFO: hook_get_multi_click_time [399]: IOHIDGetParameter: 450.

2015-32-06 08:32:39.276 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Pressed: (⇥) modifiers: []
2015-32-06 08:32:39.409 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Released: (⇥) modifiers: []
2015-32-06 08:32:39.850 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Pressed: (⇥) modifiers: []
2015-32-06 08:32:39.962 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Released: (⇥) modifiers: []
2015-32-06 08:32:40.346 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Pressed: (⇥) modifiers: []
2015-32-06 08:32:40.530 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Released: (⇥) modifiers: []
2015-32-06 08:32:41.018 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Pressed: (⇥) modifiers: []
2015-32-06 08:32:41.154 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Released: (⇥) modifiers: []
2015-32-06 08:32:41.498 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Pressed: (⇥) modifiers: []
2015-32-06 08:32:41.634 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Released: (⇥) modifiers: []
2015-32-06 08:32:43.042 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Pressed: (⇥) modifiers: []
2015-32-06 08:32:43.226 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Released: (⇥) modifiers: []
2015-32-06 08:32:43.771 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Pressed: (⇥) modifiers: []
2015-32-06 08:32:43.890 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Released: (⇥) modifiers: []
2015-32-06 08:32:44.618 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Released: (Left Meta) modifiers: [⌘]
Apr 06, 2015 8:32:45 AM org.jnativehook.GlobalScreen$NativeHookThread enable
WARNING: hook_event_proc [855]: Unhandled Darwin event! (0X1D)

Apr 06, 2015 8:32:45 AM org.jnativehook.GlobalScreen$NativeHookThread enable
WARNING: hook_event_proc [855]: Unhandled Darwin event! (0X1D)

Apr 06, 2015 8:32:45 AM org.jnativehook.GlobalScreen$NativeHookThread enable
WARNING: hook_event_proc [855]: Unhandled Darwin event! (0X1D)

Apr 06, 2015 8:32:45 AM org.jnativehook.GlobalScreen$NativeHookThread enable
WARNING: hook_event_proc [855]: Unhandled Darwin event! (0X1D)

Apr 06, 2015 8:32:45 AM org.jnativehook.GlobalScreen$NativeHookThread enable
WARNING: hook_event_proc [855]: Unhandled Darwin event! (0X1D)

Apr 06, 2015 8:32:45 AM org.jnativehook.GlobalScreen$NativeHookThread enable
WARNING: hook_event_proc [855]: Unhandled Darwin event! (0X1D)

Apr 06, 2015 8:32:45 AM org.jnativehook.GlobalScreen$NativeHookThread enable
WARNING: hook_event_proc [855]: Unhandled Darwin event! (0X1D)

Apr 06, 2015 8:32:45 AM org.jnativehook.GlobalScreen$NativeHookThread enable
WARNING: hook_event_proc [855]: Unhandled Darwin event! (0X1D)

2015-32-06 08:32:45.565 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (275,88) modifiers: [⌘]
2015-32-06 08:32:45.581 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (275,90) modifiers: [⌘]
2015-32-06 08:32:45.598 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (275,90) modifiers: [⌘]
2015-32-06 08:32:45.615 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (275,92) modifiers: [⌘]
2015-32-06 08:32:45.638 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (275,93) modifiers: [⌘]
2015-32-06 08:32:45.654 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (275,93) modifiers: [⌘]
2015-32-06 08:32:45.790 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (276,93) modifiers: [⌘]
2015-32-06 08:32:45.806 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (279,93) modifiers: [⌘]
2015-32-06 08:32:45.824 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (281,91) modifiers: [⌘]
2015-32-06 08:32:45.846 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (281,88) modifiers: [⌘]
2015-32-06 08:32:45.859 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (280,81) modifiers: [⌘]
2015-32-06 08:32:45.875 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (274,73) modifiers: [⌘]
2015-32-06 08:32:45.892 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (263,61) modifiers: [⌘]

From this point on all of the events have the modifier.

@roberttyson
Copy link
Author

I got it to happen again but I did not have a large enough buffer to capture the start of the modifier key being pressed (I have changed what I am capturing and will attempt to get that).

Pressing the command key again, does seem to toggle off it always being selected. I am not sure if it helps but here are the logs from that happening:
2015-40-06 11:40:20.497 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (775,73) modifiers: [⌘]
Apr 06, 2015 11:40:20 AM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 1604, 461.

Apr 06, 2015 11:40:20 AM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-40-06 11:40:20.513 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (775,71) modifiers: [⌘]
Apr 06, 2015 11:40:20 AM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 1604, 460.

Apr 06, 2015 11:40:20 AM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-40-06 11:40:20.530 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (775,70) modifiers: [⌘]
Apr 06, 2015 11:40:21 AM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_modifier_changed [424]: Modifiers Changed for key 0X37. (0X100108)

2015-40-06 11:40:21.744 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Pressed: (Left Meta) modifiers: [⌘]
Apr 06, 2015 11:40:21 AM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_pressed [322]: Key 0XE5B pressed. (0X37)

Apr 06, 2015 11:40:21 AM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 4.

Apr 06, 2015 11:40:22 AM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_pressed [322]: Key 0X2E pressed. (0X8)

Apr 06, 2015 11:40:22 AM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 4.

Apr 06, 2015 11:40:22 AM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_pressed [377]: Key 0 typed. (c)

2015-40-06 11:40:22.248 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Pressed: (C) modifiers: [⌘]
Apr 06, 2015 11:40:22 AM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 3.

Apr 06, 2015 11:40:22 AM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_modifier_changed [424]: Modifiers Changed for key 0X37. (0X100)

Apr 06, 2015 11:40:22 AM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_released [413]: Key 0XE5B released. (0X37)

Apr 06, 2015 11:40:22 AM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 5.

2015-40-06 11:40:22.381 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Combination: image_10.png null (c) modifiers: [⌘]
2015-40-06 11:40:22.382 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Released: (Left Meta) modifiers: []
Apr 06, 2015 11:40:22 AM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_released [413]: Key 0X2E released. (0X8)

Apr 06, 2015 11:40:22 AM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 5.

2015-40-06 11:40:22.408 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Released: (C) modifiers: []
Apr 06, 2015 11:40:23 AM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 1604, 462.

2015-40-06 11:40:23.380 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (775,72) modifiers: []

@roberttyson
Copy link
Author

Here are some logs showing what was happening when the command key was always down (this was done by holding the command key down before starting the listeners though this is not the only way this has happened). At the end I hit the command key again and it seems to stop the problem.

Apr 07, 2015 3:16:37 PM org.jnativehook.DefaultLibraryLocator getLibraries
INFO: Library extracted successfully: /var/folders/2z/6rnkzjzj2q55s6935mr329pc0000gp/T/libJNativeHook-2.0.0.dylib (0x14E29952E7A4EF4E15530C500082348FADEA1517).

JNativeHook: Global keyboard and mouse hooking for Java.
Copyright (C) 2006-2015 Alexander Barker. All Rights Received.
https://github.com/kwhat/jnativehook/

JNativeHook is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published
by the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

JNativeHook is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU Lesser General Public License
along with this program. If not, see http://www.gnu.org/licenses/.

Apr 07, 2015 3:16:37 PM java.lang.ClassLoader$NativeLibrary load
INFO: hook_get_auto_repeat_rate [107]: IOHIDGetParameter: 75.

Apr 07, 2015 3:16:37 PM java.lang.ClassLoader$NativeLibrary load
INFO: hook_get_auto_repeat_delay [189]: IOHIDGetParameter: 450.

Apr 07, 2015 3:16:37 PM java.lang.ClassLoader$NativeLibrary load
INFO: hook_get_pointer_acceleration_multiplier [270]: IOHIDGetAccelerationWithKey: 1.

Apr 07, 2015 3:16:37 PM java.lang.ClassLoader$NativeLibrary load
WARNING: jni_SetProperties [146]: Invalid result returned from hook_get_pointer_acceleration_threshold()!

Apr 07, 2015 3:16:37 PM java.lang.ClassLoader$NativeLibrary load
INFO: hook_get_pointer_sensitivity [356]: IOHIDGetAccelerationWithKey: 1.

Apr 07, 2015 3:16:37 PM java.lang.ClassLoader$NativeLibrary load
INFO: hook_get_multi_click_time [399]: IOHIDGetParameter: 450.

Apr 07, 2015 3:16:48 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: hook_run [889]: Accessibility API is enabled.

Apr 07, 2015 3:16:48 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: hook_run [944]: CGEventTapCreate Successful.

Apr 07, 2015 3:16:48 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: hook_run [960]: CFMachPortCreateRunLoopSource successful.

Apr 07, 2015 3:16:48 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: hook_run [975]: CFRunLoopGetCurrent successful.

Apr 07, 2015 3:16:48 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: start_message_port_runloop [225]: Successful.

Apr 07, 2015 3:16:48 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 1.

Apr 07, 2015 3:16:49 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: get_event_timestamp [134]: Resynchronizing event clock. (1427896743080)

Apr 07, 2015 3:16:49 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_modifier_changed [424]: Modifiers Changed for key 0X37. (0X100)

Apr 07, 2015 3:16:49 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_released [413]: Key 0XE5B released. (0X37)

Apr 07, 2015 3:16:49 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 5.

2015-16-07 15:16:49.646 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Released: (Left Meta) modifiers: [⌘]
Apr 07, 2015 3:16:49 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_modifier_changed [424]: Modifiers Changed for key 0. (0X100)

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 982, 298.

2015-16-07 15:16:51.208 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (775,39) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 982, 299.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.225 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (775,40) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 982, 301.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.241 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (775,42) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 981, 301.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.286 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (774,42) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 980, 301.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.304 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (773,42) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 977, 301.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.323 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (770,42) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 972, 301.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.338 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (765,42) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 965, 301.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.355 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (758,42) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 954, 301.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.371 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (747,42) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 942, 301.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.389 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (735,42) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 928, 301.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.405 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (721,42) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 918, 301.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.422 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (711,42) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 905, 299.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.439 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (698,40) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 894, 298.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.456 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (687,39) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 885, 297.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.473 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (678,38) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 876, 297.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.490 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (669,38) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 871, 297.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.506 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (664,38) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 867, 297.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.523 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (660,38) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 861, 297.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.540 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (654,38) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 856, 297.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.557 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (649,38) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 851, 297.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.575 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (644,38) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 847, 297.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.592 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (640,38) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 844, 297.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.610 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (637,38) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 842, 297.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.626 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (635,38) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 840, 297.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.644 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (633,38) modifiers: [⌘]
Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 839, 297.

Apr 07, 2015 3:16:51 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:51.661 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (632,38) modifiers: [⌘]
Apr 07, 2015 3:16:52 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 839, 298.

Apr 07, 2015 3:16:52 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:52.062 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (632,39) modifiers: [⌘]
Apr 07, 2015 3:16:52 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 839, 299.

Apr 07, 2015 3:16:52 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:52.079 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (632,40) modifiers: [⌘]
Apr 07, 2015 3:16:52 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 839, 301.

Apr 07, 2015 3:16:52 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:52.097 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (632,42) modifiers: [⌘]
Apr 07, 2015 3:16:52 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 839, 302.

Apr 07, 2015 3:16:52 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:52.114 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (632,43) modifiers: [⌘]
Apr 07, 2015 3:16:52 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 839, 303.

Apr 07, 2015 3:16:52 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

2015-16-07 15:16:52.141 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (632,44) modifiers: [⌘]
Apr 07, 2015 3:16:52 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_mouse_moved [657]: Mouse moved to 839, 304.

2015-16-07 15:16:52.591 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Mouse Moved: (632,45) modifiers: [⌘]
Apr 07, 2015 3:16:52 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 9.

Apr 07, 2015 3:17:00 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_modifier_changed [424]: Modifiers Changed for key 0X37. (0X100108)

2015-17-07 15:17:00.524 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Pressed: (Left Meta) modifiers: [⌘]
Apr 07, 2015 3:17:00 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_pressed [322]: Key 0XE5B pressed. (0X37)

Apr 07, 2015 3:17:00 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 4.

Apr 07, 2015 3:17:00 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_pressed [322]: Key 0X2E pressed. (0X8)

Apr 07, 2015 3:17:00 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 4.

2015-17-07 15:17:00.899 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Pressed: (C) modifiers: [⌘]
Apr 07, 2015 3:17:00 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_pressed [377]: Key 0 typed. (c)

Apr 07, 2015 3:17:00 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 3.

Apr 07, 2015 3:17:01 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_modifier_changed [424]: Modifiers Changed for key 0X37. (0X100)

Apr 07, 2015 3:17:01 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_released [413]: Key 0XE5B released. (0X37)

Apr 07, 2015 3:17:01 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 5.

Apr 07, 2015 3:17:01 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_released [413]: Key 0X2E released. (0X8)

Apr 07, 2015 3:17:01 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 5.

2015-17-07 15:17:01.171 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Combination: image_1.png null (c) modifiers: [⌘]
2015-17-07 15:17:01.171 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Released: (Left Meta) modifiers: []
2015-17-07 15:17:01.171 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Released: (C) modifiers: []
Apr 07, 2015 3:17:04 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_modifier_changed [424]: Modifiers Changed for key 0X37. (0X100108)

2015-17-07 15:17:04.196 DEBUG [JNativeHook Dispatch Thread] CaptureEvents Key Pressed: (Left Meta) modifiers: [⌘]
Apr 07, 2015 3:17:04 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_pressed [322]: Key 0XE5B pressed. (0X37)

Apr 07, 2015 3:17:04 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 4.

Apr 07, 2015 3:17:04 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_pressed [322]: Key 0X1C pressed. (0X24)

Apr 07, 2015 3:17:04 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 4.

2015-17-07 15:17:04.820 DEBUG [JNativeHook Dispatch Thread] AccessibilityAccess Removed all listeners
Apr 07, 2015 3:17:04 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_pressed [377]: Key 0 typed. (
)

Apr 07, 2015 3:17:04 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 3.

Apr 07, 2015 3:17:04 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: process_key_released [413]: Key 0X1C released. (0X24)

Apr 07, 2015 3:17:04 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 5.

Apr 07, 2015 3:17:05 PM org.jnativehook.GlobalScreen$NativeHookThread disable
FINE: hook_stop [1066]: Status: 0.

Apr 07, 2015 3:17:05 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: dispatch_event [88]: Dispatching event type 2.

Apr 07, 2015 3:17:05 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: stop_message_port_runloop [264]: Successful.

Apr 07, 2015 3:17:05 PM org.jnativehook.GlobalScreen$NativeHookThread enable
FINE: hook_run [1044]: Something, something, something, complete.

@kwhat
Copy link
Owner

kwhat commented Apr 8, 2015

Have you tried with 2.0.1? I made a few api improvements on OS X. I haven't been able to duplicate the issue with 2.0 latest yet.

@roberttyson
Copy link
Author

I have tried it both with 2.0.1 and with the 2.0.20140406 build that you posted in another bug yesterday. In both cases I can get the bug to happen.

While I have had it happen on other occasions, I can get it to happen fairly often by holding down the command key before the listeners are added and then releasing the command key after this time.

@kwhat
Copy link
Owner

kwhat commented Apr 8, 2015

Ahh ok, that makes sense. I have already addressed that issue on Windows but I have a feeling Apple is going to make it very difficult on OS X. I'll try to get a fix in sometime this week.

@roberttyson
Copy link
Author

Great! Let me know if you need anything else from me. I can easily test a build if you want as well.

@kwhat
Copy link
Owner

kwhat commented Apr 19, 2015

Git this nightly a try and see if it works better. I added the same Windows fix to OS X and Linux.

JNativeHook-2.0.20150419.jar | uploaded via ZenHub

@roberttyson
Copy link
Author

I have done some limited testing on it and it appears to be fixed. Thanks! I will be testing it more today. I will let you know if there are any problems.

@roberttyson
Copy link
Author

The nightly, JNativeHook-2.0.20150418.jar, seems to work fine on OS X but I am having some problems with it on windows. (Not sure if was intended to work on windows ...) Every time I have run it, it always as something as a modifier, either the Mouse-2 button or shift key, similar to the way the command key was always down in OS X.

@kwhat
Copy link
Owner

kwhat commented Apr 20, 2015

Thanks for testing! It was suppose to work with Windows, but clearly I screwed something up ;) Ill put a new build together soon.

@kwhat
Copy link
Owner

kwhat commented Apr 21, 2015

Give this one a try.

JNativeHook-2.0.20150420.jar | uploaded via ZenHub

@roberttyson
Copy link
Author

2.0.20150420 works for me on both OS-X and Windows. Thanks!

@kwhat
Copy link
Owner

kwhat commented Apr 22, 2015

NP, thanks again for testing.

@kwhat kwhat closed this as completed Apr 22, 2015
kwhat pushed a commit that referenced this issue May 22, 2017
kwhat pushed a commit that referenced this issue May 22, 2017
kwhat pushed a commit that referenced this issue May 22, 2017
kwhat pushed a commit that referenced this issue May 22, 2017
kwhat pushed a commit that referenced this issue May 22, 2017
kwhat pushed a commit that referenced this issue May 22, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants