| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 #ifndef BLIMP_ENGINE_APP_BLIMP_BROWSER_MAIN_PARTS_H_ | 5 #ifndef BLIMP_ENGINE_APP_BLIMP_BROWSER_MAIN_PARTS_H_ |
| 6 #define BLIMP_ENGINE_APP_BLIMP_BROWSER_MAIN_PARTS_H_ | 6 #define BLIMP_ENGINE_APP_BLIMP_BROWSER_MAIN_PARTS_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 class BlimpBrowserContext; | 29 class BlimpBrowserContext; |
| 30 class BlimpEngineConfig; | 30 class BlimpEngineConfig; |
| 31 class BlimpEngineSession; | 31 class BlimpEngineSession; |
| 32 class SettingsManager; | 32 class SettingsManager; |
| 33 | 33 |
| 34 class BlimpBrowserMainParts : public content::BrowserMainParts { | 34 class BlimpBrowserMainParts : public content::BrowserMainParts { |
| 35 public: | 35 public: |
| 36 explicit BlimpBrowserMainParts(const content::MainFunctionParams& parameters); | 36 explicit BlimpBrowserMainParts(const content::MainFunctionParams& parameters); |
| 37 ~BlimpBrowserMainParts() override; | 37 ~BlimpBrowserMainParts() override; |
| 38 | 38 |
| 39 // content::BrowserMainParts implementation. | |
| 40 void PreEarlyInitialization() override; | |
| 41 void PreMainMessageLoopRun() override; | |
| 42 void PostMainMessageLoopRun() override; | |
| 43 | |
| 44 BlimpBrowserContext* GetBrowserContext(); | 39 BlimpBrowserContext* GetBrowserContext(); |
| 45 SettingsManager* GetSettingsManager(); | 40 SettingsManager* GetSettingsManager(); |
| 46 BlobChannelSender* GetBlobChannelSender(); | 41 BlobChannelSender* GetBlobChannelSender(); |
| 47 BlobChannelService* GetBlobChannelService(); | 42 BlobChannelService* GetBlobChannelService(); |
| 48 BlimpEngineSession* GetBlimpEngineSession(); | 43 BlimpEngineSession* GetBlimpEngineSession(); |
| 49 | 44 |
| 45 // content::BrowserMainParts implementation. |
| 46 void PreEarlyInitialization() override; |
| 47 void PreMainMessageLoopRun() override; |
| 48 void PostMainMessageLoopRun() override; |
| 49 |
| 50 protected: |
| 51 void SetSettingsManagerForTesting( |
| 52 std::unique_ptr<SettingsManager> settings_manager); |
| 53 void SetEngineSessionForTesting( |
| 54 std::unique_ptr<BlimpEngineSession> engine_session); |
| 55 |
| 50 private: | 56 private: |
| 51 std::unique_ptr<BlimpEngineConfig> engine_config_; | 57 std::unique_ptr<BlimpEngineConfig> engine_config_; |
| 52 std::unique_ptr<net::NetLog> net_log_; | 58 std::unique_ptr<net::NetLog> net_log_; |
| 53 std::unique_ptr<SettingsManager> settings_manager_; | 59 std::unique_ptr<SettingsManager> settings_manager_; |
| 54 std::unique_ptr<BlimpEngineSession> engine_session_; | 60 std::unique_ptr<BlimpEngineSession> engine_session_; |
| 55 | 61 |
| 56 DISALLOW_COPY_AND_ASSIGN(BlimpBrowserMainParts); | 62 DISALLOW_COPY_AND_ASSIGN(BlimpBrowserMainParts); |
| 57 }; | 63 }; |
| 58 | 64 |
| 59 } // namespace engine | 65 } // namespace engine |
| 60 } // namespace blimp | 66 } // namespace blimp |
| 61 | 67 |
| 62 #endif // BLIMP_ENGINE_APP_BLIMP_BROWSER_MAIN_PARTS_H_ | 68 #endif // BLIMP_ENGINE_APP_BLIMP_BROWSER_MAIN_PARTS_H_ |
| OLD | NEW |