| 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 UI_VIEWS_MUS_AURA_INIT_H_ | 5 #ifndef UI_VIEWS_MUS_AURA_INIT_H_ |
| 6 #define UI_VIEWS_MUS_AURA_INIT_H_ | 6 #define UI_VIEWS_MUS_AURA_INIT_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 59 const std::string& resource_file, | 59 const std::string& resource_file, |
| 60 const std::string& resource_file_200 = std::string(), | 60 const std::string& resource_file_200 = std::string(), |
| 61 scoped_refptr<base::SingleThreadTaskRunner> io_task_runner = nullptr, | 61 scoped_refptr<base::SingleThreadTaskRunner> io_task_runner = nullptr, |
| 62 Mode mode = Mode::UI); | 62 Mode mode = Mode::UI); |
| 63 ~AuraInit(); | 63 ~AuraInit(); |
| 64 | 64 |
| 65 // Only valid if Mode::AURA_MUS was passed to constructor. | 65 // Only valid if Mode::AURA_MUS was passed to constructor. |
| 66 MusClient* mus_client() { return mus_client_.get(); } | 66 MusClient* mus_client() { return mus_client_.get(); } |
| 67 | 67 |
| 68 private: | 68 private: |
| 69 void InitializeResources(service_manager::Connector* connector); | 69 // Attempts to initialize the resource bundle. Returns true if successful, |
| 70 // otherwise false if resources cannot be loaded. |
| 71 bool InitializeResources(service_manager::Connector* connector); |
| 70 | 72 |
| 71 #if defined(OS_LINUX) | 73 #if defined(OS_LINUX) |
| 72 sk_sp<font_service::FontLoader> font_loader_; | 74 sk_sp<font_service::FontLoader> font_loader_; |
| 73 #endif | 75 #endif |
| 74 | 76 |
| 75 const std::string resource_file_; | 77 const std::string resource_file_; |
| 76 const std::string resource_file_200_; | 78 const std::string resource_file_200_; |
| 77 | 79 |
| 78 std::unique_ptr<aura::Env> env_; | 80 std::unique_ptr<aura::Env> env_; |
| 79 std::unique_ptr<MusClient> mus_client_; | 81 std::unique_ptr<MusClient> mus_client_; |
| 80 std::unique_ptr<ViewsDelegate> views_delegate_; | 82 std::unique_ptr<ViewsDelegate> views_delegate_; |
| 81 | 83 |
| 82 DISALLOW_COPY_AND_ASSIGN(AuraInit); | 84 DISALLOW_COPY_AND_ASSIGN(AuraInit); |
| 83 }; | 85 }; |
| 84 | 86 |
| 85 } // namespace views | 87 } // namespace views |
| 86 | 88 |
| 87 #endif // UI_VIEWS_MUS_AURA_INIT_H_ | 89 #endif // UI_VIEWS_MUS_AURA_INIT_H_ |
| OLD | NEW |