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/linux/mtp_device_delegate_impl_linux.h" | 5 #include "chrome/browser/media_galleries/linux/mtp_device_delegate_impl_linux.h" |
6 | 6 |
7 #include <errno.h> | 7 #include <errno.h> |
8 #include <fcntl.h> | 8 #include <fcntl.h> |
9 #include <stddef.h> | 9 #include <stddef.h> |
10 | 10 |
(...skipping 349 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
360 const base::FilePath& path, | 360 const base::FilePath& path, |
361 content::BrowserThread::ID thread_id, | 361 content::BrowserThread::ID thread_id, |
362 const tracked_objects::Location& location, | 362 const tracked_objects::Location& location, |
363 const base::Closure& task) | 363 const base::Closure& task) |
364 : path(path), | 364 : path(path), |
365 thread_id(thread_id), | 365 thread_id(thread_id), |
366 location(location), | 366 location(location), |
367 task(task) { | 367 task(task) { |
368 } | 368 } |
369 | 369 |
| 370 MTPDeviceDelegateImplLinux::PendingTaskInfo::PendingTaskInfo( |
| 371 const PendingTaskInfo& other) = default; |
| 372 |
370 MTPDeviceDelegateImplLinux::PendingTaskInfo::~PendingTaskInfo() { | 373 MTPDeviceDelegateImplLinux::PendingTaskInfo::~PendingTaskInfo() { |
371 } | 374 } |
372 | 375 |
373 // Represents a file on the MTP device. | 376 // Represents a file on the MTP device. |
374 // Lives on the IO thread. | 377 // Lives on the IO thread. |
375 class MTPDeviceDelegateImplLinux::MTPFileNode { | 378 class MTPDeviceDelegateImplLinux::MTPFileNode { |
376 public: | 379 public: |
377 MTPFileNode(uint32_t file_id, | 380 MTPFileNode(uint32_t file_id, |
378 const std::string& file_name, | 381 const std::string& file_name, |
379 MTPFileNode* parent, | 382 MTPFileNode* parent, |
(...skipping 1515 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1895 } | 1898 } |
1896 } | 1899 } |
1897 | 1900 |
1898 void CreateMTPDeviceAsyncDelegate( | 1901 void CreateMTPDeviceAsyncDelegate( |
1899 const std::string& device_location, | 1902 const std::string& device_location, |
1900 const bool read_only, | 1903 const bool read_only, |
1901 const CreateMTPDeviceAsyncDelegateCallback& callback) { | 1904 const CreateMTPDeviceAsyncDelegateCallback& callback) { |
1902 DCHECK_CURRENTLY_ON(content::BrowserThread::IO); | 1905 DCHECK_CURRENTLY_ON(content::BrowserThread::IO); |
1903 callback.Run(new MTPDeviceDelegateImplLinux(device_location, read_only)); | 1906 callback.Run(new MTPDeviceDelegateImplLinux(device_location, read_only)); |
1904 } | 1907 } |
OLD | NEW |