|
|
|
ToggleButtonOnClick aToggleButton instructionlist
Command that sets the onClick event handler of the ToggleButton aToggleButton to the commands in the instructionlist.
Examples:
tb=ToggleButton [][Hide Turtle][ ifelse ToggleButtonValue tb [hideTurtle][showTurtle] updateGraph] ToggleButtonOnClick tb [ ifelse ToggleButtonValue tb [pr [Yes, Sir!]][pr [No, Sir!]] updateGraph] ToggleButtonOnClick tb [] ;like disabling the ToggleButton |
|
|
|