| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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_OZONE_PLATFORM_WAYLAND_WAYLAND_DISPLAY_H_ | 5 #ifndef UI_OZONE_PLATFORM_WAYLAND_WAYLAND_DISPLAY_H_ |
| 6 #define UI_OZONE_PLATFORM_WAYLAND_WAYLAND_DISPLAY_H_ | 6 #define UI_OZONE_PLATFORM_WAYLAND_WAYLAND_DISPLAY_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 | 9 |
| 10 #include "base/message_loop/message_pump_libevent.h" | 10 #include "base/message_loop/message_pump_libevent.h" |
| 11 #include "ui/events/platform/platform_event_source.h" | 11 #include "ui/events/platform/platform_event_source.h" |
| 12 #include "ui/gfx/native_widget_types.h" | 12 #include "ui/gfx/native_widget_types.h" |
| 13 #include "ui/ozone/ozone_export.h" | |
| 14 #include "ui/ozone/platform/wayland/wayland_object.h" | 13 #include "ui/ozone/platform/wayland/wayland_object.h" |
| 15 | 14 |
| 16 namespace ui { | 15 namespace ui { |
| 17 | 16 |
| 18 class WaylandWindow; | 17 class WaylandWindow; |
| 19 | 18 |
| 20 class OZONE_EXPORT WaylandDisplay : public PlatformEventSource, | 19 class WaylandDisplay : public PlatformEventSource, |
| 21 public base::MessagePumpLibevent::Watcher { | 20 public base::MessagePumpLibevent::Watcher { |
| 22 public: | 21 public: |
| 23 WaylandDisplay(); | 22 WaylandDisplay(); |
| 24 ~WaylandDisplay() override; | 23 ~WaylandDisplay() override; |
| 25 | 24 |
| 26 bool Initialize(); | 25 bool Initialize(); |
| 27 | 26 |
| 28 // Flushes the Wayland connection. | 27 // Flushes the Wayland connection. |
| 29 void Flush(); | 28 void Flush(); |
| 30 | 29 |
| 31 wl_display* display() { return display_.get(); } | 30 wl_display* display() { return display_.get(); } |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 | 65 |
| 67 bool watching_ = false; | 66 bool watching_ = false; |
| 68 base::MessagePumpLibevent::FileDescriptorWatcher controller_; | 67 base::MessagePumpLibevent::FileDescriptorWatcher controller_; |
| 69 | 68 |
| 70 DISALLOW_COPY_AND_ASSIGN(WaylandDisplay); | 69 DISALLOW_COPY_AND_ASSIGN(WaylandDisplay); |
| 71 }; | 70 }; |
| 72 | 71 |
| 73 } // namespace ui | 72 } // namespace ui |
| 74 | 73 |
| 75 #endif // UI_OZONE_PLATFORM_WAYLAND_WAYLAND_DISPLAY_H_ | 74 #endif // UI_OZONE_PLATFORM_WAYLAND_WAYLAND_DISPLAY_H_ |
| OLD | NEW |