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

Unified Diff: chrome/browser/ui/unload_controller.cc

Issue 17382005: Unbreak tabs.onRemove extension API in face of fast tab closure Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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: chrome/browser/ui/unload_controller.cc
diff --git a/chrome/browser/ui/unload_controller.cc b/chrome/browser/ui/unload_controller.cc
index b52348c30ae25d9568f6c3ea1fb7967e96ca1f00..2a400fe0b0dcc42595ddc0c6c0374a1ea9a0ed82 100644
--- a/chrome/browser/ui/unload_controller.cc
+++ b/chrome/browser/ui/unload_controller.cc
@@ -220,6 +220,7 @@ bool UnloadController::DetachWebContents(content::WebContents* contents) {
if (index != TabStripModel::kNoTab &&
contents->NeedToFireBeforeUnload()) {
tabs_needing_unload_ack_.insert(contents);
+ contents->OnUnloadAboutToDetach();
browser_->tab_strip_model()->DetachWebContentsAt(index);
contents->SetDelegate(detached_delegate_.get());
contents->OnUnloadDetachedStarted();

Powered by Google App Engine
This is Rietveld 408576698