WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
79494
requestPermission callback not invoked if the WebProcess doesn't have to ask the UI Process about the permission level
https://bugs.webkit.org/show_bug.cgi?id=79494
Summary
requestPermission callback not invoked if the WebProcess doesn't have to ask ...
Jessie Berlin
Reported
2012-02-24 08:22:02 PST
If a site already has had permission granted to them to post notifications, and the Web Process already knows about this permission, if the site again calls requestPermission, the callback is never invoked. This is because of the following code in NotificationPermissionRequestManager.cpp: void NotificationPermissionRequestManager::startRequest(SecurityOrigin* origin, PassRefPtr<VoidCallback> callback) { #if ENABLE(NOTIFICATIONS) if (permissionLevel(origin) != NotificationPresenter::PermissionNotAllowed) return; uint64_t requestID = generateRequestID(); m_originToIDMap.set(origin, requestID); m_idToOriginMap.set(requestID, origin); m_idToCallbackMap.set(requestID, callback); m_page->send(Messages::WebPageProxy::RequestNotificationPermission(requestID, origin->toString())); #else UNUSED_PARAM(origin); UNUSED_PARAM(callback); #endif } That first if statement should invoke the callback. <
rdar://problem/10923498
>
Attachments
Patch
(1.77 KB, patch)
2012-02-24 08:27 PST
,
Jessie Berlin
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Jessie Berlin
Comment 1
2012-02-24 08:27:43 PST
Created
attachment 128739
[details]
Patch
Jessie Berlin
Comment 2
2012-02-24 10:52:24 PST
Comment on
attachment 128739
[details]
Patch Fixed in
http://trac.webkit.org/changeset/108822
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug