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 #include "examples/wm_flow/wm/frame_controller.h" | 5 #include "examples/wm_flow/wm/frame_controller.h" |
6 | 6 |
7 #include "base/macros.h" | 7 #include "base/macros.h" |
8 #include "base/strings/utf_string_conversions.h" | 8 #include "base/strings/utf_string_conversions.h" |
9 #include "mojo/converters/geometry/geometry_type_converters.h" | 9 #include "mojo/converters/geometry/geometry_type_converters.h" |
10 #include "mojo/services/public/cpp/view_manager/view.h" | 10 #include "mojo/services/public/cpp/view_manager/view.h" |
11 #include "mojo/services/window_manager/window_manager_app.h" | |
12 #include "mojo/views/native_widget_view_manager.h" | 11 #include "mojo/views/native_widget_view_manager.h" |
| 12 #include "services/window_manager/window_manager_app.h" |
13 #include "ui/views/background.h" | 13 #include "ui/views/background.h" |
14 #include "ui/views/controls/button/label_button.h" | 14 #include "ui/views/controls/button/label_button.h" |
15 #include "ui/views/layout/layout_manager.h" | 15 #include "ui/views/layout/layout_manager.h" |
16 #include "ui/views/widget/widget.h" | 16 #include "ui/views/widget/widget.h" |
17 #include "ui/wm/public/activation_client.h" | 17 #include "ui/wm/public/activation_client.h" |
18 | 18 |
19 class FrameController::LayoutManager : public views::LayoutManager, | 19 class FrameController::LayoutManager : public views::LayoutManager, |
20 public views::ButtonListener { | 20 public views::ButtonListener { |
21 public: | 21 public: |
22 explicit LayoutManager(FrameController* controller) | 22 explicit LayoutManager(FrameController* controller) |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
148 window_manager_app_->focus_controller()->ActivateView(view_); | 148 window_manager_app_->focus_controller()->ActivateView(view_); |
149 } | 149 } |
150 | 150 |
151 //////////////////////////////////////////////////////////////////////////////// | 151 //////////////////////////////////////////////////////////////////////////////// |
152 // FrameController, mojo::ViewObserver implementation: | 152 // FrameController, mojo::ViewObserver implementation: |
153 | 153 |
154 void FrameController::OnViewDestroyed(mojo::View* view) { | 154 void FrameController::OnViewDestroyed(mojo::View* view) { |
155 view_->RemoveObserver(this); | 155 view_->RemoveObserver(this); |
156 delete this; | 156 delete this; |
157 } | 157 } |
OLD | NEW |