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

Side by Side Diff: chrome/browser/chromeos/login/lock/screen_locker_tester.cc

Issue 1395103003: Don't use base::MessageLoop::{Quit,QuitClosure} in chrome/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 2 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/chromeos/login/lock/screen_locker_tester.h" 5 #include "chrome/browser/chromeos/login/lock/screen_locker_tester.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/strings/string_util.h" 9 #include "base/strings/string_util.h"
10 #include "base/strings/stringprintf.h" 10 #include "base/strings/stringprintf.h"
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 waiting_ = true; 75 waiting_ = true;
76 content::RunMessageLoop(); 76 content::RunMessageLoop();
77 waiting_ = false; 77 waiting_ = false;
78 } 78 }
79 ASSERT_TRUE(login_attempted_); 79 ASSERT_TRUE(login_attempted_);
80 } 80 }
81 81
82 void LoginAttemptObserver::LoginAttempted() { 82 void LoginAttemptObserver::LoginAttempted() {
83 login_attempted_ = true; 83 login_attempted_ = true;
84 if (waiting_) 84 if (waiting_)
85 base::MessageLoopForUI::current()->Quit(); 85 base::MessageLoopForUI::current()->QuitWhenIdle();
86 } 86 }
87 87
88 } // anyonymous namespace 88 } // anyonymous namespace
89 89
90 namespace chromeos { 90 namespace chromeos {
91 91
92 namespace test { 92 namespace test {
93 93
94 class WebUIScreenLockerTester : public ScreenLockerTester { 94 class WebUIScreenLockerTester : public ScreenLockerTester {
95 public: 95 public:
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
209 new FakeExtendedAuthenticator(ScreenLocker::screen_locker_, user_context); 209 new FakeExtendedAuthenticator(ScreenLocker::screen_locker_, user_context);
210 } 210 }
211 211
212 } // namespace test 212 } // namespace test
213 213
214 test::ScreenLockerTester* ScreenLocker::GetTester() { 214 test::ScreenLockerTester* ScreenLocker::GetTester() {
215 return new test::WebUIScreenLockerTester(); 215 return new test::WebUIScreenLockerTester();
216 } 216 }
217 217
218 } // namespace chromeos 218 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698