diff options
author | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2019-06-24 14:41:46 +0200 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2020-04-15 17:17:26 +0200 |
commit | eb96f424587c5da4eabe1306e4c277879a245c02 (patch) | |
tree | 22b4b13e620dca5b06bbed457be8b01ac5bb21e7 /src/core/web_contents_adapter.cpp | |
parent | 3125f1ac3951c63c20110c7e3946ca281cebbdf3 (diff) |
Join some features request and response functions
Will make it easier to expands with more features in the future
Change-Id: Ic7c1aca23a543c95a4873471c918f74606be2053
Reviewed-by: Kirill Burtsev <kirill.burtsev@qt.io>
Diffstat (limited to 'src/core/web_contents_adapter.cpp')
-rw-r--r-- | src/core/web_contents_adapter.cpp | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/src/core/web_contents_adapter.cpp b/src/core/web_contents_adapter.cpp index 61f8e5da0..a97db169b 100644 --- a/src/core/web_contents_adapter.cpp +++ b/src/core/web_contents_adapter.cpp @@ -1356,16 +1356,10 @@ void WebContentsAdapter::grantMediaAccessPermission(const QUrl &securityOrigin, MediaCaptureDevicesDispatcher::GetInstance()->handleMediaAccessPermissionResponse(m_webContents.get(), securityOrigin, flags); } -void WebContentsAdapter::runGeolocationRequestCallback(const QUrl &securityOrigin, bool allowed) +void WebContentsAdapter::runFeatureRequestCallback(const QUrl &securityOrigin, ProfileAdapter::PermissionType feature, bool allowed) { CHECK_INITIALIZED(); - m_profileAdapter->permissionRequestReply(securityOrigin, ProfileAdapter::GeolocationPermission, allowed); -} - -void WebContentsAdapter::runUserNotificationRequestCallback(const QUrl &securityOrigin, bool allowed) -{ - CHECK_INITIALIZED(); - m_profileAdapter->permissionRequestReply(securityOrigin, ProfileAdapter::NotificationPermission, allowed); + m_profileAdapter->permissionRequestReply(securityOrigin, feature, allowed); } void WebContentsAdapter::grantMouseLockPermission(bool granted) |