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

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

Issue 2004533002: mash: Fix mash in debug builds. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_EVENTS_PLATFORM_X11_X11_EVENT_SOURCE_H_ 5 #ifndef UI_EVENTS_PLATFORM_X11_X11_EVENT_SOURCE_H_
6 #define UI_EVENTS_PLATFORM_X11_X11_EVENT_SOURCE_H_ 6 #define UI_EVENTS_PLATFORM_X11_X11_EVENT_SOURCE_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 25 matching lines...) Expand all
36 DISALLOW_COPY_AND_ASSIGN(X11EventSourceDelegate); 36 DISALLOW_COPY_AND_ASSIGN(X11EventSourceDelegate);
37 }; 37 };
38 38
39 // Receives X11 events and sends them to X11EventSourceDelegate. Handles 39 // Receives X11 events and sends them to X11EventSourceDelegate. Handles
40 // receiving, pre-process and post-processing XEvents. 40 // receiving, pre-process and post-processing XEvents.
41 class EVENTS_EXPORT X11EventSource { 41 class EVENTS_EXPORT X11EventSource {
42 public: 42 public:
43 X11EventSource(X11EventSourceDelegate* delegate, XDisplay* display); 43 X11EventSource(X11EventSourceDelegate* delegate, XDisplay* display);
44 ~X11EventSource(); 44 ~X11EventSource();
45 45
46 static bool HasInstance();
47
46 static X11EventSource* GetInstance(); 48 static X11EventSource* GetInstance();
47 49
48 // Called when there is a new XEvent available. Processes all (if any) 50 // Called when there is a new XEvent available. Processes all (if any)
49 // available X events. 51 // available X events.
50 void DispatchXEvents(); 52 void DispatchXEvents();
51 53
52 // Blocks on the X11 event queue until we receive notification from the 54 // Blocks on the X11 event queue until we receive notification from the
53 // xserver that |w| has been mapped; StructureNotifyMask events on |w| are 55 // xserver that |w| has been mapped; StructureNotifyMask events on |w| are
54 // pulled out from the queue and dispatched out of order. 56 // pulled out from the queue and dispatched out of order.
55 // 57 //
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 bool continue_stream_ = true; 102 bool continue_stream_ = true;
101 103
102 std::unique_ptr<X11HotplugEventHandler> hotplug_event_handler_; 104 std::unique_ptr<X11HotplugEventHandler> hotplug_event_handler_;
103 105
104 DISALLOW_COPY_AND_ASSIGN(X11EventSource); 106 DISALLOW_COPY_AND_ASSIGN(X11EventSource);
105 }; 107 };
106 108
107 } // namespace ui 109 } // namespace ui
108 110
109 #endif // UI_EVENTS_PLATFORM_X11_X11_EVENT_SOURCE_H_ 111 #endif // UI_EVENTS_PLATFORM_X11_X11_EVENT_SOURCE_H_
OLDNEW
« no previous file with comments | « chrome/browser/chrome_browser_main_extra_parts_x11.cc ('k') | ui/events/platform/x11/x11_event_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698