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

Unified Diff: ui/views/mus/views_mus_test_suite.cc

Issue 2027323002: Migrate WaitableEvent to enum-based constructor in ui/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@WEvent_enums
Patch Set: Created 4 years, 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/mus/views_mus_test_suite.cc
diff --git a/ui/views/mus/views_mus_test_suite.cc b/ui/views/mus/views_mus_test_suite.cc
index 8290d54ef78bafcc0665b749805f1562cfe9abbd..c709f9dcb4b86c72b80801582d80ab2ec03f5c3d 100644
--- a/ui/views/mus/views_mus_test_suite.cc
+++ b/ui/views/mus/views_mus_test_suite.cc
@@ -67,7 +67,8 @@ std::unique_ptr<PlatformTestHelper> CreatePlatformTestHelper(
class ShellConnection {
public:
ShellConnection() : thread_("Persistent shell connections") {
- base::WaitableEvent wait(false, false);
+ base::WaitableEvent wait(base::WaitableEvent::ResetPolicy::AUTOMATIC,
sky 2016/06/01 19:18:35 Did you consider making WaitableEvent take a bitma
gab 2016/06/01 19:50:30 Copied your suggestion on bug, danakj prefers the
+ base::WaitableEvent::InitialState::NOT_SIGNALED);
base::Thread::Options options;
thread_.StartWithOptions(options);
thread_.task_runner()->PostTask(
@@ -87,7 +88,8 @@ class ShellConnection {
~ShellConnection() {
if (views::WindowManagerConnection::Exists())
views::WindowManagerConnection::Reset();
- base::WaitableEvent wait(false, false);
+ base::WaitableEvent wait(base::WaitableEvent::ResetPolicy::AUTOMATIC,
+ base::WaitableEvent::InitialState::NOT_SIGNALED);
thread_.task_runner()->PostTask(
FROM_HERE, base::Bind(&ShellConnection::TearDownConnections,
base::Unretained(this), &wait));
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698