| 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 // This interface is for managing the global services of the application. Each | 5 // This interface is for managing the global services of the application. Each |
| 6 // service is lazily created when requested the first time. The service getters | 6 // service is lazily created when requested the first time. The service getters |
| 7 // will return NULL if the service is not available, so callers must check for | 7 // will return NULL if the service is not available, so callers must check for |
| 8 // this condition. | 8 // this condition. |
| 9 | 9 |
| 10 #ifndef CHROME_BROWSER_BROWSER_PROCESS_H_ | 10 #ifndef CHROME_BROWSER_BROWSER_PROCESS_H_ |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 64 namespace printing { | 64 namespace printing { |
| 65 class BackgroundPrintingManager; | 65 class BackgroundPrintingManager; |
| 66 class PrintJobManager; | 66 class PrintJobManager; |
| 67 class PrintPreviewTabController; | 67 class PrintPreviewTabController; |
| 68 } | 68 } |
| 69 | 69 |
| 70 namespace safe_browsing { | 70 namespace safe_browsing { |
| 71 class ClientSideDetectionService; | 71 class ClientSideDetectionService; |
| 72 } | 72 } |
| 73 | 73 |
| 74 namespace ui { | |
| 75 class Clipboard; | |
| 76 } | |
| 77 | |
| 78 // NOT THREAD SAFE, call only from the main thread. | 74 // NOT THREAD SAFE, call only from the main thread. |
| 79 // These functions shouldn't return NULL unless otherwise noted. | 75 // These functions shouldn't return NULL unless otherwise noted. |
| 80 class BrowserProcess { | 76 class BrowserProcess { |
| 81 public: | 77 public: |
| 82 BrowserProcess(); | 78 BrowserProcess(); |
| 83 virtual ~BrowserProcess(); | 79 virtual ~BrowserProcess(); |
| 84 | 80 |
| 85 // Called when the ResourceDispatcherHost object is created by content. | 81 // Called when the ResourceDispatcherHost object is created by content. |
| 86 virtual void ResourceDispatcherHostCreated() = 0; | 82 virtual void ResourceDispatcherHostCreated() = 0; |
| 87 | 83 |
| 88 // Invoked when the user is logging out/shutting down. When logging off we may | 84 // Invoked when the user is logging out/shutting down. When logging off we may |
| 89 // not have enough time to do a normal shutdown. This method is invoked prior | 85 // not have enough time to do a normal shutdown. This method is invoked prior |
| 90 // to normal shutdown and saves any state that must be saved before we are | 86 // to normal shutdown and saves any state that must be saved before we are |
| 91 // continue shutdown. | 87 // continue shutdown. |
| 92 virtual void EndSession() = 0; | 88 virtual void EndSession() = 0; |
| 93 | 89 |
| 94 // Services: any of these getters may return NULL | 90 // Services: any of these getters may return NULL |
| 95 virtual MetricsService* metrics_service() = 0; | 91 virtual MetricsService* metrics_service() = 0; |
| 96 virtual ProfileManager* profile_manager() = 0; | 92 virtual ProfileManager* profile_manager() = 0; |
| 97 virtual PrefService* local_state() = 0; | 93 virtual PrefService* local_state() = 0; |
| 98 virtual ui::Clipboard* clipboard() = 0; | |
| 99 virtual net::URLRequestContextGetter* system_request_context() = 0; | 94 virtual net::URLRequestContextGetter* system_request_context() = 0; |
| 100 virtual chrome_variations::VariationsService* variations_service() = 0; | 95 virtual chrome_variations::VariationsService* variations_service() = 0; |
| 101 | 96 |
| 102 #if defined(OS_CHROMEOS) | 97 #if defined(OS_CHROMEOS) |
| 103 // Returns the out-of-memory priority manager. | 98 // Returns the out-of-memory priority manager. |
| 104 virtual chromeos::OomPriorityManager* oom_priority_manager() = 0; | 99 virtual chromeos::OomPriorityManager* oom_priority_manager() = 0; |
| 105 #endif // defined(OS_CHROMEOS) | 100 #endif // defined(OS_CHROMEOS) |
| 106 | 101 |
| 107 virtual extensions::EventRouterForwarder* | 102 virtual extensions::EventRouterForwarder* |
| 108 extension_event_router_forwarder() = 0; | 103 extension_event_router_forwarder() = 0; |
| (...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 201 | 196 |
| 202 virtual CRLSetFetcher* crl_set_fetcher() = 0; | 197 virtual CRLSetFetcher* crl_set_fetcher() = 0; |
| 203 | 198 |
| 204 private: | 199 private: |
| 205 DISALLOW_COPY_AND_ASSIGN(BrowserProcess); | 200 DISALLOW_COPY_AND_ASSIGN(BrowserProcess); |
| 206 }; | 201 }; |
| 207 | 202 |
| 208 extern BrowserProcess* g_browser_process; | 203 extern BrowserProcess* g_browser_process; |
| 209 | 204 |
| 210 #endif // CHROME_BROWSER_BROWSER_PROCESS_H_ | 205 #endif // CHROME_BROWSER_BROWSER_PROCESS_H_ |
| OLD | NEW |