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_WINDOW_TREE_IMPL_H_ | 5 #ifndef COMPONENTS_MUS_WS_WINDOW_TREE_IMPL_H_ |
6 #define COMPONENTS_MUS_WS_WINDOW_TREE_IMPL_H_ | 6 #define COMPONENTS_MUS_WS_WINDOW_TREE_IMPL_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
104 void OnWillDestroyWindowTreeHost(WindowTreeHostImpl* tree_host); | 104 void OnWillDestroyWindowTreeHost(WindowTreeHostImpl* tree_host); |
105 | 105 |
106 // These functions are synchronous variants of those defined in the mojom. The | 106 // These functions are synchronous variants of those defined in the mojom. The |
107 // WindowTree implementations all call into these. See the mojom for details. | 107 // WindowTree implementations all call into these. See the mojom for details. |
108 bool NewWindow(const ClientWindowId& client_window_id, | 108 bool NewWindow(const ClientWindowId& client_window_id, |
109 const std::map<std::string, std::vector<uint8_t>>& properties); | 109 const std::map<std::string, std::vector<uint8_t>>& properties); |
110 bool AddWindow(const ClientWindowId& parent_id, | 110 bool AddWindow(const ClientWindowId& parent_id, |
111 const ClientWindowId& child_id); | 111 const ClientWindowId& child_id); |
112 bool AddTransientWindow(const ClientWindowId& window_id, | 112 bool AddTransientWindow(const ClientWindowId& window_id, |
113 const ClientWindowId& transient_window_id); | 113 const ClientWindowId& transient_window_id); |
| 114 bool SetAsModal(const ClientWindowId& window_id); |
114 std::vector<const ServerWindow*> GetWindowTree( | 115 std::vector<const ServerWindow*> GetWindowTree( |
115 const ClientWindowId& window_id) const; | 116 const ClientWindowId& window_id) const; |
116 bool SetWindowVisibility(const ClientWindowId& window_id, bool visible); | 117 bool SetWindowVisibility(const ClientWindowId& window_id, bool visible); |
117 bool Embed(const ClientWindowId& window_id, | 118 bool Embed(const ClientWindowId& window_id, |
118 mojom::WindowTreeClientPtr client, | 119 mojom::WindowTreeClientPtr client, |
119 uint32_t policy_bitmask, | 120 uint32_t policy_bitmask, |
120 ConnectionSpecificId* connection_id); | 121 ConnectionSpecificId* connection_id); |
121 void DispatchInputEvent(ServerWindow* target, mojom::EventPtr event); | 122 void DispatchInputEvent(ServerWindow* target, mojom::EventPtr event); |
122 | 123 |
123 bool IsWaitingForNewTopLevelWindow(uint32_t wm_change_id); | 124 bool IsWaitingForNewTopLevelWindow(uint32_t wm_change_id); |
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
283 mojo::Map<mojo::String, mojo::Array<uint8_t>> | 284 mojo::Map<mojo::String, mojo::Array<uint8_t>> |
284 transport_properties) override; | 285 transport_properties) override; |
285 void DeleteWindow(uint32_t change_id, Id transport_window_id) override; | 286 void DeleteWindow(uint32_t change_id, Id transport_window_id) override; |
286 void AddWindow(uint32_t change_id, Id parent_id, Id child_id) override; | 287 void AddWindow(uint32_t change_id, Id parent_id, Id child_id) override; |
287 void RemoveWindowFromParent(uint32_t change_id, Id window_id) override; | 288 void RemoveWindowFromParent(uint32_t change_id, Id window_id) override; |
288 void AddTransientWindow(uint32_t change_id, | 289 void AddTransientWindow(uint32_t change_id, |
289 Id window, | 290 Id window, |
290 Id transient_window) override; | 291 Id transient_window) override; |
291 void RemoveTransientWindowFromParent(uint32_t change_id, | 292 void RemoveTransientWindowFromParent(uint32_t change_id, |
292 Id transient_window_id) override; | 293 Id transient_window_id) override; |
| 294 void SetAsModal(uint32_t change_id, Id window_id) override; |
293 void ReorderWindow(uint32_t change_Id, | 295 void ReorderWindow(uint32_t change_Id, |
294 Id window_id, | 296 Id window_id, |
295 Id relative_window_id, | 297 Id relative_window_id, |
296 mojom::OrderDirection direction) override; | 298 mojom::OrderDirection direction) override; |
297 void GetWindowTree( | 299 void GetWindowTree( |
298 Id window_id, | 300 Id window_id, |
299 const mojo::Callback<void(mojo::Array<mojom::WindowDataPtr>)>& callback) | 301 const mojo::Callback<void(mojo::Array<mojom::WindowDataPtr>)>& callback) |
300 override; | 302 override; |
301 void SetCapture(uint32_t change_id, Id window_id) override; | 303 void SetCapture(uint32_t change_id, Id window_id) override; |
302 void ReleaseCapture(uint32_t change_id, Id window_id) override; | 304 void ReleaseCapture(uint32_t change_id, Id window_id) override; |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
403 | 405 |
404 scoped_ptr<WaitingForTopLevelWindowInfo> waiting_for_top_level_window_info_; | 406 scoped_ptr<WaitingForTopLevelWindowInfo> waiting_for_top_level_window_info_; |
405 | 407 |
406 DISALLOW_COPY_AND_ASSIGN(WindowTreeImpl); | 408 DISALLOW_COPY_AND_ASSIGN(WindowTreeImpl); |
407 }; | 409 }; |
408 | 410 |
409 } // namespace ws | 411 } // namespace ws |
410 } // namespace mus | 412 } // namespace mus |
411 | 413 |
412 #endif // COMPONENTS_MUS_WS_WINDOW_TREE_IMPL_H_ | 414 #endif // COMPONENTS_MUS_WS_WINDOW_TREE_IMPL_H_ |
OLD | NEW |