From 2937cac67e61e1ee4d01dd1e7ecb4562be79005b Mon Sep 17 00:00:00 2001 From: "scottmg@google.com" Date: Mon, 12 Nov 2012 21:45:03 +0000 Subject: Currently, the ash and desktop implementations of StackingClient stomp each other in aura::Env. Instead: - Don't have StackingClient implementations install themselves by default - Add chrome implementation of StackingClient that dispatches to ash or desktop - Pass extra |context| to GetDefaultParent (normally a RootWindow) that it can use to determine desktop type. - Workaround a few locations by using ScopedForceDesktopType: in these locations, the GetHostDesktopForNative... functions fail because they're used during window creation when the windows have no parent (and so can't determine which desktop they're in). - Remove window-specific StackingClient (unnecessary?) BUG=128578 Review URL: https://codereview.chromium.org/11364053 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@167245 0039d316-1c4b-4281-b951-d872f2087c98 --- ash/test/test_shell_delegate.cc | 5 +++++ ash/test/test_shell_delegate.h | 1 + 2 files changed, 6 insertions(+) (limited to 'ash/test') diff --git a/ash/test/test_shell_delegate.cc b/ash/test/test_shell_delegate.cc index 8575d6b..c165707 100644 --- a/ash/test/test_shell_delegate.cc +++ b/ash/test/test_shell_delegate.cc @@ -10,6 +10,7 @@ #include "ash/shell.h" #include "ash/shell_window_ids.h" #include "ash/test/test_launcher_delegate.h" +#include "ash/wm/stacking_controller.h" #include "ash/wm/window_util.h" #include "content/public/test/test_browser_context.h" #include "ui/aura/window.h" @@ -159,5 +160,9 @@ double TestShellDelegate::GetSavedScreenMagnifierScale() { return std::numeric_limits::min(); } +aura::client::StackingClient* TestShellDelegate::CreateStackingClient() { + return new StackingController; +} + } // namespace test } // namespace ash diff --git a/ash/test/test_shell_delegate.h b/ash/test/test_shell_delegate.h index 76b48b1..a1e9747 100644 --- a/ash/test/test_shell_delegate.h +++ b/ash/test/test_shell_delegate.h @@ -55,6 +55,7 @@ class TestShellDelegate : public ShellDelegate { virtual void SaveScreenMagnifierScale(double scale) OVERRIDE; virtual double GetSavedScreenMagnifierScale() OVERRIDE; virtual ui::MenuModel* CreateContextMenu(aura::RootWindow* root) OVERRIDE; + virtual aura::client::StackingClient* CreateStackingClient() OVERRIDE; int num_exit_requests() const { return num_exit_requests_; } private: -- cgit v1.1