| Index: chrome/browser/storage_monitor/storage_monitor_linux.cc
|
| diff --git a/chrome/browser/storage_monitor/storage_monitor_linux.cc b/chrome/browser/storage_monitor/storage_monitor_linux.cc
|
| index 64954bd7ff2ba6bbecbd03507f2c39dc382da9a1..1b5457902dc031213890d8e8023ded2349cbb13d 100644
|
| --- a/chrome/browser/storage_monitor/storage_monitor_linux.cc
|
| +++ b/chrome/browser/storage_monitor/storage_monitor_linux.cc
|
| @@ -19,7 +19,6 @@
|
| #include "base/string_util.h"
|
| #include "base/strings/string_number_conversions.h"
|
| #include "base/utf_string_conversions.h"
|
| -#include "chrome/browser/storage_monitor/media_device_notifications_utils.h"
|
| #include "chrome/browser/storage_monitor/media_storage_util.h"
|
| #include "chrome/browser/storage_monitor/removable_device_constants.h"
|
| #include "chrome/browser/storage_monitor/udev_util_linux.h"
|
| @@ -158,7 +157,8 @@ string16 GetDeviceName(struct udev_device* device,
|
| "RemovableDeviceNotificationsLinux.device_file_system_uuid_available",
|
| !device_label.empty());
|
|
|
| - const string16 name = GetFullProductName(vendor_name, model_name);
|
| + const string16 name = MediaStorageUtil::GetFullProductName(vendor_name,
|
| + model_name);
|
|
|
| const string16 device_label_utf16 =
|
| (!device_label.empty() && IsStringUTF8(device_label)) ?
|
| @@ -240,7 +240,7 @@ void GetDeviceInfo(const base::FilePath& device_path,
|
| if (device_id) {
|
| MediaStorageUtil::Type type = MediaStorageUtil::FIXED_MASS_STORAGE;
|
| if (is_removable) {
|
| - if (IsMediaDevice(mount_point.value()))
|
| + if (MediaStorageUtil::HasDcim(mount_point.value()))
|
| type = MediaStorageUtil::REMOVABLE_MASS_STORAGE_WITH_DCIM;
|
| else
|
| type = MediaStorageUtil::REMOVABLE_MASS_STORAGE_NO_DCIM;
|
| @@ -463,9 +463,11 @@ void StorageMonitorLinux::AddNewMount(const base::FilePath& mount_device,
|
| mount_priority_map_[mount_device][mount_point] = removable;
|
|
|
| if (removable) {
|
| - receiver()->ProcessAttach(StorageInfo(
|
| - device_id, GetDisplayNameForDevice(partition_size_in_bytes, name),
|
| - mount_point.value()));
|
| + string16 display_name = MediaStorageUtil::GetDisplayNameForDevice(
|
| + partition_size_in_bytes, name);
|
| +
|
| + receiver()->ProcessAttach(StorageInfo(device_id, display_name,
|
| + mount_point.value()));
|
| }
|
| }
|
|
|
|
|