allow client to decide displaying web notifications

This commit is contained in:
Robo 2016-01-23 19:02:30 +05:30
parent 147c09f7d2
commit 3b09c370d4
3 changed files with 39 additions and 12 deletions

View file

@ -28,6 +28,12 @@ class BrowserClient : public content::ContentBrowserClient {
NotificationPresenter* GetNotificationPresenter();
// Subclasses should override this to enable or disable WebNotification.
virtual void WebNotificationAllowed(int render_process_id,
const base::Callback<void(bool)>& callback) {
callback.Run(true);
}
protected:
// Subclasses should override this to provide their own BrowserMainParts
// implementation. The lifetime of the returned instance is managed by the