Index: content/browser/frame_host/navigator_impl.h |
diff --git a/content/browser/frame_host/navigator_impl.h b/content/browser/frame_host/navigator_impl.h |
index 7d58bbdc41028cba44fb33d7eb8f7616b10bf467..02747a6dece5f35baa7f3d6c4a2f340905b3b85e 100644 |
--- a/content/browser/frame_host/navigator_impl.h |
+++ b/content/browser/frame_host/navigator_impl.h |
@@ -5,6 +5,7 @@ |
#ifndef CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_IMPL_H_ |
#define CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_IMPL_H_ |
+#include "base/memory/linked_ptr.h" |
#include "base/memory/ref_counted.h" |
#include "base/memory/scoped_ptr.h" |
#include "content/browser/frame_host/navigation_controller_impl.h" |
@@ -67,14 +68,17 @@ class CONTENT_EXPORT NavigatorImpl : public Navigator { |
const GlobalRequestID& transferred_global_request_id, |
bool should_replace_current_entry, |
bool user_gesture) OVERRIDE; |
+ virtual void OnBeginNavigation( |
+ FrameTreeNode* frame_tree_node, |
+ const FrameHostMsg_BeginNavigation_Params& params, |
+ const CommonNavigationParams& common_params) OVERRIDE; |
virtual void CommitNavigation( |
- RenderFrameHostImpl* render_frame_host, |
- const GURL& stream_url, |
- const CommonNavigationParams& common_params, |
- const CommitNavigationParams& commit_params) OVERRIDE; |
+ FrameTreeNode* frame_tree_node, |
+ const NavigationBeforeCommitInfo& info) OVERRIDE; |
+ virtual void CancelNavigation(FrameTreeNode* frame_tree_node) OVERRIDE; |
private: |
- virtual ~NavigatorImpl() {} |
+ virtual ~NavigatorImpl(); |
// Navigates to the given entry, which must be the pending entry. Private |
// because all callers should use NavigateToPendingEntry. |
@@ -89,6 +93,14 @@ class CONTENT_EXPORT NavigatorImpl : public Navigator { |
RenderFrameHostImpl* render_frame_host, |
const GURL& url); |
+ // PlzNavigate: sends a RequestNavigation IPC to the renderer to ask it to |
+ // navigate. If no live renderer is present, then the navigation request will |
+ // be sent directly to the ResourceDispatcherHost. |
+ bool RequestNavigation(FrameTreeNode* frame_tree_node, |
+ const NavigationEntryImpl& entry, |
+ NavigationController::ReloadType reload_type, |
+ base::TimeTicks navigation_start); |
+ |
// The NavigationController that will keep track of session history for all |
// RenderFrameHost objects using this NavigatorImpl. |
// TODO(nasko): Move ownership of the NavigationController from |
@@ -99,6 +111,12 @@ class CONTENT_EXPORT NavigatorImpl : public Navigator { |
// events. Can be NULL in tests. |
NavigatorDelegate* delegate_; |
+ // PlzNavigate: used to track the various ongoing NavigationRequests in the |
+ // different FrameTreeNode, based on the frame_tree_node_id. |
nasko
2014/10/01 15:59:49
nit: nodes should be plural, based on the sentence
clamy
2014/10/01 17:10:43
Done.
|
+ typedef base::hash_map<int64, linked_ptr<NavigationRequest>> |
nasko
2014/10/01 15:59:50
Why linked_ptr? Why not scoped_ptr?
clamy
2014/10/01 17:10:43
I was under the impression that you should not put
nasko
2014/10/01 18:20:19
Why not use ScopedPtrHashMap then? Scoped pointers
clamy
2014/10/01 22:30:46
Because I did not know we had a ScopedPtrHashMap :
|
+ NavigationRequestMap; |
+ NavigationRequestMap navigation_request_map_; |
carlosk
2014/10/01 18:31:10
More of a design discussion: this is in fact repli
clamy
2014/10/01 22:30:46
I don't think there is such a plan. And we are not
nasko
2014/10/02 00:09:39
There is no plan to have Navigator be 1-1 with Fra
|
+ |
DISALLOW_COPY_AND_ASSIGN(NavigatorImpl); |
}; |