From 4ff02f753fefef3430438c3c5f0f3ba6a5271ddb Mon Sep 17 00:00:00 2001 From: "scherkus@chromium.org" Date: Thu, 12 Nov 2009 23:48:32 +0000 Subject: Revert 31839 - Notifications permission infobar should only be shown in response to a user gesture, not arbitrary script. Includes UI test which verify the infobar is shown from a gesture, and not shown from raw script. BUG=27215 TEST=included Review URL: http://codereview.chromium.org/387011 TBR=johnnyg@chromium.org Review URL: http://codereview.chromium.org/385080 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31857 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/renderer/notification_provider.cc | 4 ---- 1 file changed, 4 deletions(-) (limited to 'chrome/renderer') diff --git a/chrome/renderer/notification_provider.cc b/chrome/renderer/notification_provider.cc index 6746350..9510cab 100644 --- a/chrome/renderer/notification_provider.cc +++ b/chrome/renderer/notification_provider.cc @@ -55,10 +55,6 @@ WebNotificationPresenter::Permission NotificationProvider::checkPermission( void NotificationProvider::requestPermission( const WebString& origin, WebNotificationPermissionCallback* callback) { - // We only request permission in response to a user gesture. - if (!view_->webview()->mainFrame()->isProcessingUserGesture()) - return; - int id = manager_.RegisterPermissionRequest(callback); Send(new ViewHostMsg_RequestNotificationPermission(view_->routing_id(), -- cgit v1.1