OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 "base/logging.h" | 5 #include "base/logging.h" |
6 #include "build/build_config.h" | 6 #include "build/build_config.h" |
7 #include "chrome/browser/browser_process_platform_part_base.h" | 7 #include "chrome/browser/browser_process_platform_part_base.h" |
8 #include "chrome/browser/lifetime/application_lifetime.h" | 8 #include "chrome/browser/lifetime/application_lifetime.h" |
9 | |
10 #if defined(ENABLE_CONFIGURATION_POLICY) | |
11 #include "chrome/browser/policy/chrome_browser_policy_connector.h" | 9 #include "chrome/browser/policy/chrome_browser_policy_connector.h" |
12 #include "components/policy/core/browser/browser_policy_connector.h" | 10 #include "components/policy/core/browser/browser_policy_connector.h" |
13 #endif | |
14 | 11 |
15 BrowserProcessPlatformPartBase::BrowserProcessPlatformPartBase() { | 12 BrowserProcessPlatformPartBase::BrowserProcessPlatformPartBase() { |
16 } | 13 } |
17 | 14 |
18 BrowserProcessPlatformPartBase::~BrowserProcessPlatformPartBase() { | 15 BrowserProcessPlatformPartBase::~BrowserProcessPlatformPartBase() { |
19 } | 16 } |
20 | 17 |
21 void BrowserProcessPlatformPartBase::PlatformSpecificCommandLineProcessing( | 18 void BrowserProcessPlatformPartBase::PlatformSpecificCommandLineProcessing( |
22 const base::CommandLine& /* command_line */) { | 19 const base::CommandLine& /* command_line */) { |
23 } | 20 } |
24 | 21 |
25 void BrowserProcessPlatformPartBase::StartTearDown() { | 22 void BrowserProcessPlatformPartBase::StartTearDown() { |
26 } | 23 } |
27 | 24 |
28 void BrowserProcessPlatformPartBase::AttemptExit() { | 25 void BrowserProcessPlatformPartBase::AttemptExit() { |
29 // chrome::CloseAllBrowsers() doesn't link on OS_ANDROID, but it overrides this | 26 // chrome::CloseAllBrowsers() doesn't link on OS_ANDROID, but it overrides this |
30 // method already. | 27 // method already. |
31 #if defined(OS_ANDROID) | 28 #if defined(OS_ANDROID) |
32 NOTREACHED(); | 29 NOTREACHED(); |
33 #else | 30 #else |
34 // On most platforms, closing all windows causes the application to exit. | 31 // On most platforms, closing all windows causes the application to exit. |
35 chrome::CloseAllBrowsers(); | 32 chrome::CloseAllBrowsers(); |
36 #endif | 33 #endif |
37 } | 34 } |
38 | 35 |
39 void BrowserProcessPlatformPartBase::PreMainMessageLoopRun() { | 36 void BrowserProcessPlatformPartBase::PreMainMessageLoopRun() { |
40 } | 37 } |
41 | 38 |
42 #if defined(ENABLE_CONFIGURATION_POLICY) | |
43 scoped_ptr<policy::BrowserPolicyConnector> | 39 scoped_ptr<policy::BrowserPolicyConnector> |
44 BrowserProcessPlatformPartBase::CreateBrowserPolicyConnector() { | 40 BrowserProcessPlatformPartBase::CreateBrowserPolicyConnector() { |
45 return scoped_ptr<policy::BrowserPolicyConnector>( | 41 return scoped_ptr<policy::BrowserPolicyConnector>( |
46 new policy::ChromeBrowserPolicyConnector()); | 42 new policy::ChromeBrowserPolicyConnector()); |
47 } | 43 } |
48 #endif | |
OLD | NEW |