diff options
author | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-12-12 22:33:07 +0000 |
---|---|---|
committer | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-12-12 22:33:07 +0000 |
commit | a9ea2b5334e49a3f36b2bb2581b90f301747dc77 (patch) | |
tree | 22d64d958abf32ddc75b66224da7c02c6168ce7e /ui/aura_shell/workspace_controller.h | |
parent | 2bfa54889d0c31859bf932759ce93652297ab3ec (diff) | |
download | chromium_src-a9ea2b5334e49a3f36b2bb2581b90f301747dc77.zip chromium_src-a9ea2b5334e49a3f36b2bb2581b90f301747dc77.tar.gz chromium_src-a9ea2b5334e49a3f36b2bb2581b90f301747dc77.tar.bz2 |
Revert 114095 - Move the concept of Activation to the Shell.
The Active Window is now stored in a property on the RootWindow. Classes wishing to observe changes to this can implement WindowObserver and attach to the RootWindow to be notified of changes in this property.
We provide an ActivationClient interface in Aura for customers to use to set/get the active window, and deactivate a window. This is because setting the active window involves more than just changing the property, there is some additional book-keeping that must be done. The ActivationClient is stored in a property on the RootWindow.
We also provide an ActivationDelegate interface in Aura that window owners can use to be notified of changes in activation state, and to specify whether or not a window can be activated. The ActivationDelegate should be stored on the relevant window in a property.
I moved a lot of Activation-related functionality out of Aura, including all of the unit tests, now on ActivationController, and the associated WindowDelegate implementations which have now become a single TestActivationDelegate implementation.
BUG=none
TEST=unit tests
Review URL: http://codereview.chromium.org/8894018
TBR=ben@chromium.org
Review URL: http://codereview.chromium.org/8926004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@114101 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/aura_shell/workspace_controller.h')
-rw-r--r-- | ui/aura_shell/workspace_controller.h | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/ui/aura_shell/workspace_controller.h b/ui/aura_shell/workspace_controller.h index fd9e311..e41899e 100644 --- a/ui/aura_shell/workspace_controller.h +++ b/ui/aura_shell/workspace_controller.h @@ -9,7 +9,6 @@ #include "base/basictypes.h" #include "base/memory/scoped_ptr.h" #include "ui/aura/root_window_observer.h" -#include "ui/aura/window_observer.h" #include "ui/aura_shell/aura_shell_export.h" #include "ui/aura_shell/launcher/launcher_model_observer.h" #include "ui/aura_shell/workspace/workspace_observer.h" @@ -34,7 +33,6 @@ class WorkspaceManager; // a move event between Laucher and Workspace. class AURA_SHELL_EXPORT WorkspaceController : public aura::RootWindowObserver, - public aura::WindowObserver, public aura_shell::internal::WorkspaceObserver, public aura_shell::LauncherModelObserver { public: @@ -50,13 +48,9 @@ class AURA_SHELL_EXPORT WorkspaceController : return workspace_manager_.get(); } - // aura::RootWindowObserver overrides: + // RootWindowObserver overrides: virtual void OnRootWindowResized(const gfx::Size& new_size) OVERRIDE; - - // aura::WindowObserver overrides: - virtual void OnWindowPropertyChanged(aura::Window* window, - const char* key, - void* old) OVERRIDE; + virtual void OnActiveWindowChanged(aura::Window* active) OVERRIDE; // WorkspaceObserver overrides: virtual void WindowMoved(WorkspaceManager* manager, |