You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@weex.apache.org by GitBox <gi...@apache.org> on 2018/12/24 12:28:54 UTC
[GitHub] zcl0001 opened a new issue #1959: weex-androw(sdk:0.19.0.7):webview message prompt 实现是否错误
zcl0001 opened a new issue #1959: weex-androw(sdk:0.19.0.7):webview message prompt 实现是否错误
URL: https://github.com/apache/incubator-weex/issues/1959
com.taobao.weex.ui.view.WXWebView 247行到254行,DOWNGRADE_JS_INTERFACE 逻辑貌似写反了
if (mOnMessageListener != null) {
evaluateJS("javascript:(window.postMessage = function(message, targetOrigin) {"
+ "if (message == null || !targetOrigin) return;"
+ (DOWNGRADE_JS_INTERFACE
? "prompt('" + BRIDGE_NAME + "://postMessage?message=' + JSON.stringify(message) + '&targetOrigin=' + targetOrigin)"
: BRIDGE_NAME + ".postMessage(JSON.stringify(message), targetOrigin);")
+ "})");
}
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services