| OLD | NEW |
| (Empty) |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef MASH_WM_WINDOW_LAYOUT_H_ | |
| 6 #define MASH_WM_WINDOW_LAYOUT_H_ | |
| 7 | |
| 8 #include <stdint.h> | |
| 9 | |
| 10 #include "base/macros.h" | |
| 11 #include "mash/wm/layout_manager.h" | |
| 12 | |
| 13 namespace mash { | |
| 14 namespace wm { | |
| 15 | |
| 16 // Responsible for layout of top level windows. | |
| 17 class WindowLayout : public LayoutManager { | |
| 18 public: | |
| 19 explicit WindowLayout(mus::Window* owner); | |
| 20 ~WindowLayout() override; | |
| 21 | |
| 22 private: | |
| 23 // Overridden from LayoutManager: | |
| 24 void LayoutWindow(mus::Window* window) override; | |
| 25 void OnWindowSharedPropertyChanged( | |
| 26 mus::Window* window, | |
| 27 const std::string& name, | |
| 28 const std::vector<uint8_t>* old_data, | |
| 29 const std::vector<uint8_t>* new_data) override; | |
| 30 | |
| 31 void FitToContainer(mus::Window* window); | |
| 32 void CenterWindow(mus::Window* window, const gfx::Size& preferred_size); | |
| 33 | |
| 34 DISALLOW_COPY_AND_ASSIGN(WindowLayout); | |
| 35 }; | |
| 36 | |
| 37 } // namespace wm | |
| 38 } // namespace mash | |
| 39 | |
| 40 #endif // MASH_WM_WINDOW_LAYOUT_H_ | |
| OLD | NEW |