diff options
Diffstat (limited to 'Source/WebKit2/WebProcess/Notifications/NotificationPermissionRequestManager.cpp')
-rw-r--r-- | Source/WebKit2/WebProcess/Notifications/NotificationPermissionRequestManager.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/Source/WebKit2/WebProcess/Notifications/NotificationPermissionRequestManager.cpp b/Source/WebKit2/WebProcess/Notifications/NotificationPermissionRequestManager.cpp index 7d662f12d..73e71fbc9 100644 --- a/Source/WebKit2/WebProcess/Notifications/NotificationPermissionRequestManager.cpp +++ b/Source/WebKit2/WebProcess/Notifications/NotificationPermissionRequestManager.cpp @@ -62,8 +62,10 @@ NotificationPermissionRequestManager::NotificationPermissionRequestManager(WebPa void NotificationPermissionRequestManager::startRequest(SecurityOrigin* origin, PassRefPtr<VoidCallback> callback) { #if ENABLE(NOTIFICATIONS) - if (permissionLevel(origin) != NotificationPresenter::PermissionNotAllowed) + if (permissionLevel(origin) != NotificationClient::PermissionNotAllowed) { + callback->handleEvent(); return; + } uint64_t requestID = generateRequestID(); m_originToIDMap.set(origin, requestID); @@ -90,16 +92,16 @@ void NotificationPermissionRequestManager::cancelRequest(SecurityOrigin* origin) #endif } -NotificationPresenter::Permission NotificationPermissionRequestManager::permissionLevel(SecurityOrigin* securityOrigin) +NotificationClient::Permission NotificationPermissionRequestManager::permissionLevel(SecurityOrigin* securityOrigin) { #if ENABLE(NOTIFICATIONS) if (!m_page->corePage()->settings()->notificationsEnabled()) - return NotificationPresenter::PermissionDenied; + return NotificationClient::PermissionDenied; return WebProcess::shared().notificationManager().policyForOrigin(securityOrigin); #else UNUSED_PARAM(securityOrigin); - return NotificationPresenter::PermissionDenied; + return NotificationClient::PermissionDenied; #endif } |