JavaScriptObject evt = JavaScriptObject.createObject();
putEventValue(evt, "playerState", event.getPlayerState().name());
runCallback(eventHandlers.get(EventName.onPlayerState), evt);
}
});
player.addPlayStateHandler(new PlayStateHandler() {
@Override
public void onPlayStateChanged(PlayStateEvent event) {
JavaScriptObject evt = JavaScriptObject.createObject();
putEventValue(evt, "playState", event.getPlayState().name());