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

Unified Diff: content/browser/frame_host/render_frame_host_impl.cc

Issue 1014623002: Revert "Refactor sudden termination" (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase + fixed compilation error Created 5 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/frame_host/render_frame_host_impl.cc
diff --git a/content/browser/frame_host/render_frame_host_impl.cc b/content/browser/frame_host/render_frame_host_impl.cc
index 88bfbe0f663345f2fb6a063e50ed2e1fdd0c5eb6..a40518fd7de3d4b3cb9df4934887840db25902ad 100644
--- a/content/browser/frame_host/render_frame_host_impl.cc
+++ b/content/browser/frame_host/render_frame_host_impl.cc
@@ -149,9 +149,6 @@ RenderFrameHostImpl::RenderFrameHostImpl(SiteInstance* site_instance,
routing_id_(routing_id),
render_frame_created_(false),
navigations_suspended_(false),
- has_beforeunload_handlers_(false),
- has_unload_handlers_(false),
- override_sudden_termination_status_(false),
is_waiting_for_beforeunload_ack_(false),
unload_ack_is_for_navigation_(false),
is_loading_(false),
@@ -358,10 +355,6 @@ bool RenderFrameHostImpl::OnMessageReceived(const IPC::Message &msg) {
IPC_MESSAGE_HANDLER(FrameHostMsg_DocumentOnLoadCompleted,
OnDocumentOnLoadCompleted)
IPC_MESSAGE_HANDLER(FrameHostMsg_BeforeUnload_ACK, OnBeforeUnloadACK)
- IPC_MESSAGE_HANDLER(FrameHostMsg_BeforeUnloadHandlersPresent,
- OnBeforeUnloadHandlersPresent)
- IPC_MESSAGE_HANDLER(FrameHostMsg_UnloadHandlersPresent,
- OnUnloadHandlersPresent)
IPC_MESSAGE_HANDLER(FrameHostMsg_SwapOut_ACK, OnSwapOutACK)
IPC_MESSAGE_HANDLER(FrameHostMsg_ContextMenu, OnContextMenu)
IPC_MESSAGE_HANDLER(FrameHostMsg_JavaScriptExecuteResponse,
@@ -1053,11 +1046,6 @@ bool RenderFrameHostImpl::IsWaitingForUnloadACK() const {
rfh_state_ == STATE_PENDING_SWAP_OUT;
}
-bool RenderFrameHostImpl::SuddenTerminationAllowed() const {
- return override_sudden_termination_status_ ||
- (!has_beforeunload_handlers_ && !has_unload_handlers_);
-}
-
void RenderFrameHostImpl::OnSwapOutACK() {
OnSwappedOut();
}
@@ -1418,14 +1406,6 @@ void RenderFrameHostImpl::OnToggleFullscreen(bool enter_fullscreen) {
render_view_host_->WasResized();
}
-void RenderFrameHostImpl::OnBeforeUnloadHandlersPresent(bool present) {
- has_beforeunload_handlers_ = present;
-}
-
-void RenderFrameHostImpl::OnUnloadHandlersPresent(bool present) {
- has_unload_handlers_ = present;
-}
-
#if defined(OS_MACOSX) || defined(OS_ANDROID)
void RenderFrameHostImpl::OnShowPopup(
const FrameHostMsg_ShowPopup_Params& params) {
« no previous file with comments | « content/browser/frame_host/render_frame_host_impl.h ('k') | content/browser/renderer_host/render_process_host_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698