| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/extensions/chrome_extensions_browser_client.h" | 5 #include "chrome/browser/extensions/chrome_extensions_browser_client.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/version.h" | 8 #include "base/version.h" |
| 9 #include "chrome/browser/app_mode/app_mode_utils.h" | 9 #include "chrome/browser/app_mode/app_mode_utils.h" |
| 10 #include "chrome/browser/browser_process.h" | 10 #include "chrome/browser/browser_process.h" |
| (...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 214 if (!last_version.IsValid()) | 214 if (!last_version.IsValid()) |
| 215 return true; | 215 return true; |
| 216 | 216 |
| 217 return last_version.IsOlderThan(current_version); | 217 return last_version.IsOlderThan(current_version); |
| 218 } | 218 } |
| 219 | 219 |
| 220 void ChromeExtensionsBrowserClient::PermitExternalProtocolHandler() { | 220 void ChromeExtensionsBrowserClient::PermitExternalProtocolHandler() { |
| 221 ExternalProtocolHandler::PermitLaunchUrl(); | 221 ExternalProtocolHandler::PermitLaunchUrl(); |
| 222 } | 222 } |
| 223 | 223 |
| 224 scoped_ptr<AppSorting> ChromeExtensionsBrowserClient::CreateAppSorting() { | 224 scoped_ptr<AppSorting> ChromeExtensionsBrowserClient::CreateAppSorting( |
| 225 return scoped_ptr<AppSorting>(new ChromeAppSorting()); | 225 content::BrowserContext* context) { |
| 226 return scoped_ptr<AppSorting>(new ChromeAppSorting(context)); |
| 226 } | 227 } |
| 227 | 228 |
| 228 bool ChromeExtensionsBrowserClient::IsRunningInForcedAppMode() { | 229 bool ChromeExtensionsBrowserClient::IsRunningInForcedAppMode() { |
| 229 return chrome::IsRunningInForcedAppMode(); | 230 return chrome::IsRunningInForcedAppMode(); |
| 230 } | 231 } |
| 231 | 232 |
| 232 ApiActivityMonitor* ChromeExtensionsBrowserClient::GetApiActivityMonitor( | 233 ApiActivityMonitor* ChromeExtensionsBrowserClient::GetApiActivityMonitor( |
| 233 content::BrowserContext* context) { | 234 content::BrowserContext* context) { |
| 234 // The ActivityLog monitors and records function calls and events. | 235 // The ActivityLog monitors and records function calls and events. |
| 235 return ActivityLog::GetInstance(context); | 236 return ActivityLog::GetInstance(context); |
| (...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 340 ->GetBrowserContext(); | 341 ->GetBrowserContext(); |
| 341 | 342 |
| 342 // Clean up context menus for the WebView. | 343 // Clean up context menus for the WebView. |
| 343 auto menu_manager = | 344 auto menu_manager = |
| 344 MenuManager::Get(Profile::FromBrowserContext(browser_context)); | 345 MenuManager::Get(Profile::FromBrowserContext(browser_context)); |
| 345 menu_manager->RemoveAllContextItems( | 346 menu_manager->RemoveAllContextItems( |
| 346 MenuItem::ExtensionKey("", embedder_process_id, view_instance_id)); | 347 MenuItem::ExtensionKey("", embedder_process_id, view_instance_id)); |
| 347 } | 348 } |
| 348 | 349 |
| 349 } // namespace extensions | 350 } // namespace extensions |
| OLD | NEW |