diff options
author | lazyboy@chromium.org <lazyboy@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-03-09 01:32:49 +0000 |
---|---|---|
committer | lazyboy@chromium.org <lazyboy@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-03-09 01:32:49 +0000 |
commit | e4a55a597c2d3ad0e7b1fad022c510452171a248 (patch) | |
tree | f6f68d9a59401c2cdcfa6fa51ed2f8a72502a4e7 /content/renderer | |
parent | eba66b0c2f522302638803d3c04827b901c95ba5 (diff) | |
download | chromium_src-e4a55a597c2d3ad0e7b1fad022c510452171a248.zip chromium_src-e4a55a597c2d3ad0e7b1fad022c510452171a248.tar.gz chromium_src-e4a55a597c2d3ad0e7b1fad022c510452171a248.tar.bz2 |
<browser>: permissionRequest API for geolocation.
BUG=141195
TEST=Added browsertests: WebViewTest.GeolocationAPI*
Review URL: https://chromiumcodereview.appspot.com/11142012
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@187099 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/renderer')
-rw-r--r-- | content/renderer/browser_plugin/browser_plugin.cc | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/content/renderer/browser_plugin/browser_plugin.cc b/content/renderer/browser_plugin/browser_plugin.cc index 37fe6eb..ee6a713 100644 --- a/content/renderer/browser_plugin/browser_plugin.cc +++ b/content/renderer/browser_plugin/browser_plugin.cc @@ -75,8 +75,11 @@ static std::string GetInternalEventName(const char* event_name) { static std::string PermissionTypeToString(BrowserPluginPermissionType type) { switch (type) { + case BrowserPluginPermissionTypeGeolocation: + return browser_plugin::kPermissionTypeGeolocation; case BrowserPluginPermissionTypeMedia: return browser_plugin::kPermissionTypeMedia; + case BrowserPluginPermissionTypeUnknown: default: NOTREACHED(); break; @@ -419,7 +422,7 @@ void BrowserPlugin::OnBuffersSwapped(int instance_id, } void BrowserPlugin::OnGuestContentWindowReady(int instance_id, - int content_window_routing_id) { + int content_window_routing_id) { DCHECK(content_window_routing_id != MSG_ROUTING_NONE); content_window_routing_id_ = content_window_routing_id; } @@ -538,15 +541,14 @@ void BrowserPlugin::OnLockMouse(int instance_id, } void BrowserPlugin::OnRequestPermission( - int /*instance_id*/, + int instance_id, BrowserPluginPermissionType permission_type, int request_id, const base::DictionaryValue& request_info) { if (!HasEventListeners(browser_plugin::kEventRequestPermission)) { // Automatically deny the request if there are no event listeners for // permissionrequest. - RespondPermission( - permission_type, request_id, false /* allow */); + RespondPermission(permission_type, request_id, false /* allow */); return; } DCHECK(!pending_permission_requests_.count(request_id)); |