You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Can you allow inserting keystrokes (so as to release a GetKey() call)?
The scenario is like this: The main routine issues a GetKey() call and is waiting for input. A goroutine meanwhile is counting on a timer and wants to end the wait when the timout occurs. At this point, how do I 'cancel' the GetKey() call? The solution I found (and it works fine) is to have a PushKey(ev KeyEvent) method added to keyboard_common.go that only does inputComm <- ev. This will push a default keystroke in and completes the GetKey() which can then return.
Did you leave out this functionality because of the security implications? If so, what is the alternative solution to cancel a GetKey() blocking call?
The text was updated successfully, but these errors were encountered:
Can you allow inserting keystrokes (so as to release a GetKey() call)?
The scenario is like this: The main routine issues a GetKey() call and is waiting for input. A goroutine meanwhile is counting on a timer and wants to end the wait when the timout occurs. At this point, how do I 'cancel' the GetKey() call? The solution I found (and it works fine) is to have a PushKey(ev KeyEvent) method added to keyboard_common.go that only does inputComm <- ev. This will push a default keystroke in and completes the GetKey() which can then return.
Did you leave out this functionality because of the security implications? If so, what is the alternative solution to cancel a GetKey() blocking call?
The text was updated successfully, but these errors were encountered: