private void dispatchMessage(WVJBMessage message) {
        String messageJSON = message2JSONObject(message).toString();
        evaluateJavascript(String.format("WebViewJavascriptBridge._handleMessageFromJava(%s)", messageJSON));
    }
set a listener for javascript closing the current activity.
app/src/main/java/com/example/jingbin/webviewstudy/view/WVJBWebView.java