OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #ifndef CHROME_BROWSER_DOWNLOAD_DOWNLOAD_TARGET_DETERMINER_H_ | 5 #ifndef CHROME_BROWSER_DOWNLOAD_DOWNLOAD_TARGET_DETERMINER_H_ |
6 #define CHROME_BROWSER_DOWNLOAD_DOWNLOAD_TARGET_DETERMINER_H_ | 6 #define CHROME_BROWSER_DOWNLOAD_DOWNLOAD_TARGET_DETERMINER_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "base/files/file_path.h" | 11 #include "base/files/file_path.h" |
12 #include "base/macros.h" | 12 #include "base/macros.h" |
13 #include "base/memory/ref_counted.h" | 13 #include "base/memory/ref_counted.h" |
14 #include "base/memory/weak_ptr.h" | 14 #include "base/memory/weak_ptr.h" |
15 #include "base/task/cancelable_task_tracker.h" | 15 #include "base/task/cancelable_task_tracker.h" |
16 #include "build/build_config.h" | 16 #include "build/build_config.h" |
17 #include "chrome/browser/download/download_path_reservation_tracker.h" | 17 #include "chrome/browser/download/download_path_reservation_tracker.h" |
18 #include "chrome/browser/download/download_target_determiner_delegate.h" | 18 #include "chrome/browser/download/download_target_determiner_delegate.h" |
19 #include "chrome/browser/download/download_target_info.h" | 19 #include "chrome/browser/download/download_target_info.h" |
20 #include "chrome/common/safe_browsing/download_file_types.pb.h" | 20 #include "chrome/common/safe_browsing/download_file_types.pb.h" |
21 #include "content/public/browser/download_danger_type.h" | 21 #include "content/public/browser/download_danger_type.h" |
22 #include "content/public/browser/download_item.h" | 22 #include "content/public/browser/download_item.h" |
23 #include "content/public/browser/download_manager_delegate.h" | 23 #include "content/public/browser/download_manager_delegate.h" |
24 #include "ppapi/features/features.h" | 24 #include "ppapi/features/features.h" |
25 | 25 |
26 class Profile; | 26 class Profile; |
27 class DownloadPrefs; | 27 class DownloadPrefs; |
28 | 28 |
29 namespace content { | |
30 enum DownloadDangerType; | |
31 } | |
32 | |
33 // Determines the target of the download. | 29 // Determines the target of the download. |
34 // | 30 // |
35 // Terminology: | 31 // Terminology: |
36 // Virtual Path: A path representing the target of the download that may or | 32 // Virtual Path: A path representing the target of the download that may or |
37 // may not be a physical file path. E.g. if the target of the download is in | 33 // may not be a physical file path. E.g. if the target of the download is in |
38 // cloud storage, then the virtual path may be relative to a logical mount | 34 // cloud storage, then the virtual path may be relative to a logical mount |
39 // point. | 35 // point. |
40 // | 36 // |
41 // Local Path: A local file system path where the downloads system should | 37 // Local Path: A local file system path where the downloads system should |
42 // write the file to. | 38 // write the file to. |
(...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
335 DownloadTargetDeterminerDelegate* delegate_; | 331 DownloadTargetDeterminerDelegate* delegate_; |
336 CompletionCallback completion_callback_; | 332 CompletionCallback completion_callback_; |
337 base::CancelableTaskTracker history_tracker_; | 333 base::CancelableTaskTracker history_tracker_; |
338 | 334 |
339 base::WeakPtrFactory<DownloadTargetDeterminer> weak_ptr_factory_; | 335 base::WeakPtrFactory<DownloadTargetDeterminer> weak_ptr_factory_; |
340 | 336 |
341 DISALLOW_COPY_AND_ASSIGN(DownloadTargetDeterminer); | 337 DISALLOW_COPY_AND_ASSIGN(DownloadTargetDeterminer); |
342 }; | 338 }; |
343 | 339 |
344 #endif // CHROME_BROWSER_DOWNLOAD_DOWNLOAD_TARGET_DETERMINER_H_ | 340 #endif // CHROME_BROWSER_DOWNLOAD_DOWNLOAD_TARGET_DETERMINER_H_ |
OLD | NEW |