-
-
Notifications
You must be signed in to change notification settings - Fork 290
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(linux): don't share UserContentManager between webviews (v0.24) (#…
…1325) Fixes #1308 Init scripts are registered to the `UserContentManager`, so if it is shared between `WebView`s, the init scripts conflict. Use a unique `UserContentManager` for each `WebView` instead of sharing it across the `WebContext`. The IPC message handler is also registered to `UserContentManager`. Also changed from `register_uri_scheme` to `try_register_uri_scheme`, which doesn't attempt to register a URI scheme if we already know that one with the same name was registered to the `WebContext` before. Without this change, I get this error from WebKitGTK: ``` ** (tauri-app:[...]): CRITICAL **: 14:03:50.040: Cannot register URI scheme tauri more than once ``` It doesn't seem to affect functionality, but better to issue a more appropriate warning on our side. (On dev, this is propagated as an error)
- Loading branch information
Showing
3 changed files
with
18 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"wry": patch | ||
--- | ||
|
||
Fix Linux IPC handler and initialization scripts when sharing a WebContext between multiple WebViews. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters