| OLD | NEW |
| 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 CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_MTP_DEVICE_MAP_SERVICE_H_ | 5 #ifndef CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_MTP_DEVICE_MAP_SERVICE_H_ |
| 6 #define CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_MTP_DEVICE_MAP_SERVICE_H_ | 6 #define CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_MTP_DEVICE_MAP_SERVICE_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 | 9 |
| 10 #include "base/files/file_path.h" | 10 #include "base/files/file_path.h" |
| 11 #include "base/lazy_instance.h" | 11 #include "base/lazy_instance.h" |
| 12 #include "base/threading/thread_checker.h" | 12 #include "base/threading/thread_checker.h" |
| 13 | 13 |
| 14 namespace chrome { | |
| 15 | |
| 16 class MTPDeviceAsyncDelegate; | 14 class MTPDeviceAsyncDelegate; |
| 17 | 15 |
| 18 // This class provides media transfer protocol (MTP) device delegate to | 16 // This class provides media transfer protocol (MTP) device delegate to |
| 19 // complete media file system operations. | 17 // complete media file system operations. |
| 20 class MTPDeviceMapService { | 18 class MTPDeviceMapService { |
| 21 public: | 19 public: |
| 22 static MTPDeviceMapService* GetInstance(); | 20 static MTPDeviceMapService* GetInstance(); |
| 23 | 21 |
| 24 // Adds the MTP device delegate to the map service. |device_location| | 22 // Adds the MTP device delegate to the map service. |device_location| |
| 25 // specifies the mount location of the MTP device. | 23 // specifies the mount location of the MTP device. |
| (...skipping 29 matching lines...) Expand all Loading... |
| 55 // Following member variables are used to manage asynchronous // | 53 // Following member variables are used to manage asynchronous // |
| 56 // MTP device delegate objects. // | 54 // MTP device delegate objects. // |
| 57 ///////////////////////////////////////////////////////////////////////////// | 55 ///////////////////////////////////////////////////////////////////////////// |
| 58 // Map of attached mtp device async delegates. | 56 // Map of attached mtp device async delegates. |
| 59 AsyncDelegateMap async_delegate_map_; | 57 AsyncDelegateMap async_delegate_map_; |
| 60 base::ThreadChecker thread_checker_; | 58 base::ThreadChecker thread_checker_; |
| 61 | 59 |
| 62 DISALLOW_COPY_AND_ASSIGN(MTPDeviceMapService); | 60 DISALLOW_COPY_AND_ASSIGN(MTPDeviceMapService); |
| 63 }; | 61 }; |
| 64 | 62 |
| 65 } // namespace chrome | |
| 66 | |
| 67 #endif // CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_MTP_DEVICE_MAP_SERVICE_H_ | 63 #endif // CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_MTP_DEVICE_MAP_SERVICE_H_ |
| OLD | NEW |