| 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_WINDOW_TREE_HOST_X11_H_ | 5 #ifndef UI_AURA_WINDOW_TREE_HOST_X11_H_ |
| 6 #define UI_AURA_WINDOW_TREE_HOST_X11_H_ | 6 #define UI_AURA_WINDOW_TREE_HOST_X11_H_ |
| 7 | 7 |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "ui/aura/aura_export.h" | 9 #include "ui/aura/aura_export.h" |
| 10 #include "ui/aura/window_tree_host.h" | 10 #include "ui/aura/window_tree_host.h" |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 57 virtual void MoveCursorToNative(const gfx::Point& location) OVERRIDE; | 57 virtual void MoveCursorToNative(const gfx::Point& location) OVERRIDE; |
| 58 virtual void OnCursorVisibilityChangedNative(bool show) OVERRIDE; | 58 virtual void OnCursorVisibilityChangedNative(bool show) OVERRIDE; |
| 59 | 59 |
| 60 // ui::EventSource overrides. | 60 // ui::EventSource overrides. |
| 61 virtual ui::EventProcessor* GetEventProcessor() OVERRIDE; | 61 virtual ui::EventProcessor* GetEventProcessor() OVERRIDE; |
| 62 | 62 |
| 63 protected: | 63 protected: |
| 64 // Called when X Configure Notify event is recevied. | 64 // Called when X Configure Notify event is recevied. |
| 65 virtual void OnConfigureNotify(); | 65 virtual void OnConfigureNotify(); |
| 66 | 66 |
| 67 // Translates the native mouse location into screen coordinates and and | 67 // Translates the native mouse location into screen coordinates and |
| 68 // dispatches the event via WindowEventDispatcher. | 68 // dispatches the event via WindowEventDispatcher. |
| 69 virtual void TranslateAndDispatchLocatedEvent(ui::LocatedEvent* event); | 69 virtual void TranslateAndDispatchLocatedEvent(ui::LocatedEvent* event); |
| 70 | 70 |
| 71 ::Window x_root_window() { return x_root_window_; } | 71 ::Window x_root_window() { return x_root_window_; } |
| 72 XDisplay* xdisplay() { return xdisplay_; } | 72 XDisplay* xdisplay() { return xdisplay_; } |
| 73 const gfx::Rect bounds() const { return bounds_; } | 73 const gfx::Rect bounds() const { return bounds_; } |
| 74 ui::X11AtomCache* atom_cache() { return &atom_cache_; } | 74 ui::X11AtomCache* atom_cache() { return &atom_cache_; } |
| 75 | 75 |
| 76 private: | 76 private: |
| 77 // Dispatches XI2 events. Note that some events targetted for the X root | 77 // Dispatches XI2 events. Note that some events targetted for the X root |
| (...skipping 14 matching lines...) Expand all Loading... |
| 92 | 92 |
| 93 // Current Aura cursor. | 93 // Current Aura cursor. |
| 94 gfx::NativeCursor current_cursor_; | 94 gfx::NativeCursor current_cursor_; |
| 95 | 95 |
| 96 // Is the window mapped to the screen? | 96 // Is the window mapped to the screen? |
| 97 bool window_mapped_; | 97 bool window_mapped_; |
| 98 | 98 |
| 99 // The bounds of |xwindow_|. | 99 // The bounds of |xwindow_|. |
| 100 gfx::Rect bounds_; | 100 gfx::Rect bounds_; |
| 101 | 101 |
| 102 scoped_ptr<internal::TouchEventCalibrate> touch_calibrate_; |
| 103 |
| 102 ui::X11AtomCache atom_cache_; | 104 ui::X11AtomCache atom_cache_; |
| 103 | 105 |
| 104 DISALLOW_COPY_AND_ASSIGN(WindowTreeHostX11); | 106 DISALLOW_COPY_AND_ASSIGN(WindowTreeHostX11); |
| 105 }; | 107 }; |
| 106 | 108 |
| 107 namespace test { | 109 namespace test { |
| 108 | 110 |
| 109 // Set the default value of the override redirect flag used to | 111 // Set the default value of the override redirect flag used to |
| 110 // create a X window for WindowTreeHostX11. | 112 // create a X window for WindowTreeHostX11. |
| 111 AURA_EXPORT void SetUseOverrideRedirectWindowByDefault(bool override_redirect); | 113 AURA_EXPORT void SetUseOverrideRedirectWindowByDefault(bool override_redirect); |
| 112 | 114 |
| 113 } // namespace test | 115 } // namespace test |
| 114 } // namespace aura | 116 } // namespace aura |
| 115 | 117 |
| 116 #endif // UI_AURA_WINDOW_TREE_HOST_X11_H_ | 118 #endif // UI_AURA_WINDOW_TREE_HOST_X11_H_ |
| OLD | NEW |