| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/geolocation/chrome_geolocation_permission_context.h" | 5 #include "chrome/browser/geolocation/chrome_geolocation_permission_context.h" |
| 6 | 6 |
| 7 #include <functional> | 7 #include <functional> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| 11 #include "base/bind.h" | 11 #include "base/bind.h" |
| 12 #include "base/strings/utf_string_conversions.h" | 12 #include "base/strings/utf_string_conversions.h" |
| 13 #include "chrome/browser/content_settings/host_content_settings_map.h" | 13 #include "chrome/browser/content_settings/host_content_settings_map.h" |
| 14 #include "chrome/browser/content_settings/permission_request_id.h" | 14 #include "chrome/browser/content_settings/permission_request_id.h" |
| 15 #include "chrome/browser/content_settings/tab_specific_content_settings.h" | 15 #include "chrome/browser/content_settings/tab_specific_content_settings.h" |
| 16 #include "chrome/browser/extensions/extension_service.h" | 16 #include "chrome/browser/extensions/extension_service.h" |
| 17 #include "chrome/browser/extensions/extension_system.h" | 17 #include "chrome/browser/extensions/extension_system.h" |
| 18 #include "chrome/browser/extensions/suggest_permission_util.h" | 18 #include "chrome/browser/extensions/suggest_permission_util.h" |
| 19 #include "chrome/browser/profiles/profile.h" | 19 #include "chrome/browser/profiles/profile.h" |
| 20 #include "chrome/browser/tab_contents/tab_util.h" | 20 #include "chrome/browser/tab_contents/tab_util.h" |
| 21 #include "chrome/common/extensions/extension.h" | |
| 22 #include "content/public/browser/browser_thread.h" | 21 #include "content/public/browser/browser_thread.h" |
| 23 #include "content/public/browser/render_view_host.h" | 22 #include "content/public/browser/render_view_host.h" |
| 24 #include "content/public/browser/web_contents.h" | 23 #include "content/public/browser/web_contents.h" |
| 25 #include "extensions/browser/view_type_utils.h" | 24 #include "extensions/browser/view_type_utils.h" |
| 25 #include "extensions/common/extension.h" |
| 26 | 26 |
| 27 using extensions::APIPermission; | 27 using extensions::APIPermission; |
| 28 | 28 |
| 29 ChromeGeolocationPermissionContext::ChromeGeolocationPermissionContext( | 29 ChromeGeolocationPermissionContext::ChromeGeolocationPermissionContext( |
| 30 Profile* profile) | 30 Profile* profile) |
| 31 : profile_(profile), | 31 : profile_(profile), |
| 32 shutting_down_(false) { | 32 shutting_down_(false) { |
| 33 } | 33 } |
| 34 | 34 |
| 35 ChromeGeolocationPermissionContext::~ChromeGeolocationPermissionContext() { | 35 ChromeGeolocationPermissionContext::~ChromeGeolocationPermissionContext() { |
| (...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 201 base::Bind( | 201 base::Bind( |
| 202 &ChromeGeolocationPermissionContext::CancelPendingInfoBarRequest, | 202 &ChromeGeolocationPermissionContext::CancelPendingInfoBarRequest, |
| 203 this, id)); | 203 this, id)); |
| 204 return; | 204 return; |
| 205 } | 205 } |
| 206 DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI)); | 206 DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI)); |
| 207 if (shutting_down_) | 207 if (shutting_down_) |
| 208 return; | 208 return; |
| 209 QueueController()->CancelInfoBarRequest(id); | 209 QueueController()->CancelInfoBarRequest(id); |
| 210 } | 210 } |
| OLD | NEW |