[Webkit-unassigned] [Bug 163366] [GTK] No way for applications to set notification permissions without waiting for permission request

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Oct 26 14:46:55 PDT 2016


https://bugs.webkit.org/show_bug.cgi?id=163366

--- Comment #4 from Carlos Alberto Lopez Perez <clopez at igalia.com> ---
(In reply to comment #3)
> What's going wrong is that checking Notification.permission via JavaScript
> does not trigger a WebKitNotificationPermissionRequest (nor should it). The
> sites where notification permissions work properly simply don't check this
> property. If http://www.bennish.net/web-notifications.html were to attempt
> to tell you if notifications are authorized without creating a permission
> request (via Notification.requestPermission()), then it would say that
> notifications are not authorized (even though the permission request would
> be automatically granted by the application. WebKit already has a means to
> prepopulate notification permissions (see comment #0) that we need to expose
> in the WebKitGTK+ API.

I see. Thanks for the explanation.

I was confused, I was not checking properly that Notification.permission started with a value of "default" before the call to requestPermission()

Checked with the inspector:

> Notification.permission
< "default"
> Notification.requestPermission()
< undefined
> Notification.permission
< "granted"


Notification.permission

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20161026/cf840d4e/attachment.html>


More information about the webkit-unassigned mailing list