Commit de20dd46 authored by Francois Doray's avatar Francois Doray Committed by Commit Bot

RC: Allow a tab pending discard to be urgently discarded.

There is no reason to prevent this.

Change-Id: Ice12038054b3ffcbf1e165017a8c1238fb84670e
Reviewed-on: https://chromium-review.googlesource.com/c/1371934Reviewed-by: default avatarChris Hamilton <chrisha@chromium.org>
Commit-Queue: François Doray <fdoray@chromium.org>
Cr-Commit-Position: refs/heads/master@{#615906}
parent fe9784bb
......@@ -124,7 +124,9 @@ bool IsValidStateChange(LifecycleUnitState from,
// - The freeze timeout expires, or,
// - The renderer notifies the browser that the page has been frozen.
case LifecycleUnitState::DISCARDED:
return reason == StateChangeReason::BROWSER_INITIATED;
return reason == StateChangeReason::BROWSER_INITIATED ||
reason == StateChangeReason::SYSTEM_MEMORY_PRESSURE ||
reason == StateChangeReason::EXTENSION_INITIATED;
// The WebContents is focused.
case LifecycleUnitState::PENDING_FREEZE:
return reason == StateChangeReason::USER_INITIATED;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment