OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_MUS_WS_CLIENT_CONNECTION_H_ | 5 #ifndef COMPONENTS_MUS_WS_CLIENT_CONNECTION_H_ |
6 #define COMPONENTS_MUS_WS_CLIENT_CONNECTION_H_ | 6 #define COMPONENTS_MUS_WS_CLIENT_CONNECTION_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 "components/mus/public/interfaces/window_tree.mojom.h" | 10 #include "components/mus/public/interfaces/window_tree.mojom.h" |
(...skipping 13 matching lines...) Expand all Loading... |
24 mojom::WindowTreeClient* client); | 24 mojom::WindowTreeClient* client); |
25 virtual ~ClientConnection(); | 25 virtual ~ClientConnection(); |
26 | 26 |
27 WindowTreeImpl* service() { return service_.get(); } | 27 WindowTreeImpl* service() { return service_.get(); } |
28 const WindowTreeImpl* service() const { return service_.get(); } | 28 const WindowTreeImpl* service() const { return service_.get(); } |
29 | 29 |
30 mojom::WindowTreeClient* client() { return client_; } | 30 mojom::WindowTreeClient* client() { return client_; } |
31 | 31 |
32 virtual mojom::WindowManagerInternal* GetWindowManagerInternal() = 0; | 32 virtual mojom::WindowManagerInternal* GetWindowManagerInternal() = 0; |
33 | 33 |
| 34 virtual void SetIncomingMethodCallProcessingPaused(bool paused) = 0; |
| 35 |
34 private: | 36 private: |
35 scoped_ptr<WindowTreeImpl> service_; | 37 scoped_ptr<WindowTreeImpl> service_; |
36 mojom::WindowTreeClient* client_; | 38 mojom::WindowTreeClient* client_; |
37 | 39 |
38 DISALLOW_COPY_AND_ASSIGN(ClientConnection); | 40 DISALLOW_COPY_AND_ASSIGN(ClientConnection); |
39 }; | 41 }; |
40 | 42 |
41 // Bindings implementation of ClientConnection. | 43 // Bindings implementation of ClientConnection. |
42 class DefaultClientConnection : public ClientConnection { | 44 class DefaultClientConnection : public ClientConnection { |
43 public: | 45 public: |
44 DefaultClientConnection( | 46 DefaultClientConnection( |
45 scoped_ptr<WindowTreeImpl> service_impl, | 47 scoped_ptr<WindowTreeImpl> service_impl, |
46 ConnectionManager* connection_manager, | 48 ConnectionManager* connection_manager, |
47 mojo::InterfaceRequest<mojom::WindowTree> service_request, | 49 mojo::InterfaceRequest<mojom::WindowTree> service_request, |
48 mojom::WindowTreeClientPtr client); | 50 mojom::WindowTreeClientPtr client); |
49 ~DefaultClientConnection() override; | 51 ~DefaultClientConnection() override; |
50 | 52 |
51 // ClientConnection: | 53 // ClientConnection: |
52 mojom::WindowManagerInternal* GetWindowManagerInternal() override; | 54 mojom::WindowManagerInternal* GetWindowManagerInternal() override; |
| 55 void SetIncomingMethodCallProcessingPaused(bool paused) override; |
53 | 56 |
54 private: | 57 private: |
55 ConnectionManager* connection_manager_; | 58 ConnectionManager* connection_manager_; |
56 mojo::Binding<mojom::WindowTree> binding_; | 59 mojo::Binding<mojom::WindowTree> binding_; |
57 mojom::WindowTreeClientPtr client_; | 60 mojom::WindowTreeClientPtr client_; |
58 mojom::WindowManagerInternalAssociatedPtr window_manager_internal_; | 61 mojom::WindowManagerInternalAssociatedPtr window_manager_internal_; |
59 | 62 |
60 DISALLOW_COPY_AND_ASSIGN(DefaultClientConnection); | 63 DISALLOW_COPY_AND_ASSIGN(DefaultClientConnection); |
61 }; | 64 }; |
62 | 65 |
63 } // namespace ws | 66 } // namespace ws |
64 } // namespace mus | 67 } // namespace mus |
65 | 68 |
66 #endif // COMPONENTS_MUS_WS_CLIENT_CONNECTION_H_ | 69 #endif // COMPONENTS_MUS_WS_CLIENT_CONNECTION_H_ |
OLD | NEW |