summaryrefslogtreecommitdiffstats
path: root/ui/aura/test/test_stacking_client.h
diff options
context:
space:
mode:
authorben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-11-09 22:48:57 +0000
committerben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-11-09 22:48:57 +0000
commit9823481646ee68ca96b77099ba3ebc12ade27f58 (patch)
tree909b6ea3b680656d27b19d049d9a816911100106 /ui/aura/test/test_stacking_client.h
parent82987d6363d1a724b12575a9167752ad3baa3e27 (diff)
downloadchromium_src-9823481646ee68ca96b77099ba3ebc12ade27f58.zip
chromium_src-9823481646ee68ca96b77099ba3ebc12ade27f58.tar.gz
chromium_src-9823481646ee68ca96b77099ba3ebc12ade27f58.tar.bz2
Create a new aura client API dir and move constants and desktop delegate to it.
Rename DesktopDelegate to StackingClient. BUG=none TEST=none Review URL: http://codereview.chromium.org/8508020 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@109323 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/aura/test/test_stacking_client.h')
-rw-r--r--ui/aura/test/test_stacking_client.h43
1 files changed, 43 insertions, 0 deletions
diff --git a/ui/aura/test/test_stacking_client.h b/ui/aura/test/test_stacking_client.h
new file mode 100644
index 0000000..bf77ff8
--- /dev/null
+++ b/ui/aura/test/test_stacking_client.h
@@ -0,0 +1,43 @@
+// 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_TEST_TEST_STACKING_CLIENT_H_
+#define UI_AURA_TEST_TEST_STACKING_CLIENT_H_
+#pragma once
+
+#include "base/basictypes.h"
+#include "base/compiler_specific.h"
+#include "base/memory/scoped_ptr.h"
+#include "ui/aura/client/stacking_client.h"
+#include "ui/aura/toplevel_window_container.h"
+
+namespace aura {
+class ToplevelWindowContainer;
+
+namespace test {
+
+class TestStackingClient : public StackingClient {
+ public:
+ // Callers should allocate a TestStackingClient on the heap and then forget
+ // about it -- the c'tor passes ownership of the TestStackingClient to the
+ // static Desktop object.
+ TestStackingClient();
+ virtual ~TestStackingClient();
+
+ Window* default_container() { return default_container_.get(); }
+
+ private:
+ // Overridden from StackingClient:
+ virtual void AddChildToDefaultParent(Window* window) OVERRIDE;
+ virtual Window* GetTopmostWindowToActivate(Window* ignore) const OVERRIDE;
+
+ scoped_ptr<ToplevelWindowContainer> default_container_;
+
+ DISALLOW_COPY_AND_ASSIGN(TestStackingClient);
+};
+
+} // namespace test
+} // namespace aura
+
+#endif // UI_AURA_TEST_TEST_STACKING_CLIENT_H_