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

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

Issue 1160073004: chrome/browser/ui: Remove use of MessageLoopProxy and deprecated MessageLoop APIs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Check for task runner instead of current message loop. Created 5 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/fast_unload_controller.cc
diff --git a/chrome/browser/ui/fast_unload_controller.cc b/chrome/browser/ui/fast_unload_controller.cc
index 0a669ef25fec0847058cfa5168488d5bf8d1d81a..d89b21d283ea33c71f340f1eff0b40518b3a2e0c 100644
--- a/chrome/browser/ui/fast_unload_controller.cc
+++ b/chrome/browser/ui/fast_unload_controller.cc
@@ -4,8 +4,10 @@
#include "chrome/browser/ui/fast_unload_controller.h"
+#include "base/location.h"
#include "base/logging.h"
-#include "base/message_loop/message_loop.h"
+#include "base/single_thread_task_runner.h"
+#include "base/thread_task_runner_handle.h"
#include "chrome/browser/chrome_notification_types.h"
#include "chrome/browser/devtools/devtools_window.h"
#include "chrome/browser/ui/browser.h"
@@ -473,10 +475,9 @@ void FastUnloadController::ClearUnloadState(content::WebContents* contents) {
}
void FastUnloadController::PostTaskForProcessPendingTabs() {
- base::MessageLoop::current()->PostTask(
- FROM_HERE,
- base::Bind(&FastUnloadController::ProcessPendingTabs,
- weak_factory_.GetWeakPtr()));
+ base::ThreadTaskRunnerHandle::Get()->PostTask(
+ FROM_HERE, base::Bind(&FastUnloadController::ProcessPendingTabs,
+ weak_factory_.GetWeakPtr()));
}
} // namespace chrome

Powered by Google App Engine
This is Rietveld 408576698