|
A function that can be used in Scripting.
demoWaitForInput
( )
This function blocks until the user clicks in the Demo window or types a key into the Demo window.
Once the function finally returns, it returns the value 1 (true). This makes it possible to use this function in a while
loop:
while demoWaitForInput ()
if demoClicked ())
# handle the mouse click
elsif demoKeyPressed ())
# handle the key press
endif
endwhile
demoShow
© Paul Boersma 2023