Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(21)

Side by Side Diff: content/browser/download/download_create_info.h

Issue 562603002: Move PageTransition from //content/public/common to //ui/base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_CREATE_INFO_H_ 5 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_CREATE_INFO_H_
6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_CREATE_INFO_H_ 6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_CREATE_INFO_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/basictypes.h" 11 #include "base/basictypes.h"
12 #include "base/files/file_path.h" 12 #include "base/files/file_path.h"
13 #include "base/time/time.h" 13 #include "base/time/time.h"
14 #include "content/browser/download/download_file.h" 14 #include "content/browser/download/download_file.h"
15 #include "content/browser/download/download_request_handle.h" 15 #include "content/browser/download/download_request_handle.h"
16 #include "content/common/content_export.h" 16 #include "content/common/content_export.h"
17 #include "content/public/browser/download_save_info.h" 17 #include "content/public/browser/download_save_info.h"
18 #include "content/public/common/page_transition_types.h"
19 #include "net/base/net_log.h" 18 #include "net/base/net_log.h"
19 #include "ui/base/page_transition_types.h"
20 #include "url/gurl.h" 20 #include "url/gurl.h"
21 21
22 namespace content { 22 namespace content {
23 23
24 // Used for informing the download manager of a new download, since we don't 24 // Used for informing the download manager of a new download, since we don't
25 // want to pass |DownloadItem|s between threads. 25 // want to pass |DownloadItem|s between threads.
26 struct CONTENT_EXPORT DownloadCreateInfo { 26 struct CONTENT_EXPORT DownloadCreateInfo {
27 DownloadCreateInfo(const base::Time& start_time, 27 DownloadCreateInfo(const base::Time& start_time,
28 int64 total_bytes, 28 int64 total_bytes,
29 const net::BoundNetLog& bound_net_log, 29 const net::BoundNetLog& bound_net_log,
30 bool has_user_gesture, 30 bool has_user_gesture,
31 PageTransition transition_type, 31 ui::PageTransition transition_type,
32 scoped_ptr<DownloadSaveInfo> save_info); 32 scoped_ptr<DownloadSaveInfo> save_info);
33 DownloadCreateInfo(); 33 DownloadCreateInfo();
34 ~DownloadCreateInfo(); 34 ~DownloadCreateInfo();
35 35
36 std::string DebugString() const; 36 std::string DebugString() const;
37 37
38 // The URL from which we are downloading. This is the final URL after any 38 // The URL from which we are downloading. This is the final URL after any
39 // redirection by the server for |url_chain|. 39 // redirection by the server for |url_chain|.
40 const GURL& url() const; 40 const GURL& url() const;
41 41
(...skipping 14 matching lines...) Expand all
56 56
57 // The total download size. 57 // The total download size.
58 int64 total_bytes; 58 int64 total_bytes;
59 59
60 // The ID of the download. 60 // The ID of the download.
61 uint32 download_id; 61 uint32 download_id;
62 62
63 // True if the download was initiated by user action. 63 // True if the download was initiated by user action.
64 bool has_user_gesture; 64 bool has_user_gesture;
65 65
66 PageTransition transition_type; 66 ui::PageTransition transition_type;
67 67
68 // The content-disposition string from the response header. 68 // The content-disposition string from the response header.
69 std::string content_disposition; 69 std::string content_disposition;
70 70
71 // The mime type string from the response header (may be overridden). 71 // The mime type string from the response header (may be overridden).
72 std::string mime_type; 72 std::string mime_type;
73 73
74 // The value of the content type header sent with the downloaded item. It 74 // The value of the content type header sent with the downloaded item. It
75 // may be different from |mime_type|, which may be set based on heuristics 75 // may be different from |mime_type|, which may be set based on heuristics
76 // which may look at the file extension and first few bytes of the file. 76 // which may look at the file extension and first few bytes of the file.
(...skipping 21 matching lines...) Expand all
98 // download item's. 98 // download item's.
99 const net::BoundNetLog request_bound_net_log; 99 const net::BoundNetLog request_bound_net_log;
100 100
101 private: 101 private:
102 DISALLOW_COPY_AND_ASSIGN(DownloadCreateInfo); 102 DISALLOW_COPY_AND_ASSIGN(DownloadCreateInfo);
103 }; 103 };
104 104
105 } // namespace content 105 } // namespace content
106 106
107 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_CREATE_INFO_H_ 107 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_CREATE_INFO_H_
OLDNEW
« no previous file with comments | « content/browser/devtools/renderer_overrides_handler.cc ('k') | content/browser/download/download_create_info.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698