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

Unified Diff: chrome/browser/apps/app_launch_for_metro_restart_win.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/apps/app_launch_for_metro_restart_win.cc
diff --git a/chrome/browser/apps/app_launch_for_metro_restart_win.cc b/chrome/browser/apps/app_launch_for_metro_restart_win.cc
index 38b891a0f64d1c8d72e006ebe841de0f32dd8a77..978e1e274aa7c2a7d68b31e597eabdb9f2c4c434 100644
--- a/chrome/browser/apps/app_launch_for_metro_restart_win.cc
+++ b/chrome/browser/apps/app_launch_for_metro_restart_win.cc
@@ -7,7 +7,9 @@
#include "apps/launcher.h"
#include "base/bind.h"
#include "base/files/file_path.h"
-#include "base/message_loop/message_loop.h"
+#include "base/location.h"
+#include "base/single_thread_task_runner.h"
+#include "base/threading/thread_task_runner_handle.h"
#include "base/time/time.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/extensions/extension_service.h"
@@ -72,9 +74,8 @@ void HandleAppLaunchForMetroRestart(Profile* profile) {
prefs->ClearPref(prefs::kAppLaunchForMetroRestart);
const int kRestartAppLaunchDelayMs = 1000;
- base::MessageLoop::current()->PostDelayedTask(
- FROM_HERE,
- base::Bind(&LaunchAppWithId, profile, extension_id),
+ base::ThreadTaskRunnerHandle::Get()->PostDelayedTask(
+ FROM_HERE, base::Bind(&LaunchAppWithId, profile, extension_id),
base::TimeDelta::FromMilliseconds(kRestartAppLaunchDelayMs));
}
« no previous file with comments | « chrome/browser/android/feedback/connectivity_checker.cc ('k') | chrome/browser/apps/app_shim/app_shim_handler_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698