| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef UI_AURA_CLIENT_STACKING_CLIENT_H_ | 5 #ifndef UI_AURA_CLIENT_STACKING_CLIENT_H_ |
| 6 #define UI_AURA_CLIENT_STACKING_CLIENT_H_ | 6 #define UI_AURA_CLIENT_STACKING_CLIENT_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "ui/aura/aura_export.h" | 9 #include "ui/aura/aura_export.h" |
| 10 | 10 |
| 11 namespace aura { | 11 namespace aura { |
| 12 class Window; | 12 class Window; |
| 13 namespace client { | 13 namespace client { |
| 14 | 14 |
| 15 // A property key to store a client that handles window parenting. The type of |
| 16 // the value is |aura::client::StackingClient*|. |
| 17 AURA_EXPORT extern const char kRootWindowStackingClient[]; |
| 18 |
| 15 // An interface implemented by an object that stacks windows. | 19 // An interface implemented by an object that stacks windows. |
| 16 class AURA_EXPORT StackingClient { | 20 class AURA_EXPORT StackingClient { |
| 17 public: | 21 public: |
| 18 virtual ~StackingClient() {} | 22 virtual ~StackingClient() {} |
| 19 | 23 |
| 20 // Called by the Window when its parent is set to NULL, returns the window | 24 // Called by the Window when its parent is set to NULL, returns the window |
| 21 // that |window| should be added to instead. | 25 // that |window| should be added to instead. |
| 22 virtual Window* GetDefaultParent(Window* window) = 0; | 26 virtual Window* GetDefaultParent(Window* window) = 0; |
| 23 }; | 27 }; |
| 24 | 28 |
| 25 AURA_EXPORT void SetStackingClient(StackingClient* stacking_client); | 29 AURA_EXPORT void SetStackingClient(StackingClient* stacking_client); |
| 26 AURA_EXPORT StackingClient* GetStackingClient(); | 30 AURA_EXPORT StackingClient* GetStackingClient(); |
| 27 | 31 |
| 28 } // namespace client | 32 } // namespace client |
| 29 } // namespace aura | 33 } // namespace aura |
| 30 | 34 |
| 31 #endif // UI_AURA_CLIENT_STACKING_CLIENT_H_ | 35 #endif // UI_AURA_CLIENT_STACKING_CLIENT_H_ |
| OLD | NEW |