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

Unified Diff: chrome/browser/intents/device_attached_intent_source.cc

Issue 10868110: Remove MediaDeviceMapService references from |DeviceAttachedIntentSource::OnMediaDetached| function. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Added TODO Created 8 years, 4 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/intents/device_attached_intent_source.cc
diff --git a/chrome/browser/intents/device_attached_intent_source.cc b/chrome/browser/intents/device_attached_intent_source.cc
index 5cb5762417100d13e1aebaa1c312bb442dc3ea87..08b7131c0d42cb5ad4be6c08614b322c7efae882 100644
--- a/chrome/browser/intents/device_attached_intent_source.cc
+++ b/chrome/browser/intents/device_attached_intent_source.cc
@@ -23,13 +23,6 @@
#include "webkit/fileapi/isolated_context.h"
#include "webkit/glue/web_intent_data.h"
#include "webkit/glue/web_intent_service_data.h"
-#include "webkit/fileapi/media/media_file_system_config.h"
-
-#if defined(SUPPORT_MEDIA_FILESYSTEM)
-#include "webkit/fileapi/media/media_device_map_service.h"
-
-using fileapi::MediaDeviceMapService;
-#endif
using base::SystemMonitor;
using chrome::MediaStorageUtil;
@@ -139,6 +132,8 @@ void DeviceAttachedIntentSource::DispatchIntentsForService(
const FilePath device_path(device_info.location);
// TODO(kinuko, kmadhusu): Use a different file system type for MTP.
+ // TODO(kmadhusu): To manage the registered file systems efficiently, register
+ // the attached device media file system using MediaFileSystemRegistry.
const std::string fs_id = fileapi::IsolatedContext::GetInstance()->
RegisterFileSystemForPath(fileapi::kFileSystemTypeNativeMedia,
device_path, &device_name);
@@ -157,19 +152,7 @@ void DeviceAttachedIntentSource::OnRemovableStorageDetached(
if (it == device_id_map_.end())
return;
- // TODO(kmadhusu) This should be something like
- // RevokeFileSystemByDevice(std::string)
FilePath path(it->second.location);
fileapi::IsolatedContext::GetInstance()->RevokeFileSystemByPath(path);
-
-#if defined(SUPPORT_MEDIA_FILESYSTEM)
- // TODO(kmadhusu, vandebo): Clean up this code. http://crbug.com/140340.
- MediaStorageUtil::Type type;
- MediaStorageUtil::CrackDeviceId(it->second.device_id, &type, NULL);
- if (type == MediaStorageUtil::USB_MTP) {
- MediaDeviceMapService::GetInstance()->RemoveMediaDevice(
- it->second.location);
- }
-#endif
device_id_map_.erase(it);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698