diff options
author | reillyg <reillyg@chromium.org> | 2015-01-05 20:06:26 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-01-06 04:07:05 +0000 |
commit | ec1f1c7f010d38beabcbbc653e0df4b299133c7a (patch) | |
tree | c1cf31a586e5bcabfda58d5d1e19d51aa443587f /device/hid/hid_service.h | |
parent | f58a0ec56b77d86d206cd703efee94a7c6513aab (diff) | |
download | chromium_src-ec1f1c7f010d38beabcbbc653e0df4b299133c7a.zip chromium_src-ec1f1c7f010d38beabcbbc653e0df4b299133c7a.tar.gz chromium_src-ec1f1c7f010d38beabcbbc653e0df4b299133c7a.tar.bz2 |
Create DeviceMonitorWin to manage device change notifications.
This change factors out the code in HidServiceWin that manages a
MessageWindow for listening to device change notification messages. A
single window is created for all registered device interfaces and
consumers can use a simple observer interface to subscribe.
The HidService is now destroyed using AtExitManager so that the two
singletons are destroyed in the opposite of the order of their
construction.
BUG=411715
Review URL: https://codereview.chromium.org/818353002
Cr-Commit-Position: refs/heads/master@{#310046}
Diffstat (limited to 'device/hid/hid_service.h')
-rw-r--r-- | device/hid/hid_service.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/device/hid/hid_service.h b/device/hid/hid_service.h index 6c5c5a6..8d296c0 100644 --- a/device/hid/hid_service.h +++ b/device/hid/hid_service.h @@ -9,6 +9,7 @@ #include <string> #include <vector> +#include "base/bind_helpers.h" #include "base/memory/ref_counted.h" #include "base/observer_list.h" #include "base/single_thread_task_runner.h" @@ -59,6 +60,7 @@ class HidService { const ConnectCallback& callback) = 0; protected: + friend void base::DeletePointer<HidService>(HidService* service); friend class HidConnectionTest; typedef std::map<HidDeviceId, HidDeviceInfo> DeviceMap; @@ -75,8 +77,6 @@ class HidService { base::ThreadChecker thread_checker_; private: - class Destroyer; - DeviceMap devices_; bool enumeration_ready_; std::vector<GetDevicesCallback> pending_enumerations_; |