OLD | NEW |
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 ASH_WM_AURA_AURA_LAYOUT_MANAGER_ADAPTER_H_ | 5 #ifndef ASH_AURA_AURA_LAYOUT_MANAGER_ADAPTER_H_ |
6 #define ASH_WM_AURA_AURA_LAYOUT_MANAGER_ADAPTER_H_ | 6 #define ASH_AURA_AURA_LAYOUT_MANAGER_ADAPTER_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 | 9 |
10 #include "ash/ash_export.h" | 10 #include "ash/ash_export.h" |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
12 #include "ui/aura/layout_manager.h" | 12 #include "ui/aura/layout_manager.h" |
13 | 13 |
14 namespace ash { | 14 namespace ash { |
15 namespace wm { | |
16 | 15 |
17 class WmLayoutManager; | 16 class WmLayoutManager; |
18 | 17 |
19 // AuraLayoutManagerAdapter is an aura::LayoutManager that calls to | 18 // AuraLayoutManagerAdapter is an aura::LayoutManager that calls to |
20 // WmLayoutManager. Use it when you have a WmLayoutManager you want to use | 19 // WmLayoutManager. Use it when you have a WmLayoutManager you want to use |
21 // with an aura::Window. | 20 // with an aura::Window. |
22 class ASH_EXPORT AuraLayoutManagerAdapter : public aura::LayoutManager { | 21 class ASH_EXPORT AuraLayoutManagerAdapter : public aura::LayoutManager { |
23 public: | 22 public: |
24 explicit AuraLayoutManagerAdapter( | 23 explicit AuraLayoutManagerAdapter( |
25 std::unique_ptr<WmLayoutManager> wm_layout_manager); | 24 std::unique_ptr<WmLayoutManager> wm_layout_manager); |
(...skipping 10 matching lines...) Expand all Loading... |
36 bool visible) override; | 35 bool visible) override; |
37 void SetChildBounds(aura::Window* child, | 36 void SetChildBounds(aura::Window* child, |
38 const gfx::Rect& requested_bounds) override; | 37 const gfx::Rect& requested_bounds) override; |
39 | 38 |
40 private: | 39 private: |
41 std::unique_ptr<WmLayoutManager> wm_layout_manager_; | 40 std::unique_ptr<WmLayoutManager> wm_layout_manager_; |
42 | 41 |
43 DISALLOW_COPY_AND_ASSIGN(AuraLayoutManagerAdapter); | 42 DISALLOW_COPY_AND_ASSIGN(AuraLayoutManagerAdapter); |
44 }; | 43 }; |
45 | 44 |
46 } // namespace wm | |
47 } // namespace ash | 45 } // namespace ash |
48 | 46 |
49 #endif // ASH_WM_AURA_AURA_LAYOUT_MANAGER_ADAPTER_H_ | 47 #endif // ASH_AURA_AURA_LAYOUT_MANAGER_ADAPTER_H_ |
OLD | NEW |