LibWebView: Keep javascript URL navigations in the same process

JavaScript URLs run in the same document context the navigation was
started in, so they're not eligible to be moved to a new WebContent
process.

Fixes the "Login as demo user" link on https://demo.immich.app/
This commit is contained in:
Luke Wilde 2025-03-16 14:13:58 +00:00 committed by Tim Flynn
parent c8787e6a9f
commit 61c1e4a855
Notes: github-actions[bot] 2025-03-16 15:00:33 +00:00
3 changed files with 16 additions and 0 deletions

View file

@ -0,0 +1,11 @@
<!DOCTYPE html>
<script src="../include.js"></script>
<div id="test">Hello world, this was printed by a JavaScript navigation!</div>
<script>
asyncTest((done) => {
location.href = "javascript:void println(document.getElementById('test').innerText)";
setTimeout(() => {
done();
}, 0);
});
</script>