Commit cecb363d authored by Gabriel Charette's avatar Gabriel Charette Committed by Commit Bot

Migrate MessageLoop::current() to MessageLoopCurrent in...

Migrate MessageLoop::current() to MessageLoopCurrent in /chrome/browser/app_controller_mac_browsertest.mm

These changes were scripted as part of the effort to restrict exposure of the
raw MessageLoop*.

Note that many static methods exposed on MessageLoopCurrent are also deprecated
so it is very well possible that this is migrating to an already deprecated
method.

The goal of this pass is to reduce usage of MessageLoop::current() (and
ultimately make it impossible to obtain the MessageLoop* statically).

As such I will not edit this CL unless the script did something logically wrong.
I defer to owners to fix highlighted usage of already deprecated APIs.

Possible script screw ups / things to look out for in this review:
 - Storing MessageLoopCurrent in a MessageLoop* variable or comparing it against
   one (I will go over that in a separate pass).

Includes should have been stripped if that was the last usage of message_loop.h
in that file.

Please CQ if LGTY

This CL was uploaded by git cl split.

TBR=thakis@chromium.org

Bug: 825327
Change-Id: I6aa4991f252ab4079f061f967d142a827c0a7c52
Reviewed-on: https://chromium-review.googlesource.com/1024801Reviewed-by: default avatarGabriel Charette <gab@chromium.org>
Commit-Queue: Gabriel Charette <gab@chromium.org>
Cr-Commit-Position: refs/heads/master@{#553638}
parent 36bac5b0
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
#include "base/command_line.h" #include "base/command_line.h"
#include "base/mac/foundation_util.h" #include "base/mac/foundation_util.h"
#include "base/mac/scoped_nsobject.h" #include "base/mac/scoped_nsobject.h"
#include "base/message_loop/message_loop.h" #include "base/message_loop/message_loop_current.h"
#include "base/run_loop.h" #include "base/run_loop.h"
#include "base/strings/sys_string_conversions.h" #include "base/strings/sys_string_conversions.h"
#include "base/strings/utf_string_conversions.h" #include "base/strings/utf_string_conversions.h"
...@@ -293,7 +293,7 @@ void CreateProfileCallback(const base::Closure& quit_closure, ...@@ -293,7 +293,7 @@ void CreateProfileCallback(const base::Closure& quit_closure,
void CreateAndWaitForSystemProfile() { void CreateAndWaitForSystemProfile() {
ProfileManager::CreateCallback create_callback = ProfileManager::CreateCallback create_callback =
base::Bind(&CreateProfileCallback, base::Bind(&CreateProfileCallback,
base::MessageLoop::current()->QuitWhenIdleClosure()); base::MessageLoopCurrent::Get()->QuitWhenIdleClosure());
g_browser_process->profile_manager()->CreateProfileAsync( g_browser_process->profile_manager()->CreateProfileAsync(
ProfileManager::GetSystemProfilePath(), ProfileManager::GetSystemProfilePath(),
create_callback, create_callback,
......
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