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

Unified Diff: chrome/browser/media_gallery/media_file_system_registry.h

Issue 10781014: Isolated FS for media devices. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: '' Created 8 years, 5 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: chrome/browser/media_gallery/media_file_system_registry.h
diff --git a/chrome/browser/media_gallery/media_file_system_registry.h b/chrome/browser/media_gallery/media_file_system_registry.h
index a4055710de1bb16d1555360f1d2503b8d1fa8fe9..5f1ff985edcd85b1a7d0d8fa588725d56c024cf3 100644
--- a/chrome/browser/media_gallery/media_file_system_registry.h
+++ b/chrome/browser/media_gallery/media_file_system_registry.h
@@ -72,8 +72,9 @@ class MediaFileSystemRegistry
typedef std::map<const content::RenderProcessHost*,
MediaPathToFSIDMap> ChildIdToMediaFSMap;
- // Mapping of device id to mount path.
- typedef std::map<std::string, FilePath> DeviceIdToMediaPathMap;
+ // Mapping of device id to media device info.
+ typedef std::map<std::string, base::SystemMonitor::MediaDeviceInfo>
+ DeviceIdToInfoMap;
// Obtain an instance of this class via GetInstance().
MediaFileSystemRegistry();
@@ -85,16 +86,21 @@ class MediaFileSystemRegistry
void UnregisterForRPHGoneNotifications(const content::RenderProcessHost* rph);
// Registers a path as a media file system and return the filesystem id.
- std::string RegisterPathAsFileSystem(const FilePath& path);
+ std::string RegisterPathAsFileSystem(
+ const base::SystemMonitor::MediaDeviceType& device_type,
+ const FilePath& path);
+
// Revoke a media file system with a given |path|.
- void RevokeMediaFileSystem(const FilePath& path);
+ void RevokeMediaFileSystem(
+ const base::SystemMonitor::MediaDeviceType& device_type,
+ const FilePath& path);
// Only accessed on the UI thread.
ChildIdToMediaFSMap media_fs_map_;
// Only accessed on the UI thread.
- DeviceIdToMediaPathMap device_id_map_;
+ DeviceIdToInfoMap device_id_map_;
// Is only used on the UI thread.
content::NotificationRegistrar registrar_;

Powered by Google App Engine
This is Rietveld 408576698