Chromium Code Reviews| Index: mojo/examples/wm_flow/wm/frame_controller.h |
| diff --git a/mojo/examples/wm_flow/wm/frame_controller.h b/mojo/examples/wm_flow/wm/frame_controller.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..b321836189d04606839ce3e0d4212686cdd7331a |
| --- /dev/null |
| +++ b/mojo/examples/wm_flow/wm/frame_controller.h |
| @@ -0,0 +1,46 @@ |
| +// Copyright 2014 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef MOJO_EXAMPLES_WM_FLOW_WM_FRAME_CONTROLLER_H_ |
| +#define MOJO_EXAMPLES_WM_FLOW_WM_FRAME_CONTROLLER_H_ |
| + |
| +#include "ui/gfx/geometry/rect.h" |
| + |
| +namespace mojo { |
| +class NativeWidgetViewManager; |
| +class View; |
| +} |
| + |
| +namespace views { |
| +class View; |
| +class Widget; |
| +} |
| + |
| +// FrameController encapsulates the window manager's frame additions to a window |
| +// created by an application. It renders the content of the frame and responds |
| +// to any events targeted at it. |
| +class FrameController { |
| + public: |
| + FrameController(mojo::View* view, mojo::View** app_view); |
| + virtual ~FrameController(); |
|
sky
2014/09/11 19:32:22
You never delete instances of this.
|
| + |
| + void CloseWindow(); |
| + void ToggleMaximize(); |
| + |
| + private: |
| + class LayoutManager; |
| + friend class LayoutManager; |
| + |
| + mojo::View* view_; |
| + mojo::View* app_view_; |
| + views::View* frame_view_; |
| + LayoutManager* frame_view_layout_manager_; |
| + views::Widget* widget_; |
| + bool maximized_; |
| + gfx::Rect restored_bounds_; |
| + |
| + DISALLOW_COPY_AND_ASSIGN(FrameController); |
| +}; |
| + |
| +#endif // MOJO_EXAMPLES_WM_FLOW_WM_FRAME_CONTROLLER_H_ |