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

Side by Side Diff: ui/events/ozone/device/udev/scoped_udev.h

Issue 250793005: Refactor Udev device support in Ozone and add a DRM hotplug monitor (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 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 | Annotate | Revision Log
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_OZONE_EVDEV_SCOPED_UDEV_H_ 5 #ifndef UI_EVENTS_OZONE_DEVICE_UDEV_SCOPED_UDEV_H_
6 #define UI_EVENTS_OZONE_EVDEV_SCOPED_UDEV_H_ 6 #define UI_EVENTS_OZONE_DEVICE_UDEV_SCOPED_UDEV_H_
7 7
8 #include <libudev.h> 8 #include <libudev.h>
9 9
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
11 11
12 // This file enables management of udev object references using scoped_ptr<> by 12 // This file enables management of udev object references using scoped_ptr<> by
13 // associating a custom deleter that drops the reference rather than deleting. 13 // associating a custom deleter that drops the reference rather than deleting.
14 14
15 namespace ui { 15 namespace ui {
16 16
(...skipping 23 matching lines...) Expand all
40 // Scoped struct udev_monitor. 40 // Scoped struct udev_monitor.
41 struct UdevMonitorDeleter { 41 struct UdevMonitorDeleter {
42 void operator()(struct udev_monitor* udev_monitor) { 42 void operator()(struct udev_monitor* udev_monitor) {
43 udev_monitor_unref(udev_monitor); 43 udev_monitor_unref(udev_monitor);
44 } 44 }
45 }; 45 };
46 typedef scoped_ptr<struct udev_monitor, UdevMonitorDeleter> scoped_udev_monitor; 46 typedef scoped_ptr<struct udev_monitor, UdevMonitorDeleter> scoped_udev_monitor;
47 47
48 } // namespace ui 48 } // namespace ui
49 49
50 #endif // UI_EVENTS_OZONE_EVDEV_SCOPED_UDEV_H_ 50 #endif // UI_EVENTS_OZONE_DEVICE_UDEV_SCOPED_UDEV_H_
OLDNEW
« no previous file with comments | « ui/events/ozone/device/udev/device_manager_udev.cc ('k') | ui/events/ozone/evdev/device_manager_evdev.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698