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

Side by Side Diff: components/arc/window_manager/arc_window_manager_bridge.h

Issue 2133503002: arc: Revamp the ArcBridgeService interface (Closed) Base URL: https://chromium.googlesource.com/a/chromium/src.git@master
Patch Set: More rebasing Created 4 years, 5 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_WINDOW_MANAGER_ARC_WINDOW_MANAGER_BRIDGE_H_ 5 #ifndef COMPONENTS_ARC_WINDOW_MANAGER_ARC_WINDOW_MANAGER_BRIDGE_H_
6 #define COMPONENTS_ARC_WINDOW_MANAGER_ARC_WINDOW_MANAGER_BRIDGE_H_ 6 #define COMPONENTS_ARC_WINDOW_MANAGER_ARC_WINDOW_MANAGER_BRIDGE_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "ash/common/shell_observer.h" 10 #include "ash/common/shell_observer.h"
11 #include "base/macros.h" 11 #include "base/macros.h"
12 #include "components/arc/arc_bridge_service.h" 12 #include "components/arc/arc_bridge_service.h"
13 #include "components/arc/arc_service.h" 13 #include "components/arc/arc_service.h"
14 #include "components/arc/instance_holder.h"
14 15
15 namespace arc { 16 namespace arc {
16 17
17 class ArcWindowManagerBridge : public ArcService, 18 class ArcWindowManagerBridge
18 public ArcBridgeService::Observer, 19 : public ArcService,
19 public ash::ShellObserver { 20 public InstanceHolder<mojom::WindowManagerInstance>::Observer,
21 public ash::ShellObserver {
20 public: 22 public:
21 explicit ArcWindowManagerBridge(ArcBridgeService* bridge_service); 23 explicit ArcWindowManagerBridge(ArcBridgeService* bridge_service);
22 ~ArcWindowManagerBridge() override; 24 ~ArcWindowManagerBridge() override;
23 25
24 // ArcBridgeService::Observer 26 // InstanceHolder<mojom::WindowManagerInstance>::Observer
25 void OnWindowManagerInstanceReady() override; 27 void OnInstanceReady() override;
26 28
27 // Ash::Shell::ShellObserver 29 // Ash::Shell::ShellObserver
28 void OnMaximizeModeStarted() override; 30 void OnMaximizeModeStarted() override;
29 void OnMaximizeModeEnded() override; 31 void OnMaximizeModeEnded() override;
30 32
31 private: 33 private:
32 void SendWindowManagerModeChange(bool touch_view_enabled); 34 void SendWindowManagerModeChange(bool touch_view_enabled);
33 35
34 // Remembers the currently set mode on the Android side. 36 // Remembers the currently set mode on the Android side.
35 mojom::WindowManagerMode current_mode_; 37 mojom::WindowManagerMode current_mode_;
36 38
37 DISALLOW_COPY_AND_ASSIGN(ArcWindowManagerBridge); 39 DISALLOW_COPY_AND_ASSIGN(ArcWindowManagerBridge);
38 }; 40 };
39 41
40 } // namespace arc 42 } // namespace arc
41 43
42 #endif // COMPONENTS_ARC_WINDOW_MANAGER_ARC_WINDOW_MANAGER_BRIDGE_H_ 44 #endif // COMPONENTS_ARC_WINDOW_MANAGER_ARC_WINDOW_MANAGER_BRIDGE_H_
OLDNEW
« no previous file with comments | « components/arc/test/fake_policy_instance.cc ('k') | components/arc/window_manager/arc_window_manager_bridge.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698