Added queueing of javascript messages until webview is loaded