OLD | NEW |
| (Empty) |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_STACKING_CLIENT_H_ | |
6 #define UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_STACKING_CLIENT_H_ | |
7 | |
8 #include "ui/aura/client/stacking_client.h" | |
9 | |
10 #include "base/basictypes.h" | |
11 #include "base/compiler_specific.h" | |
12 #include "base/memory/scoped_ptr.h" | |
13 #include "ui/views/views_export.h" | |
14 | |
15 namespace aura { | |
16 class RootWindow; | |
17 class Window; | |
18 namespace client { | |
19 class DefaultCaptureClient; | |
20 class FocusClient; | |
21 } | |
22 } | |
23 | |
24 namespace views { | |
25 class DesktopActivationClient; | |
26 namespace corewm { | |
27 class CompoundEventFilter; | |
28 class InputMethodEventFilter; | |
29 } | |
30 | |
31 // A stacking client for the desktop; always sets the default parent to the | |
32 // RootWindow of the passed in Window. | |
33 class VIEWS_EXPORT DesktopStackingClient : public aura::client::StackingClient { | |
34 public: | |
35 DesktopStackingClient(); | |
36 virtual ~DesktopStackingClient(); | |
37 | |
38 // Overridden from aura::client::StackingClient: | |
39 virtual aura::Window* GetDefaultParent(aura::Window* context, | |
40 aura::Window* window, | |
41 const gfx::Rect& bounds) OVERRIDE; | |
42 | |
43 private: | |
44 void CreateNULLParent(); | |
45 | |
46 // Windows with NULL parents are parented to this. | |
47 scoped_ptr<aura::RootWindow> null_parent_; | |
48 | |
49 // All the member variables below are necessary for the NULL parent root | |
50 // window to function. | |
51 scoped_ptr<aura::client::FocusClient> focus_client_; | |
52 // Depends on focus_manager_. | |
53 scoped_ptr<DesktopActivationClient> activation_client_; | |
54 | |
55 scoped_ptr<corewm::InputMethodEventFilter> input_method_filter_; | |
56 corewm::CompoundEventFilter* window_event_filter_; | |
57 | |
58 scoped_ptr<aura::client::DefaultCaptureClient> capture_client_; | |
59 | |
60 DISALLOW_COPY_AND_ASSIGN(DesktopStackingClient); | |
61 }; | |
62 | |
63 } // namespace views | |
64 | |
65 #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_STACKING_CLIENT_H_ | |
OLD | NEW |