summaryrefslogtreecommitdiffstats
path: root/ash/wm/panel_layout_manager.h
diff options
context:
space:
mode:
authortbreisacher@chromium.org <tbreisacher@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-02-04 03:57:50 +0000
committertbreisacher@chromium.org <tbreisacher@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-02-04 03:57:50 +0000
commit6de3a01154a0ffbe273da08ce6c67164d71b18d7 (patch)
tree88d226f502c045295e98df3137d92e3e07ed931f /ash/wm/panel_layout_manager.h
parenteb8abacb3842302263f3d3bd6f875d25273eb991 (diff)
downloadchromium_src-6de3a01154a0ffbe273da08ce6c67164d71b18d7.zip
chromium_src-6de3a01154a0ffbe273da08ce6c67164d71b18d7.tar.gz
chromium_src-6de3a01154a0ffbe273da08ce6c67164d71b18d7.tar.bz2
Revert 120460 - Add PanelWindow and PanelLayoutManager to ash.
This implements a sample implementation of a WidgetDelegateView (PanelWindow) and a LayoutManager to provide an initial outline for developing panels. ash_shell must be run with --aura-panels to get the new behavior, since Chrome currently relies on existing behavior for widgets of TYPE_PANEL. BUG=98330 TEST=Run ash_shell --aura-panels to see a simple panel test implementation. Ensure panels work as expected in Chrome. Review URL: http://codereview.chromium.org/9104027 TBR=stevenjb@chromium.org Review URL: https://chromiumcodereview.appspot.com/9328026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@120465 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ash/wm/panel_layout_manager.h')
-rw-r--r--ash/wm/panel_layout_manager.h69
1 files changed, 0 insertions, 69 deletions
diff --git a/ash/wm/panel_layout_manager.h b/ash/wm/panel_layout_manager.h
deleted file mode 100644
index a4921d7..0000000
--- a/ash/wm/panel_layout_manager.h
+++ /dev/null
@@ -1,69 +0,0 @@
-// Copyright (c) 2012 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 ASH_WM_PANEL_LAYOUT_MANAGER_H_
-#define ASH_WM_PANEL_LAYOUT_MANAGER_H_
-#pragma once
-
-#include <list>
-
-#include "ash/ash_export.h"
-#include "base/basictypes.h"
-#include "base/compiler_specific.h"
-#include "ui/aura/layout_manager.h"
-
-namespace aura {
-class Window;
-}
-
-namespace gfx {
-class Rect;
-}
-
-namespace ash {
-namespace internal {
-
-// PanelLayoutManager is responsible for organizing panels within the
-// workspace. It is associated with a specific container window (i.e.
-// kShellWindowId_PanelContainer) and controls the layout of any windows
-// added to that container.
-//
-// The constructor takes a |panel_container| argument which is expected to set
-// its layout manager to this instance, e.g.:
-// panel_container->SetLayoutManager(new PanelLayoutManager(panel_container));
-
-class ASH_EXPORT PanelLayoutManager : public aura::LayoutManager {
- public:
- explicit PanelLayoutManager(aura::Window* panel_container);
- virtual ~PanelLayoutManager();
-
- // Overridden from aura::LayoutManager:
- virtual void OnWindowResized() OVERRIDE;
- virtual void OnWindowAddedToLayout(aura::Window* child) OVERRIDE;
- virtual void OnWillRemoveWindowFromLayout(aura::Window* child) OVERRIDE;
- virtual void OnChildWindowVisibilityChanged(aura::Window* child,
- bool visibile) OVERRIDE;
- virtual void SetChildBounds(aura::Window* child,
- const gfx::Rect& requested_bounds) OVERRIDE;
-
- private:
- typedef std::list<aura::Window*> PanelList;
-
- // Called whenever the panel layout might change.
- void Relayout();
-
- // Parent window associated with this layout manager.
- aura::Window* panel_container_;
- // Protect against recursive calls to Relayout().
- bool in_layout_;
- // Ordered list of unowned pointers to panel windows.
- PanelList panel_windows_;
-
- DISALLOW_COPY_AND_ASSIGN(PanelLayoutManager);
-};
-
-} // namespace internal
-} // namespace ash
-
-#endif // ASH_WM_PANEL_LAYOUT_MANAGER_H_