OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_FRAME_HOST_NAVIGATION_REQUEST_H_ | 5 #ifndef CONTENT_BROWSER_FRAME_HOST_NAVIGATION_REQUEST_H_ |
6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATION_REQUEST_H_ | 6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATION_REQUEST_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 | 9 |
10 #include "base/callback_forward.h" | 10 #include "base/callback_forward.h" |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
12 #include "base/memory/ref_counted.h" | 12 #include "base/memory/ref_counted.h" |
13 #include "content/browser/frame_host/navigation_entry_impl.h" | 13 #include "content/browser/frame_host/navigation_entry_impl.h" |
14 #include "content/browser/loader/navigation_url_loader_delegate.h" | 14 #include "content/browser/loader/navigation_url_loader_delegate.h" |
15 #include "content/common/content_export.h" | 15 #include "content/common/content_export.h" |
16 #include "content/common/frame_message_enums.h" | 16 #include "content/common/frame_message_enums.h" |
17 #include "content/common/navigation_params.h" | 17 #include "content/common/navigation_params.h" |
18 #include "content/public/browser/navigation_throttle.h" | 18 #include "content/public/browser/navigation_throttle.h" |
| 19 #include "content/public/common/previews_state.h" |
19 | 20 |
20 namespace content { | 21 namespace content { |
21 | 22 |
22 class FrameNavigationEntry; | 23 class FrameNavigationEntry; |
23 class FrameTreeNode; | 24 class FrameTreeNode; |
24 class NavigationControllerImpl; | 25 class NavigationControllerImpl; |
25 class NavigationHandleImpl; | 26 class NavigationHandleImpl; |
26 class NavigationURLLoader; | 27 class NavigationURLLoader; |
27 class NavigationData; | 28 class NavigationData; |
28 class ResourceRequestBody; | 29 class ResourceRequestBody; |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 }; | 71 }; |
71 | 72 |
72 // Creates a request for a browser-intiated navigation. | 73 // Creates a request for a browser-intiated navigation. |
73 static std::unique_ptr<NavigationRequest> CreateBrowserInitiated( | 74 static std::unique_ptr<NavigationRequest> CreateBrowserInitiated( |
74 FrameTreeNode* frame_tree_node, | 75 FrameTreeNode* frame_tree_node, |
75 const GURL& dest_url, | 76 const GURL& dest_url, |
76 const Referrer& dest_referrer, | 77 const Referrer& dest_referrer, |
77 const FrameNavigationEntry& frame_entry, | 78 const FrameNavigationEntry& frame_entry, |
78 const NavigationEntryImpl& entry, | 79 const NavigationEntryImpl& entry, |
79 FrameMsg_Navigate_Type::Value navigation_type, | 80 FrameMsg_Navigate_Type::Value navigation_type, |
80 LoFiState lofi_state, | 81 PreviewsState previews_state, |
81 bool is_same_document_history_load, | 82 bool is_same_document_history_load, |
82 bool is_history_navigation_in_new_child, | 83 bool is_history_navigation_in_new_child, |
83 const base::TimeTicks& navigation_start, | 84 const base::TimeTicks& navigation_start, |
84 NavigationControllerImpl* controller); | 85 NavigationControllerImpl* controller); |
85 | 86 |
86 // Creates a request for a renderer-intiated navigation. | 87 // Creates a request for a renderer-intiated navigation. |
87 // Note: |body| is sent to the IO thread when calling BeginNavigation, and | 88 // Note: |body| is sent to the IO thread when calling BeginNavigation, and |
88 // should no longer be manipulated afterwards on the UI thread. | 89 // should no longer be manipulated afterwards on the UI thread. |
89 // TODO(clamy): see if ResourceRequestBody could be un-refcounted to avoid | 90 // TODO(clamy): see if ResourceRequestBody could be un-refcounted to avoid |
90 // threading subtleties. | 91 // threading subtleties. |
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
253 std::unique_ptr<StreamHandle> body_; | 254 std::unique_ptr<StreamHandle> body_; |
254 | 255 |
255 base::Closure on_start_checks_complete_closure_; | 256 base::Closure on_start_checks_complete_closure_; |
256 | 257 |
257 DISALLOW_COPY_AND_ASSIGN(NavigationRequest); | 258 DISALLOW_COPY_AND_ASSIGN(NavigationRequest); |
258 }; | 259 }; |
259 | 260 |
260 } // namespace content | 261 } // namespace content |
261 | 262 |
262 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATION_REQUEST_H_ | 263 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATION_REQUEST_H_ |
OLD | NEW |