GNOME Bugzilla – Bug 653646
Add HTML Notification support
Last modified: 2014-12-10 17:45:07 UTC
Provide a WebKitWebNotificationPresenter implementation using libnotify to present notifications to the user.
Created attachment 190932 [details] [review] Add HTML Notification support Implement a WebKitNotificationPresenter using libnotify to present notifications to the user.
TODO: - share and persist authorizations/denials of origins - add a global setting to ignore notifications requests
Created attachment 191029 [details] [review] Add HTML Notification support Implement a WebKitNotificationPresenter using libnotify to present notifications to the user.
Created attachment 191031 [details] [review] Add HTML Notification support Listen to WebKitWebView notifications related signals. Create an info-bar for permission requests, and delegates actual notification displaying to the notifications daemon via libnotify. The support can be enabled using the '--enable-notifications' configure flag. This updated patch follows the signals approach as implemented in https://bugs.webkit.org/show_bug.cgi?id=61140 What is missing: - global setting to enable/disable notifications support - persistence of user response (positive or negative) - raising the origin ephyembed of a clicked notification - ?
This code still build and work with current webkit patches as seen in http://people.igalia.com/amazari/ephy-html-notifications.webm I am currently wondering how to present the settings for this feature to the user. A global switch, with 3 alternatives should controls the overhaul behaviour of the notification system: - display all notification without user input == automatically accept all notifications permission requests - never display notification == forbid any notification permission request - ask the user whenever a unknown security origin (domain) request permission to display notifications. In the later case, the permissions should be stored and made available to the user to modify/revoke accepted notifications permissions. The global switch would naturally fit in Preferences>Confidentiality imho, but this tab is already quite crowded, so we need to figure out a way to pack it/relayout it. The authorization exceptions list might fit as a new tab in 'Personal Data' dialog, I guess. For reference I am attaching chrome (17) notification preferences pages Before heading there, opinions are welcome, even more with the redesign coming. Happy Coding.
Created attachment 201448 [details] Chrome global notifications settings
Created attachment 201449 [details] Chrome notification auth exception page
Comment on attachment 191031 [details] [review] Add HTML Notification support Unfortunately the whole notification stuff in WebKit has changed a lot lately, so we'll need to re-take this at some point and adapt it.
*** Bug 698961 has been marked as a duplicate of this bug. ***
*** Bug 642347 has been marked as a duplicate of this bug. ***
I think that the Notification API for desktop notifications (http://www.w3.org/TR/notifications/) is very important - if not crucial - for a browser that actively supports web applications. There are many use cases where desktop notifications come in handy and are essential for a true replacement of native applications like web interfaces for messaging/email services (new message), calendar/todo (reminder), streaming services (currently playing),... Many of them already implement the Notification API and many do not have a native alternative for gnome/linux systems. Would be cool...
*** Bug 738911 has been marked as a duplicate of this bug. ***
*** This bug has been marked as a duplicate of bug 741295 ***