| 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 #include "chrome/browser/media_galleries/mac/mtp_device_delegate_impl_mac.h" | 5 #include "chrome/browser/media_galleries/mac/mtp_device_delegate_impl_mac.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/memory/scoped_nsobject.h" | 9 #include "base/memory/scoped_nsobject.h" |
| 10 #include "base/threading/sequenced_worker_pool.h" | 10 #include "base/threading/sequenced_worker_pool.h" |
| 11 #include "chrome/browser/media_galleries/mtp_device_delegate_impl.h" | 11 #include "chrome/browser/media_galleries/mtp_device_delegate_impl.h" |
| 12 #include "chrome/browser/storage_monitor/image_capture_device.h" | 12 #include "chrome/browser/storage_monitor/image_capture_device.h" |
| 13 #include "chrome/browser/storage_monitor/image_capture_device_manager.h" | 13 #include "chrome/browser/storage_monitor/image_capture_device_manager.h" |
| 14 #include "chrome/browser/storage_monitor/media_storage_util.h" | 14 #include "chrome/browser/storage_monitor/media_storage_util.h" |
| 15 #include "content/public/browser/browser_thread.h" | 15 #include "content/public/browser/browser_thread.h" |
| 16 #include "webkit/fileapi/async_file_util.h" | 16 #include "webkit/browser/fileapi/async_file_util.h" |
| 17 | 17 |
| 18 namespace chrome { | 18 namespace chrome { |
| 19 | 19 |
| 20 namespace { | 20 namespace { |
| 21 | 21 |
| 22 int kReadDirectoryTimeLimitSeconds = 20; | 22 int kReadDirectoryTimeLimitSeconds = 20; |
| 23 | 23 |
| 24 typedef MTPDeviceAsyncDelegate::CreateSnapshotFileSuccessCallback | 24 typedef MTPDeviceAsyncDelegate::CreateSnapshotFileSuccessCallback |
| 25 CreateSnapshotFileSuccessCallback; | 25 CreateSnapshotFileSuccessCallback; |
| 26 typedef MTPDeviceAsyncDelegate::ErrorCallback ErrorCallback; | 26 typedef MTPDeviceAsyncDelegate::ErrorCallback ErrorCallback; |
| (...skipping 448 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 475 StorageInfo::Type type; | 475 StorageInfo::Type type; |
| 476 bool cracked = StorageInfo::CrackDeviceId(device_name, &type, &device_id); | 476 bool cracked = StorageInfo::CrackDeviceId(device_name, &type, &device_id); |
| 477 DCHECK(cracked); | 477 DCHECK(cracked); |
| 478 DCHECK_EQ(StorageInfo::MAC_IMAGE_CAPTURE, type); | 478 DCHECK_EQ(StorageInfo::MAC_IMAGE_CAPTURE, type); |
| 479 | 479 |
| 480 cb.Run(new MTPDeviceDelegateImplMac(device_id, device_location)); | 480 cb.Run(new MTPDeviceDelegateImplMac(device_id, device_location)); |
| 481 } | 481 } |
| 482 | 482 |
| 483 } // namespace chrome | 483 } // namespace chrome |
| 484 | 484 |
| OLD | NEW |