| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "components/storage_monitor/media_storage_util.h" | 5 #include "components/storage_monitor/media_storage_util.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/callback.h" | 9 #include "base/callback.h" |
| 10 #include "base/files/file_util.h" | 10 #include "base/files/file_util.h" |
| 11 #include "base/logging.h" | 11 #include "base/logging.h" |
| 12 #include "base/metrics/histogram_macros.h" | 12 #include "base/metrics/histogram_macros.h" |
| 13 #include "base/strings/string_util.h" | 13 #include "base/strings/string_util.h" |
| 14 #include "base/strings/utf_string_conversions.h" | 14 #include "base/strings/utf_string_conversions.h" |
| 15 #include "build/build_config.h" |
| 15 #include "components/storage_monitor/removable_device_constants.h" | 16 #include "components/storage_monitor/removable_device_constants.h" |
| 16 #include "components/storage_monitor/storage_monitor.h" | 17 #include "components/storage_monitor/storage_monitor.h" |
| 17 #include "content/public/browser/browser_thread.h" | 18 #include "content/public/browser/browser_thread.h" |
| 18 | 19 |
| 19 using content::BrowserThread; | 20 using content::BrowserThread; |
| 20 | 21 |
| 21 namespace storage_monitor { | 22 namespace storage_monitor { |
| 22 | 23 |
| 23 namespace { | 24 namespace { |
| 24 | 25 |
| (...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 245 | 246 |
| 246 StorageInfoList devices = monitor->GetAllAvailableStorages(); | 247 StorageInfoList devices = monitor->GetAllAvailableStorages(); |
| 247 for (const auto& device : devices) { | 248 for (const auto& device : devices) { |
| 248 if (StorageInfo::IsRemovableDevice(id) && device.device_id() == id) | 249 if (StorageInfo::IsRemovableDevice(id) && device.device_id() == id) |
| 249 return true; | 250 return true; |
| 250 } | 251 } |
| 251 return false; | 252 return false; |
| 252 } | 253 } |
| 253 | 254 |
| 254 } // namespace storage_monitor | 255 } // namespace storage_monitor |
| OLD | NEW |