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 <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/memory/ptr_util.h" | 10 #include "base/memory/ptr_util.h" |
(...skipping 27 matching lines...) Expand all Loading... |
38 #include "chrome/browser/profiles/profile_manager.h" | 38 #include "chrome/browser/profiles/profile_manager.h" |
39 #include "chrome/browser/renderer_host/chrome_navigation_ui_data.h" | 39 #include "chrome/browser/renderer_host/chrome_navigation_ui_data.h" |
40 #include "chrome/browser/sessions/session_tab_helper.h" | 40 #include "chrome/browser/sessions/session_tab_helper.h" |
41 #include "chrome/browser/task_manager/web_contents_tags.h" | 41 #include "chrome/browser/task_manager/web_contents_tags.h" |
42 #include "chrome/browser/ui/bluetooth/chrome_extension_bluetooth_chooser.h" | 42 #include "chrome/browser/ui/bluetooth/chrome_extension_bluetooth_chooser.h" |
43 #include "chrome/common/channel_info.h" | 43 #include "chrome/common/channel_info.h" |
44 #include "chrome/common/chrome_paths.h" | 44 #include "chrome/common/chrome_paths.h" |
45 #include "chrome/common/chrome_switches.h" | 45 #include "chrome/common/chrome_switches.h" |
46 #include "chrome/common/pref_names.h" | 46 #include "chrome/common/pref_names.h" |
47 #include "components/net_log/chrome_net_log.h" | 47 #include "components/net_log/chrome_net_log.h" |
| 48 #include "components/session_manager/core/session_manager.h" |
48 #include "components/update_client/update_client.h" | 49 #include "components/update_client/update_client.h" |
49 #include "components/version_info/version_info.h" | 50 #include "components/version_info/version_info.h" |
50 #include "content/public/browser/render_process_host.h" | 51 #include "content/public/browser/render_process_host.h" |
51 #include "content/public/browser/resource_request_info.h" | 52 #include "content/public/browser/resource_request_info.h" |
52 #include "content/public/common/content_switches.h" | 53 #include "content/public/common/content_switches.h" |
53 #include "extensions/browser/api/generated_api_registration.h" | 54 #include "extensions/browser/api/generated_api_registration.h" |
54 #include "extensions/browser/extension_function_registry.h" | 55 #include "extensions/browser/extension_function_registry.h" |
55 #include "extensions/browser/extension_prefs.h" | 56 #include "extensions/browser/extension_prefs.h" |
56 #include "extensions/browser/extension_util.h" | 57 #include "extensions/browser/extension_util.h" |
57 #include "extensions/browser/mojo/service_registration.h" | 58 #include "extensions/browser/mojo/service_registration.h" |
(...skipping 374 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
432 return nullptr; | 433 return nullptr; |
433 return navigation_data->GetExtensionNavigationUIData(); | 434 return navigation_data->GetExtensionNavigationUIData(); |
434 } | 435 } |
435 | 436 |
436 KioskDelegate* ChromeExtensionsBrowserClient::GetKioskDelegate() { | 437 KioskDelegate* ChromeExtensionsBrowserClient::GetKioskDelegate() { |
437 if (!kiosk_delegate_) | 438 if (!kiosk_delegate_) |
438 kiosk_delegate_.reset(new ChromeKioskDelegate()); | 439 kiosk_delegate_.reset(new ChromeKioskDelegate()); |
439 return kiosk_delegate_.get(); | 440 return kiosk_delegate_.get(); |
440 } | 441 } |
441 | 442 |
| 443 bool ChromeExtensionsBrowserClient::IsLockScreenContext( |
| 444 content::BrowserContext* context) { |
| 445 #if defined(OS_CHROMEOS) |
| 446 return chromeos::ProfileHelper::IsSigninProfile( |
| 447 Profile::FromBrowserContext(context)) && |
| 448 session_manager::SessionManager::Get()->IsSessionStarted(); |
| 449 #else |
| 450 return false; |
| 451 #endif |
| 452 } |
442 } // namespace extensions | 453 } // namespace extensions |
OLD | NEW |