| Index: content/browser/renderer_host/render_view_host.h
|
| diff --git a/content/browser/renderer_host/render_view_host.h b/content/browser/renderer_host/render_view_host.h
|
| index c9e7027eef851e44ec3c8e053e9dbfb95e8ec08c..cc3741266aeba77db29639b0dcd3d808c55d5a73 100644
|
| --- a/content/browser/renderer_host/render_view_host.h
|
| +++ b/content/browser/renderer_host/render_view_host.h
|
| @@ -161,27 +161,39 @@ class RenderViewHost : public RenderWidgetHost {
|
| // are_navigations_suspended() first.
|
| void SetNavigationsSuspended(bool suspend);
|
|
|
| + // Clears any suspended navigation state after a cross-site navigation is
|
| + // canceled or suspended. This is important if we later return to this
|
| + // RenderViewHost.
|
| + void CancelSuspendedNavigations();
|
| +
|
| + // Whether this RenderViewHost has been swapped out to be displayed by a
|
| + // different process.
|
| + bool is_swapped_out() const { return is_swapped_out_; }
|
| +
|
| // Causes the renderer to invoke the onbeforeunload event handler. The
|
| - // result will be returned via ViewMsg_ShouldClose. See also ClosePage which
|
| - // will fire the PageUnload event.
|
| + // result will be returned via ViewMsg_ShouldClose. See also ClosePage and
|
| + // SwapOut, which fire the PageUnload event.
|
| //
|
| // Set bool for_cross_site_transition when this close is just for the current
|
| // RenderView in the case of a cross-site transition. False means we're
|
| // closing the entire tab.
|
| void FirePageBeforeUnload(bool for_cross_site_transition);
|
|
|
| + // Tells the renderer that this RenderView is being swapped out for one in a
|
| + // different renderer process. The renderer should preserve the Frame object
|
| + // until it exits (when it has no more active RenderViews).
|
| + //
|
| + // Please see ViewMsg_SwapOut_Params in view_messages.h for a description
|
| + // of the parameters.
|
| + void SwapOut(int new_render_process_host_id, int new_request_id);
|
| +
|
| + // Called by ResourceDispatcherHost after the SwapOutACK is received.
|
| + void OnSwapOutACK();
|
| +
|
| // Causes the renderer to close the current page, including running its
|
| // onunload event handler. A ClosePage_ACK message will be sent to the
|
| // ResourceDispatcherHost when it is finished.
|
| - //
|
| - // Please see ViewMsg_ClosePage in resource_messages_internal.h for a
|
| - // description of the parameters.
|
| - void ClosePage(bool for_cross_site_transition,
|
| - int new_render_process_host_id,
|
| - int new_request_id);
|
| -
|
| - // Called by ResourceDispatcherHost after the ClosePageACK is received.
|
| - void OnClosePageACK(bool for_cross_site_transition);
|
| + void ClosePage();
|
|
|
| // Close the page ignoring whether it has unload events registers.
|
| // This is called after the beforeunload and unload events have fired
|
| @@ -531,6 +543,25 @@ class RenderViewHost : public RenderWidgetHost {
|
| void OnMsgDidStartLoading();
|
| void OnMsgDidStopLoading();
|
| void OnMsgDidChangeLoadProgress(double load_progress);
|
| + void OnMsgDidStartProvisionalLoadForFrame(int64 frame_id,
|
| + bool main_frame,
|
| + const GURL& url);
|
| + void OnMsgDidRedirectProvisionalLoad(int32 page_id,
|
| + const GURL& source_url,
|
| + const GURL& target_url);
|
| + void OnMsgDidFailProvisionalLoadWithError(int64 frame_id,
|
| + bool main_frame,
|
| + int error_code,
|
| + const GURL& url,
|
| + bool showing_repost_interstitial);
|
| + void OnMsgDidLoadResourceFromMemoryCache(const GURL& url,
|
| + const std::string& security_info);
|
| + void OnMsgDidDisplayInsecureContent();
|
| + void OnMsgDidRunInsecureContent(const std::string& security_origin,
|
| + const GURL& target_url);
|
| + void OnMsgDocumentLoadedInFrame(int64 frame_id);
|
| + void OnMsgDidFinishLoad(int64 frame_id);
|
| + void OnMsgUpdateContentRestrictions(int restrictions);
|
| void OnMsgDocumentAvailableInMainFrame();
|
| void OnMsgDocumentOnLoadCompletedInMainFrame(int32 page_id);
|
| void OnMsgUpdateFaviconURL(int32 page_id, const GURL& icon_url);
|
| @@ -575,6 +606,7 @@ class RenderViewHost : public RenderWidgetHost {
|
| void OnUpdateInspectorSetting(const std::string& key,
|
| const std::string& value);
|
| void OnMsgShouldCloseACK(bool proceed);
|
| + void OnMsgClosePageACK();
|
|
|
| void OnAccessibilityNotifications(
|
| const std::vector<ViewHostMsg_AccessibilityNotification_Params>& params);
|
| @@ -637,6 +669,10 @@ class RenderViewHost : public RenderWidgetHost {
|
| // navigation occurs.
|
| scoped_ptr<ViewMsg_Navigate> suspended_nav_message_;
|
|
|
| + // Whether this RenderViewHost is currently swapped out, such that the view is
|
| + // being rendered by another process.
|
| + bool is_swapped_out_;
|
| +
|
| // If we were asked to RunModal, then this will hold the reply_msg that we
|
| // must return to the renderer to unblock it.
|
| IPC::Message* run_modal_reply_msg_;
|
|
|