Skip to content

Commit

Permalink
Merge branch 'vNext' of https://github.com/stuerp/foo_uie_webview int…
Browse files Browse the repository at this point in the history
…o vNext
  • Loading branch information
stuerp committed Jan 27, 2025
2 parents 65641c5 + 5e36614 commit 8f3868e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Templates/Template.html
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,11 @@
}

if (!e.additionalData)
{
chrome.webview.hostObjects.sync.foo_uie_webview.print("foo_uie_webview JavaScript received shared buffer without additional data.");

return;
}

SharedBuffer = e.getBuffer(); // as an ArrayBuffer
Samples = new Float64Array(SharedBuffer);
Expand Down
2 changes: 2 additions & 0 deletions WebView.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,8 @@ HRESULT UIElement::CreateWebView()
(
[this](ICoreWebView2 * webView, ICoreWebView2NavigationStartingEventArgs * eventArgs) -> HRESULT
{
_SharedBuffer.Release();

VARIANT RemoteObject = {};

_HostObject.query_to<IDispatch>(&RemoteObject.pdispVal);
Expand Down

0 comments on commit 8f3868e

Please sign in to comment.