Chromium Code Reviews| 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 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_REQUEST_HANDLE_H_ | 5 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_REQUEST_HANDLE_H_ |
| 6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_REQUEST_HANDLE_H_ | 6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_REQUEST_HANDLE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 53 // no-ops, to confirm that no non-testing code actually uses | 53 // no-ops, to confirm that no non-testing code actually uses |
| 54 // a null DownloadRequestHandle. But for now, we need the no-op | 54 // a null DownloadRequestHandle. But for now, we need the no-op |
| 55 // behavior for unit tests. Long-term, this should be fixed by | 55 // behavior for unit tests. Long-term, this should be fixed by |
| 56 // allowing mocking of ResourceDispatcherHost in unit tests. | 56 // allowing mocking of ResourceDispatcherHost in unit tests. |
| 57 DownloadRequestHandle(); | 57 DownloadRequestHandle(); |
| 58 | 58 |
| 59 // Note that |rdh| is required to be non-null. | 59 // Note that |rdh| is required to be non-null. |
| 60 DownloadRequestHandle(const base::WeakPtr<DownloadResourceHandler>& handler, | 60 DownloadRequestHandle(const base::WeakPtr<DownloadResourceHandler>& handler, |
| 61 int child_id, | 61 int child_id, |
| 62 int render_view_id, | 62 int render_view_id, |
| 63 int request_id); | 63 int request_id, |
| 64 int64 frame_tree_node_id); | |
|
nasko
2015/05/22 16:48:07
FTN id is now int, not in64. It changed recently.
clamy
2015/05/26 10:43:11
Done.
| |
| 64 | 65 |
| 65 // Implement DownloadRequestHandleInterface interface. | 66 // Implement DownloadRequestHandleInterface interface. |
| 66 WebContents* GetWebContents() const override; | 67 WebContents* GetWebContents() const override; |
| 67 DownloadManager* GetDownloadManager() const override; | 68 DownloadManager* GetDownloadManager() const override; |
| 68 void PauseRequest() const override; | 69 void PauseRequest() const override; |
| 69 void ResumeRequest() const override; | 70 void ResumeRequest() const override; |
| 70 void CancelRequest() const override; | 71 void CancelRequest() const override; |
| 71 std::string DebugString() const override; | 72 std::string DebugString() const override; |
| 72 | 73 |
| 73 private: | 74 private: |
| 74 base::WeakPtr<DownloadResourceHandler> handler_; | 75 base::WeakPtr<DownloadResourceHandler> handler_; |
| 75 | 76 |
| 76 // The ID of the child process that started the download. | 77 // The ID of the child process that started the download. |
| 77 int child_id_; | 78 int child_id_; |
| 78 | 79 |
| 79 // The ID of the render view that started the download. | 80 // The ID of the render view that started the download. |
| 80 int render_view_id_; | 81 int render_view_id_; |
| 81 | 82 |
| 82 // The ID associated with the request used for the download. | 83 // The ID associated with the request used for the download. |
| 83 int request_id_; | 84 int request_id_; |
| 85 | |
| 86 // PlzNavigate | |
| 87 // The ID of the FrameTreeNode that started the download. | |
| 88 int64 frame_tree_node_id_; | |
|
nasko
2015/05/22 16:48:06
int
clamy
2015/05/26 10:43:11
Done.
| |
| 84 }; | 89 }; |
| 85 | 90 |
| 86 } // namespace content | 91 } // namespace content |
| 87 | 92 |
| 88 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_REQUEST_HANDLE_H_ | 93 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_REQUEST_HANDLE_H_ |
| OLD | NEW |