move to add_handler from one shots as the handlers should conditionally remove themselves.
remove unused method
Add GUI syncing mechanism. Ruby code can now wait for JS code to complete via sync_msg_command