Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(163)

Unified Diff: ui/aura_shell/toplevel_frame_view.h

Issue 9035001: Move some more WM functionality down into ash. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/aura_shell/test/test_activation_delegate.cc ('k') | ui/aura_shell/toplevel_frame_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/aura_shell/toplevel_frame_view.h
===================================================================
--- ui/aura_shell/toplevel_frame_view.h (revision 115655)
+++ ui/aura_shell/toplevel_frame_view.h (working copy)
@@ -1,85 +0,0 @@
-// Copyright (c) 2011 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 UI_AURA_SHELL_TOPLEVEL_FRAME_VIEW_H_
-#define UI_AURA_SHELL_TOPLEVEL_FRAME_VIEW_H_
-#pragma once
-
-#include "ui/aura_shell/aura_shell_export.h"
-#include "ui/views/controls/button/button.h"
-#include "ui/views/window/non_client_view.h"
-
-namespace aura_shell {
-namespace internal {
-
-class FrameComponent;
-class SizingBorder;
-class WindowCaption;
-
-// A NonClientFrameView implementation for generic top-level windows in Aura.
-// TODO(beng): Find a way to automatically this for all top-level windows in
-// Aura. Right now windows have to override CreateNonClientFrameView
-// on WidgetDelegate to specify this.
-class AURA_SHELL_EXPORT ToplevelFrameView : public views::NonClientFrameView {
- public:
- ToplevelFrameView();
- virtual ~ToplevelFrameView();
-
- private:
- // Returns the height of the side/bottom non-client edges.
- int NonClientBorderThickness() const;
-
- // Returns the height of the top non-client edge - the caption.
- int NonClientTopBorderHeight() const;
-
- // Implementation of NonClientHitTest().
- int NonClientHitTestImpl(const gfx::Point& point);
-
- // Shows the specified |sizing_border|, hiding all others.
- // If |sizing_border| is NULL, all other sizing borders are hidden.
- void ShowFrameComponent(FrameComponent* sizing_border);
-
- // Returns true if the specified point (in FrameView coordinates) hit-tests
- // against the specified child.
- bool PointIsInChildView(views::View* child, const gfx::Point& point) const;
-
- // Returns the bounds of the specified sizing border for its visible and
- // hidden states.
- gfx::Rect GetHiddenBoundsForSizingBorder(int frame_component) const;
- gfx::Rect GetVisibleBoundsForSizingBorder(int frame_component) const;
-
- // Overridden from views::NonClientFrameView:
- virtual gfx::Rect GetBoundsForClientView() const OVERRIDE;
- virtual gfx::Rect GetWindowBoundsForClientBounds(
- const gfx::Rect& client_bounds) const OVERRIDE;
- virtual int NonClientHitTest(const gfx::Point& point) OVERRIDE;
- virtual void GetWindowMask(const gfx::Size& size,
- gfx::Path* window_mask) OVERRIDE;
- virtual void ResetWindowControls() OVERRIDE;
- virtual void UpdateWindowIcon() OVERRIDE;
-
- // Overridden from views::View:
- virtual void Layout() OVERRIDE;
- virtual void OnMouseMoved(const views::MouseEvent& event) OVERRIDE;
- virtual void OnMouseExited(const views::MouseEvent& event) OVERRIDE;
- virtual views::View* GetEventHandlerForPoint(
- const gfx::Point& point) OVERRIDE;
- virtual gfx::NativeCursor GetCursor(const views::MouseEvent& event) OVERRIDE;
-
- gfx::Rect client_view_bounds_;
-
- int current_hittest_code_;
-
- WindowCaption* caption_;
- SizingBorder* left_edge_;
- SizingBorder* right_edge_;
- SizingBorder* bottom_edge_;
-
- DISALLOW_COPY_AND_ASSIGN(ToplevelFrameView);
-};
-
-} // namespace internal
-} // namespace aura_shell
-
-#endif // #ifndef UI_AURA_SHELL_TOPLEVEL_FRAME_VIEW_H_
« no previous file with comments | « ui/aura_shell/test/test_activation_delegate.cc ('k') | ui/aura_shell/toplevel_frame_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698