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

Side by Side Diff: ui/events/devices/x11/touch_factory_x11.h

Issue 1073573002: Ozone support for device special cases in keyboard event rewriting. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address review comments Created 5 years, 8 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 (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_EVENTS_DEVICES_X11_TOUCH_FACTORY_X11_H_ 5 #ifndef UI_EVENTS_DEVICES_X11_TOUCH_FACTORY_X11_H_
6 #define UI_EVENTS_DEVICES_X11_TOUCH_FACTORY_X11_H_ 6 #define UI_EVENTS_DEVICES_X11_TOUCH_FACTORY_X11_H_
7 7
8 #include <bitset> 8 #include <bitset>
9 #include <map> 9 #include <map>
10 #include <set> 10 #include <set>
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 88
89 // Sets up the device id in the list |devices| as pointer devices. 89 // Sets up the device id in the list |devices| as pointer devices.
90 // This function is only for test purpose, and it does not query from 90 // This function is only for test purpose, and it does not query from
91 // X server. 91 // X server.
92 void SetPointerDeviceForTest(const std::vector<int>& devices); 92 void SetPointerDeviceForTest(const std::vector<int>& devices);
93 93
94 private: 94 private:
95 // Requirement for Singleton 95 // Requirement for Singleton
96 friend struct DefaultSingletonTraits<TouchFactory>; 96 friend struct DefaultSingletonTraits<TouchFactory>;
97 97
98 void CacheTouchscreenIds(Display* display, int id); 98 void CacheTouchscreenIds(int id);
99 99
100 // NOTE: To keep track of touch devices, we currently maintain a lookup table 100 // NOTE: To keep track of touch devices, we currently maintain a lookup table
101 // to quickly decide if a device is a touch device or not. We also maintain a 101 // to quickly decide if a device is a touch device or not. We also maintain a
102 // list of the touch devices. Ideally, there will be only one touch device, 102 // list of the touch devices. Ideally, there will be only one touch device,
103 // and instead of having the lookup table and the list, there will be a single 103 // and instead of having the lookup table and the list, there will be a single
104 // identifier for the touch device. This can be completed after enough testing 104 // identifier for the touch device. This can be completed after enough testing
105 // on real touch devices. 105 // on real touch devices.
106 106
107 static const int kMaxDeviceNum = 128; 107 static const int kMaxDeviceNum = 128;
108 108
(...skipping 21 matching lines...) Expand all
130 int virtual_core_keyboard_device_; 130 int virtual_core_keyboard_device_;
131 131
132 SequentialIDGenerator id_generator_; 132 SequentialIDGenerator id_generator_;
133 133
134 DISALLOW_COPY_AND_ASSIGN(TouchFactory); 134 DISALLOW_COPY_AND_ASSIGN(TouchFactory);
135 }; 135 };
136 136
137 } // namespace ui 137 } // namespace ui
138 138
139 #endif // UI_EVENTS_DEVICES_X11_TOUCH_FACTORY_X11_H_ 139 #endif // UI_EVENTS_DEVICES_X11_TOUCH_FACTORY_X11_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698