Chromium Code Reviews
DescriptionRemove MessageLoop::current()->task_runner() in ui.
This CL replaces MessageLoop::current()->task_runner() with
ThreadTaskRunnerHandle::Get() in ui.
In files where this replacement is made, it adds these include:
#include "base/threading/thread_task_runner_handle.h"
#include "base/location.h" (if required)
#include "base/single_thread_task_runner.h" (if required)
And removes this include if it is no longer required:
#include "base/message_loop/message_loop.h"
Why?
The fact that there's a MessageLoop on the thread is an
unnecessary implementation detail. When browser threads
are migrated to base/task_scheduler, tasks will no longer
have access to a MessageLoop but they will have access to
a ThreadTaskRunnerHandle.
Steps to generate this patch:
1. Run message_loop_cleanup_2.py (see code on the bug).
2. Run tools/sort-headers.py on modified files.
3. Run git cl format.
BUG=616447
R=thakis@chromium.org
Committed: https://crrev.com/13b955d465a1e4ce91961710091c7707f38a9d98
Cr-Commit-Position: refs/heads/master@{#399739}
Patch Set 1 #Patch Set 2 : rebase #
Messages
Total messages: 12 (4 generated)
|
||||||||||||||||||||||||||||||||||||||||||||||