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 | 10 |
10 #include <algorithm> | 11 #include <algorithm> |
11 #include <limits> | 12 #include <limits> |
12 #include <vector> | 13 #include <vector> |
13 | 14 |
14 #include "base/bind.h" | 15 #include "base/bind.h" |
15 #include "base/files/file_util.h" | 16 #include "base/files/file_util.h" |
| 17 #include "base/macros.h" |
16 #include "base/numerics/safe_conversions.h" | 18 #include "base/numerics/safe_conversions.h" |
17 #include "base/posix/eintr_wrapper.h" | 19 #include "base/posix/eintr_wrapper.h" |
18 #include "base/strings/string_number_conversions.h" | 20 #include "base/strings/string_number_conversions.h" |
19 #include "base/strings/string_split.h" | 21 #include "base/strings/string_split.h" |
20 #include "base/strings/string_util.h" | 22 #include "base/strings/string_util.h" |
21 #include "chrome/browser/media_galleries/linux/mtp_device_task_helper_map_servic
e.h" | 23 #include "chrome/browser/media_galleries/linux/mtp_device_task_helper_map_servic
e.h" |
22 #include "chrome/browser/media_galleries/linux/snapshot_file_details.h" | 24 #include "chrome/browser/media_galleries/linux/snapshot_file_details.h" |
23 #include "net/base/io_buffer.h" | 25 #include "net/base/io_buffer.h" |
24 #include "third_party/cros_system_api/dbus/service_constants.h" | 26 #include "third_party/cros_system_api/dbus/service_constants.h" |
25 | 27 |
(...skipping 1867 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1893 } | 1895 } |
1894 } | 1896 } |
1895 | 1897 |
1896 void CreateMTPDeviceAsyncDelegate( | 1898 void CreateMTPDeviceAsyncDelegate( |
1897 const std::string& device_location, | 1899 const std::string& device_location, |
1898 const bool read_only, | 1900 const bool read_only, |
1899 const CreateMTPDeviceAsyncDelegateCallback& callback) { | 1901 const CreateMTPDeviceAsyncDelegateCallback& callback) { |
1900 DCHECK_CURRENTLY_ON(content::BrowserThread::IO); | 1902 DCHECK_CURRENTLY_ON(content::BrowserThread::IO); |
1901 callback.Run(new MTPDeviceDelegateImplLinux(device_location, read_only)); | 1903 callback.Run(new MTPDeviceDelegateImplLinux(device_location, read_only)); |
1902 } | 1904 } |
OLD | NEW |