OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CHROME_BROWSER_MEDIA_GALLERIES_WIN_PORTABLE_DEVICE_MAP_SERVICE_H_ | 5 #ifndef CHROME_BROWSER_MEDIA_GALLERIES_WIN_PORTABLE_DEVICE_MAP_SERVICE_H_ |
6 #define CHROME_BROWSER_MEDIA_GALLERIES_WIN_PORTABLE_DEVICE_MAP_SERVICE_H_ | 6 #define CHROME_BROWSER_MEDIA_GALLERIES_WIN_PORTABLE_DEVICE_MAP_SERVICE_H_ |
7 | 7 |
8 #include <portabledeviceapi.h> | 8 #include <portabledeviceapi.h> |
9 #include <map> | 9 #include <map> |
10 | 10 |
11 #include "base/lazy_instance.h" | 11 #include "base/lazy_instance.h" |
| 12 #include "base/macros.h" |
12 #include "base/strings/string16.h" | 13 #include "base/strings/string16.h" |
13 #include "base/synchronization/lock.h" | 14 #include "base/synchronization/lock.h" |
14 #include "base/win/scoped_comptr.h" | 15 #include "base/win/scoped_comptr.h" |
15 | 16 |
16 // PortableDeviceMapService keeps track of initialized portable device | 17 // PortableDeviceMapService keeps track of initialized portable device |
17 // interfaces. PortableDeviceMapService owns the portable device interfaces. | 18 // interfaces. PortableDeviceMapService owns the portable device interfaces. |
18 class PortableDeviceMapService { | 19 class PortableDeviceMapService { |
19 public: | 20 public: |
20 static PortableDeviceMapService* GetInstance(); | 21 static PortableDeviceMapService* GetInstance(); |
21 | 22 |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 ~PortableDeviceMapService(); | 69 ~PortableDeviceMapService(); |
69 | 70 |
70 // Mapping of |device_location| and IPortableDevice* object. | 71 // Mapping of |device_location| and IPortableDevice* object. |
71 PortableDeviceMap device_map_; | 72 PortableDeviceMap device_map_; |
72 base::Lock lock_; | 73 base::Lock lock_; |
73 | 74 |
74 DISALLOW_COPY_AND_ASSIGN(PortableDeviceMapService); | 75 DISALLOW_COPY_AND_ASSIGN(PortableDeviceMapService); |
75 }; | 76 }; |
76 | 77 |
77 #endif // CHROME_BROWSER_MEDIA_GALLERIES_WIN_PORTABLE_DEVICE_MAP_SERVICE_H_ | 78 #endif // CHROME_BROWSER_MEDIA_GALLERIES_WIN_PORTABLE_DEVICE_MAP_SERVICE_H_ |
OLD | NEW |