mirror of
https://github.com/tauri-apps/tauri.git
synced 2026-04-03 10:11:15 +02:00
fix(core): iOS compilation without the wry feature (#10176)
Ref https://github.com/tauri-apps/plugins-workspace/pull/1402
This commit is contained in:
committed by
GitHub
parent
7bc6a2a1d6
commit
55733aba9c
5
.changes/with-webview-wry-feature.md
Normal file
5
.changes/with-webview-wry-feature.md
Normal file
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"tauri": patch:bug
|
||||
---
|
||||
|
||||
Move `PluginApi::register_ios_plugin` behind the `wry` Cargo feature as `Webview::with_webview` is only available when that feature is enabled.
|
||||
@@ -631,7 +631,7 @@ impl<R: Runtime> WebviewManager<R> {
|
||||
.webview_created(webview_);
|
||||
});
|
||||
|
||||
#[cfg(target_os = "ios")]
|
||||
#[cfg(all(target_os = "ios", feature = "wry"))]
|
||||
{
|
||||
webview
|
||||
.with_webview(|w| {
|
||||
|
||||
@@ -152,7 +152,7 @@ impl<T> fmt::Display for ErrorResponse<T> {
|
||||
|
||||
impl<R: Runtime, C: DeserializeOwned> PluginApi<R, C> {
|
||||
/// Registers an iOS plugin.
|
||||
#[cfg(target_os = "ios")]
|
||||
#[cfg(all(target_os = "ios", feature = "wry"))]
|
||||
pub fn register_ios_plugin(
|
||||
&self,
|
||||
init_fn: unsafe fn() -> *const std::ffi::c_void,
|
||||
|
||||
Reference in New Issue
Block a user