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

Unified Diff: chrome/browser/profiles/profile_window.cc

Issue 2033753002: Remove use of deprecated MessageLoop methods in chrome/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: manual change Created 4 years, 7 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/profiles/profile_window.cc
diff --git a/chrome/browser/profiles/profile_window.cc b/chrome/browser/profiles/profile_window.cc
index 9ed0f49bb4aa0aa942a5305a1907ce8a0b20609a..935892cd64799e3ab5d45b6255030ff9a259fb51 100644
--- a/chrome/browser/profiles/profile_window.cc
+++ b/chrome/browser/profiles/profile_window.cc
@@ -11,9 +11,12 @@
#include "base/command_line.h"
#include "base/files/file_path.h"
+#include "base/location.h"
#include "base/macros.h"
+#include "base/single_thread_task_runner.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/utf_string_conversions.h"
+#include "base/threading/thread_task_runner_handle.h"
#include "build/build_config.h"
#include "chrome/browser/about_flags.h"
#include "chrome/browser/browser_process.h"
@@ -104,10 +107,10 @@ class BrowserAddedForProfileObserver : public chrome::BrowserListObserver {
// By the time the browser is added a tab (or multiple) are about to be
// added. Post the callback to the message loop so it gets executed after
// the tabs are created.
- base::MessageLoop::current()->PostTask(
+ base::ThreadTaskRunnerHandle::Get()->PostTask(
FROM_HERE,
base::Bind(callback_, profile_, Profile::CREATE_STATUS_INITIALIZED));
- base::MessageLoop::current()->DeleteSoon(FROM_HERE, this);
+ base::ThreadTaskRunnerHandle::Get()->DeleteSoon(FROM_HERE, this);
}
}

Powered by Google App Engine
This is Rietveld 408576698