diff options
author | Oliver Wolff <[email protected]> | 2018-01-10 10:43:12 +0100 |
---|---|---|
committer | Oliver Wolff <[email protected]> | 2018-01-10 13:38:51 +0000 |
commit | 67950a969c37660d35e9da792fbd95a97772e881 (patch) | |
tree | 51996fc308d23978daa7eca91e4351ba1efe2052 | |
parent | 4fab9eb042fc3c3728d926f6b10620d1895cb9dd (diff) |
winrt: Remove callback registrations on webview destruction
Change-Id: Ie730be9fa46e5ab2a236c5e7c4a2533789e06a5e
Reviewed-by: Maurice Kalinowski <[email protected]>
-rw-r--r-- | src/webview/qwebview_winrt.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/webview/qwebview_winrt.cpp b/src/webview/qwebview_winrt.cpp index d6ec493..fc999d2 100644 --- a/src/webview/qwebview_winrt.cpp +++ b/src/webview/qwebview_winrt.cpp @@ -348,6 +348,10 @@ QWinRTWebViewPrivate::~QWinRTWebViewPrivate() { QEventDispatcherWinRT::runOnXamlThread([this]() { HRESULT hr; + hr = d->ext->remove_NavigationStarting(d->navigationStartingToken); + Q_ASSERT_SUCCEEDED(hr); + hr = d->ext->remove_NavigationCompleted(d->navigationCompletedToken); + Q_ASSERT_SUCCEEDED(hr); ComPtr<IVector<UIElement *>> children; hr = d->host->get_Children(&children); Q_ASSERT_SUCCEEDED(hr); |