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

Unified Diff: content/renderer/render_thread_impl.cc

Issue 2132593002: Remove remaining calls to deprecated MessageLoop methods on Mac. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: CR gab Created 4 years, 5 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: content/renderer/render_thread_impl.cc
diff --git a/content/renderer/render_thread_impl.cc b/content/renderer/render_thread_impl.cc
index 0845883e185e198d5d91837bd9fae4da9262772c..0ad6a49cead59a9d988b117a5d2468c46d653924 100644
--- a/content/renderer/render_thread_impl.cc
+++ b/content/renderer/render_thread_impl.cc
@@ -14,7 +14,6 @@
#include "base/command_line.h"
#include "base/debug/crash_logging.h"
#include "base/lazy_instance.h"
-#include "base/location.h"
#include "base/logging.h"
#include "base/macros.h"
#include "base/memory/discardable_memory_allocator.h"
@@ -23,7 +22,7 @@
#include "base/metrics/field_trial.h"
#include "base/metrics/histogram.h"
#include "base/path_service.h"
-#include "base/single_thread_task_runner.h"
+#include "base/run_loop.h"
#include "base/strings/string16.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/string_split.h"
@@ -955,13 +954,14 @@ void RenderThreadImpl::Shutdown() {
ChildThreadImpl::Shutdown();
- // Shut down the message loop and the renderer scheduler before shutting down
- // Blink. This prevents a scenario where a pending task in the message loop
- // accesses Blink objects after Blink shuts down.
+ // Shut down the message loop (if provided when the RenderThreadImpl was
+ // constructed) and the renderer scheduler before shutting down Blink. This
+ // prevents a scenario where a pending task in the message loop accesses Blink
+ // objects after Blink shuts down.
renderer_scheduler_->SetRAILModeObserver(nullptr);
renderer_scheduler_->Shutdown();
if (main_message_loop_)
- main_message_loop_->RunUntilIdle();
+ base::RunLoop().RunUntilIdle();
if (blink_platform_impl_) {
blink_platform_impl_->Shutdown();

Powered by Google App Engine
This is Rietveld 408576698