diff --git a/.changes/setWebview-jni-crash.md b/.changes/setWebview-jni-crash.md new file mode 100644 index 000000000..ca444fea1 --- /dev/null +++ b/.changes/setWebview-jni-crash.md @@ -0,0 +1,5 @@ +--- +"wry": patch +--- + +On Android, make `WryActivity.setWebview` method public to prevent JNI crashes. \ No newline at end of file diff --git a/src/android/kotlin/WryActivity.kt b/src/android/kotlin/WryActivity.kt index 1ed332f9f..9ef0c38f1 100644 --- a/src/android/kotlin/WryActivity.kt +++ b/src/android/kotlin/WryActivity.kt @@ -17,7 +17,7 @@ abstract class WryActivity : AppCompatActivity() { open fun onWebViewCreate(webView: WebView) { } - private fun setWebView(webView: RustWebView) { + fun setWebView(webView: RustWebView) { mWebView = webView onWebViewCreate(webView) }