OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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_ROOT_WINDOW_HOST_X11_H_ | 5 #ifndef UI_AURA_ROOT_WINDOW_HOST_X11_H_ |
6 #define UI_AURA_ROOT_WINDOW_HOST_X11_H_ | 6 #define UI_AURA_ROOT_WINDOW_HOST_X11_H_ |
7 | 7 |
8 #include <X11/Xlib.h> | 8 #include <X11/Xlib.h> |
9 | 9 |
10 #include <vector> | 10 #include <vector> |
11 | 11 |
12 // Get rid of a macro from Xlib.h that conflicts with Aura's RootWindow class. | 12 // Get rid of a macro from Xlib.h that conflicts with Aura's RootWindow class. |
13 #undef RootWindow | 13 #undef RootWindow |
14 | 14 |
15 #include "base/memory/scoped_ptr.h" | 15 #include "base/memory/scoped_ptr.h" |
16 #include "base/message_loop/message_loop.h" | 16 #include "base/message_loop/message_pump_dispatcher.h" |
17 #include "ui/aura/aura_export.h" | 17 #include "ui/aura/aura_export.h" |
18 #include "ui/aura/env_observer.h" | 18 #include "ui/aura/env_observer.h" |
19 #include "ui/aura/window_tree_host.h" | 19 #include "ui/aura/window_tree_host.h" |
20 #include "ui/base/x/x11_util.h" | 20 #include "ui/base/x/x11_util.h" |
21 #include "ui/events/event_source.h" | 21 #include "ui/events/event_source.h" |
22 #include "ui/gfx/insets.h" | 22 #include "ui/gfx/insets.h" |
23 #include "ui/gfx/rect.h" | 23 #include "ui/gfx/rect.h" |
24 #include "ui/gfx/x/x11_atom_cache.h" | 24 #include "ui/gfx/x/x11_atom_cache.h" |
25 | 25 |
26 namespace ui { | 26 namespace ui { |
27 class MouseEvent; | 27 class MouseEvent; |
28 } | 28 } |
29 | 29 |
30 namespace aura { | 30 namespace aura { |
31 | 31 |
32 namespace internal { | 32 namespace internal { |
33 class TouchEventCalibrate; | 33 class TouchEventCalibrate; |
34 } | 34 } |
35 | 35 |
36 class AURA_EXPORT WindowTreeHostX11 : public WindowTreeHost, | 36 class AURA_EXPORT WindowTreeHostX11 : public WindowTreeHost, |
37 public base::MessageLoop::Dispatcher, | 37 public base::MessagePumpDispatcher, |
38 public ui::EventSource, | 38 public ui::EventSource, |
39 public EnvObserver { | 39 public EnvObserver { |
40 public: | 40 public: |
41 explicit WindowTreeHostX11(const gfx::Rect& bounds); | 41 explicit WindowTreeHostX11(const gfx::Rect& bounds); |
42 virtual ~WindowTreeHostX11(); | 42 virtual ~WindowTreeHostX11(); |
43 | 43 |
44 // Overridden from Dispatcher overrides: | 44 // Overridden from Dispatcher overrides: |
45 virtual bool Dispatch(const base::NativeEvent& event) OVERRIDE; | 45 virtual bool Dispatch(const base::NativeEvent& event) OVERRIDE; |
46 | 46 |
47 // WindowTreeHost Overrides. | 47 // WindowTreeHost Overrides. |
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
143 namespace test { | 143 namespace test { |
144 | 144 |
145 // Set the default value of the override redirect flag used to | 145 // Set the default value of the override redirect flag used to |
146 // create a X window for WindowTreeHostX11. | 146 // create a X window for WindowTreeHostX11. |
147 AURA_EXPORT void SetUseOverrideRedirectWindowByDefault(bool override_redirect); | 147 AURA_EXPORT void SetUseOverrideRedirectWindowByDefault(bool override_redirect); |
148 | 148 |
149 } // namespace test | 149 } // namespace test |
150 } // namespace aura | 150 } // namespace aura |
151 | 151 |
152 #endif // UI_AURA_ROOT_WINDOW_HOST_X11_H_ | 152 #endif // UI_AURA_ROOT_WINDOW_HOST_X11_H_ |
OLD | NEW |