View Single Post
  #6  
Old 04-13-2017, 12:43 PM
Lenticularis Lenticularis is offline
Member
 
Join Date: Jul 2016
Posts: 12
That's exactly what I was looking for, thanks!

But how would you change the ManualCursorButtonTask function?
Code:
def ManualCursorButtonTask():
	"""Use spacebar to manually simulate mouse press/release on canvas"""

	while True:

		yield viztask.waitKeyDown(' ', priority=viz.PRIORITY_GUI_HANDLER-1)

		canvas.sendMouseButtonEvent(viz.MOUSEBUTTON_LEFT, viz.DOWN)

		yield viztask.waitKeyUp(' ', priority=viz.PRIORITY_GUI_HANDLER-1)

		canvas.sendMouseButtonEvent(viz.MOUSEBUTTON_LEFT, viz.UP)
Reply With Quote