Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9)

Side by Side Diff: ui/events/platform/x11/x11_event_source_libevent.h

Issue 1602173005: Add PlatformWindow/Event related code for Ozone X11. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: XEventDispatcher added. Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef UI_EVENTS_PLATFORM_X11_X11_EVENT_SOURCE_LIBEVENT_H_
6 #define UI_EVENTS_PLATFORM_X11_X11_EVENT_SOURCE_LIBEVENT_H_
7
8 #include "base/macros.h"
9 #include "base/message_loop/message_loop.h"
10 #include "base/message_loop/message_pump_libevent.h"
11 #include "ui/events/events_export.h"
12 #include "ui/events/platform/x11/x11_event_source.h"
13
14 namespace ui {
15
16 class EVENTS_EXPORT X11EventSourceLibevent
17 : public X11EventSource,
18 public base::MessagePumpLibevent::Watcher {
19 public:
20 explicit X11EventSourceLibevent(XDisplay* display);
21
22 ~X11EventSourceLibevent() override;
23
24 private:
25 void AddEventWatcher();
26
27 // PlatformEventSource:
28 void OnDispatcherListChanged() override;
29
30 // base::MessagePumpLibevent::Watcher:
31 void OnFileCanReadWithoutBlocking(int fd) override;
32 void OnFileCanWriteWithoutBlocking(int fd) override;
33
34 base::MessagePumpLibevent::FileDescriptorWatcher watcher_controller_;
35 bool initialized_;
36
37 DISALLOW_COPY_AND_ASSIGN(X11EventSourceLibevent);
38 };
39
40 } // namespace ui
41
42 #endif // UI_EVENTS_PLATFORM_X11_X11_EVENT_SOURCE_LIBEVENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698