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

Unified Diff: ui/base/test/windowed_nsnotification_observer.mm

Issue 2054573002: Remove MessageLoop::current()->task_runner() in ui. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 6 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
« no previous file with comments | « ui/accelerated_widget_mac/display_link_mac.cc ('k') | ui/snapshot/screenshot_grabber.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/test/windowed_nsnotification_observer.mm
diff --git a/ui/base/test/windowed_nsnotification_observer.mm b/ui/base/test/windowed_nsnotification_observer.mm
index f5c1e667a6f00cf9950eed7d9ce9d6cec79a5d4c..622c8c7ac3832b0ef4dce99a44d1183dac2fd032 100644
--- a/ui/base/test/windowed_nsnotification_observer.mm
+++ b/ui/base/test/windowed_nsnotification_observer.mm
@@ -6,8 +6,11 @@
#import <Cocoa/Cocoa.h>
+#include "base/location.h"
#include "base/run_loop.h"
+#include "base/single_thread_task_runner.h"
#include "base/test/test_timeouts.h"
+#include "base/threading/thread_task_runner_handle.h"
@interface WindowedNSNotificationObserver ()
- (void)onNotification:(NSNotification*)notification;
@@ -69,7 +72,7 @@
while (notificationCount_ < minimumCount) {
const int oldCount = notificationCount_;
base::RunLoop runLoop;
- base::MessageLoop::current()->task_runner()->PostDelayedTask(
+ base::ThreadTaskRunnerHandle::Get()->PostDelayedTask(
FROM_HERE, runLoop.QuitClosure(), TestTimeouts::action_timeout());
runLoop_ = &runLoop;
runLoop.Run();
« no previous file with comments | « ui/accelerated_widget_mac/display_link_mac.cc ('k') | ui/snapshot/screenshot_grabber.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698