Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(119)

Side by Side Diff: components/arc/arc_service_manager.h

Issue 1477733002: Add ArcNotificationManager for new ARC notification (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Sync dependencies Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « components/arc/DEPS ('k') | components/arc/arc_service_manager.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 COMPONENTS_ARC_ARC_SERVICE_MANAGER_H_ 5 #ifndef COMPONENTS_ARC_ARC_SERVICE_MANAGER_H_
6 #define COMPONENTS_ARC_ARC_SERVICE_MANAGER_H_ 6 #define COMPONENTS_ARC_ARC_SERVICE_MANAGER_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/threading/thread_checker.h" 10 #include "base/threading/thread_checker.h"
11 #include "components/signin/core/account_id/account_id.h"
11 12
12 namespace arc { 13 namespace arc {
13 14
14 class ArcAuthService; 15 class ArcAuthService;
15 class ArcBridgeService; 16 class ArcBridgeService;
16 class ArcClipboardBridge; 17 class ArcClipboardBridge;
17 class ArcInputBridge; 18 class ArcInputBridge;
19 class ArcNotificationManager;
18 class ArcPowerBridge; 20 class ArcPowerBridge;
19 class ArcSettingsBridge; 21 class ArcSettingsBridge;
20 class ArcVideoBridge; 22 class ArcVideoBridge;
21 23
22 // Manages creation and destruction of services that communicate with the ARC 24 // Manages creation and destruction of services that communicate with the ARC
23 // instance via the ArcBridgeService. 25 // instance via the ArcBridgeService.
24 class ArcServiceManager { 26 class ArcServiceManager {
25 public: 27 public:
26 ArcServiceManager(scoped_ptr<ArcAuthService> auth_service, 28 ArcServiceManager(scoped_ptr<ArcAuthService> auth_service,
27 scoped_ptr<ArcSettingsBridge> settings_bridge, 29 scoped_ptr<ArcSettingsBridge> settings_bridge,
28 scoped_ptr<ArcVideoBridge> video_bridge); 30 scoped_ptr<ArcVideoBridge> video_bridge);
29 virtual ~ArcServiceManager(); 31 virtual ~ArcServiceManager();
30 32
31 // |arc_bridge_service| can only be accessed on the thread that this 33 // |arc_bridge_service| can only be accessed on the thread that this
32 // class was created on. 34 // class was created on.
33 ArcBridgeService* arc_bridge_service(); 35 ArcBridgeService* arc_bridge_service();
34 36
35 // Gets the global instance of the ARC Service Manager. This can only be 37 // Gets the global instance of the ARC Service Manager. This can only be
36 // called on the thread that this class was created on. 38 // called on the thread that this class was created on.
37 static ArcServiceManager* Get(); 39 static ArcServiceManager* Get();
38 40
41 // Called when the main profile is initialized after user logs in.
42 void OnPrimaryUserProfilePrepared(const AccountId& account_id);
43
39 private: 44 private:
40 base::ThreadChecker thread_checker_; 45 base::ThreadChecker thread_checker_;
41 scoped_ptr<ArcBridgeService> arc_bridge_service_; 46 scoped_ptr<ArcBridgeService> arc_bridge_service_;
42 47
43 // Individual services 48 // Individual services
44 scoped_ptr<ArcAuthService> arc_auth_service_; 49 scoped_ptr<ArcAuthService> arc_auth_service_;
45 scoped_ptr<ArcClipboardBridge> arc_clipboard_bridge_; 50 scoped_ptr<ArcClipboardBridge> arc_clipboard_bridge_;
46 scoped_ptr<ArcInputBridge> arc_input_bridge_; 51 scoped_ptr<ArcInputBridge> arc_input_bridge_;
52 scoped_ptr<ArcNotificationManager> arc_notification_manager_;
47 scoped_ptr<ArcSettingsBridge> arc_settings_bridge_; 53 scoped_ptr<ArcSettingsBridge> arc_settings_bridge_;
48 scoped_ptr<ArcPowerBridge> arc_power_bridge_; 54 scoped_ptr<ArcPowerBridge> arc_power_bridge_;
49 scoped_ptr<ArcVideoBridge> arc_video_bridge_; 55 scoped_ptr<ArcVideoBridge> arc_video_bridge_;
50 56
51 DISALLOW_COPY_AND_ASSIGN(ArcServiceManager); 57 DISALLOW_COPY_AND_ASSIGN(ArcServiceManager);
52 }; 58 };
53 59
54 } // namespace arc 60 } // namespace arc
55 61
56 #endif // COMPONENTS_ARC_ARC_SERVICE_MANAGER_H_ 62 #endif // COMPONENTS_ARC_ARC_SERVICE_MANAGER_H_
OLDNEW
« no previous file with comments | « components/arc/DEPS ('k') | components/arc/arc_service_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698