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

Unified Diff: ui/events/ozone/evdev/scoped_input_device.h

Issue 2657533008: Merge "Fix double-close in EventConverterEvdevImpl" (Closed)
Patch Set: Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: ui/events/ozone/evdev/scoped_input_device.h
diff --git a/ui/events/ozone/evdev/scoped_input_device.h b/ui/events/ozone/evdev/scoped_input_device.h
new file mode 100644
index 0000000000000000000000000000000000000000..24d8aa58c27d3a3a006ce6dc5357b12ed37e598d
--- /dev/null
+++ b/ui/events/ozone/evdev/scoped_input_device.h
@@ -0,0 +1,25 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef UI_EVENTS_OZONE_EVDEV_SCOPED_INPUT_DEVICE_H_
+#define UI_EVENTS_OZONE_EVDEV_SCOPED_INPUT_DEVICE_H_
+
+#include "base/scoped_generic.h"
+
+namespace ui {
+namespace internal {
+
+struct ScopedInputDeviceCloseTraits {
+ static int InvalidValue() { return -1; }
+ static void Free(int fd);
+};
+
+} // namespace internal
+
+typedef base::ScopedGeneric<int, internal::ScopedInputDeviceCloseTraits>
+ ScopedInputDevice;
+
+} // namespace ui
+
+#endif // UI_EVENTS_OZONE_EVDEV_SCOPED_INPUT_DEVICE_H_
« no previous file with comments | « ui/events/ozone/evdev/libgestures_glue/event_reader_libevdev_cros.cc ('k') | ui/events/ozone/evdev/scoped_input_device.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698