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

Unified Diff: ppapi/proxy/ppapi_proxy_test.cc

Issue 2027313002: Migrate WaitableEvent to enum-based constructor in ppapi/ (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 | « ppapi/host/resource_message_filter_unittest.cc ('k') | ppapi/proxy/ppp_instance_proxy_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/proxy/ppapi_proxy_test.cc
diff --git a/ppapi/proxy/ppapi_proxy_test.cc b/ppapi/proxy/ppapi_proxy_test.cc
index fab1e0c7187099d499e5aa29089785b9ca394812..46d7a4ada77f4b615c6589ba70c3f1c8753ed003 100644
--- a/ppapi/proxy/ppapi_proxy_test.cc
+++ b/ppapi/proxy/ppapi_proxy_test.cc
@@ -527,8 +527,10 @@ TwoWayTest::TwoWayTest(TwoWayTest::TwoWayTestMode test_mode)
plugin_thread_("TwoWayTest_PluginThread"),
remote_harness_(NULL),
local_harness_(NULL),
- channel_created_(true, false),
- shutdown_event_(true, false) {
+ channel_created_(base::WaitableEvent::ResetPolicy::MANUAL,
+ base::WaitableEvent::InitialState::NOT_SIGNALED),
+ shutdown_event_(base::WaitableEvent::ResetPolicy::MANUAL,
+ base::WaitableEvent::InitialState::NOT_SIGNALED) {
if (test_mode == TEST_PPP_INTERFACE) {
remote_harness_ = &plugin_;
local_harness_ = &host_;
@@ -553,7 +555,9 @@ void TwoWayTest::SetUp() {
std::ostringstream handle_name;
handle_name << "TwoWayTestChannel" << base::GetCurrentProcId();
IPC::ChannelHandle handle(handle_name.str());
- base::WaitableEvent remote_harness_set_up(true, false);
+ base::WaitableEvent remote_harness_set_up(
+ base::WaitableEvent::ResetPolicy::MANUAL,
+ base::WaitableEvent::InitialState::NOT_SIGNALED);
plugin_thread_.task_runner()->PostTask(
FROM_HERE, base::Bind(&SetUpRemoteHarness, remote_harness_, handle,
base::RetainedRef(io_thread_.task_runner()),
@@ -565,7 +569,9 @@ void TwoWayTest::SetUp() {
}
void TwoWayTest::TearDown() {
- base::WaitableEvent remote_harness_torn_down(true, false);
+ base::WaitableEvent remote_harness_torn_down(
+ base::WaitableEvent::ResetPolicy::MANUAL,
+ base::WaitableEvent::InitialState::NOT_SIGNALED);
plugin_thread_.task_runner()->PostTask(
FROM_HERE, base::Bind(&TearDownRemoteHarness, remote_harness_,
&remote_harness_torn_down));
@@ -577,7 +583,9 @@ void TwoWayTest::TearDown() {
}
void TwoWayTest::PostTaskOnRemoteHarness(const base::Closure& task) {
- base::WaitableEvent task_complete(true, false);
+ base::WaitableEvent task_complete(
+ base::WaitableEvent::ResetPolicy::MANUAL,
+ base::WaitableEvent::InitialState::NOT_SIGNALED);
plugin_thread_.task_runner()->PostTask(
FROM_HERE, base::Bind(&RunTaskOnRemoteHarness, task, &task_complete));
task_complete.Wait();
« no previous file with comments | « ppapi/host/resource_message_filter_unittest.cc ('k') | ppapi/proxy/ppp_instance_proxy_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698