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

Unified Diff: android_webview/browser/test/fake_window.cc

Issue 2041033003: clang-tidy WaitableEvent refactor (Android side) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@0_windows
Patch Set: 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 | « android_webview/browser/aw_form_database_service.cc ('k') | android_webview/native/cookie_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: android_webview/browser/test/fake_window.cc
diff --git a/android_webview/browser/test/fake_window.cc b/android_webview/browser/test/fake_window.cc
index f970ec3f616cf14829e6aae44d8a32ea94ae1e3f..52266ecc24438a1f5b8abab778fa4470199c4bd4 100644
--- a/android_webview/browser/test/fake_window.cc
+++ b/android_webview/browser/test/fake_window.cc
@@ -61,7 +61,9 @@ FakeWindow::FakeWindow(BrowserViewRenderer* view,
FakeWindow::~FakeWindow() {
CheckCurrentlyOnUIThread();
if (render_thread_loop_) {
- base::WaitableEvent completion(true, false);
+ base::WaitableEvent completion(
+ base::WaitableEvent::ResetPolicy::MANUAL,
+ base::WaitableEvent::InitialState::NOT_SIGNALED);
render_thread_loop_->PostTask(
FROM_HERE, base::Bind(&FakeWindow::DestroyOnRT, base::Unretained(this),
&completion));
@@ -79,7 +81,9 @@ void FakeWindow::Detach() {
void FakeWindow::RequestInvokeGL(FakeFunctor* functor,
bool wait_for_completion) {
CheckCurrentlyOnUIThread();
- base::WaitableEvent completion(true, false);
+ base::WaitableEvent completion(
+ base::WaitableEvent::ResetPolicy::MANUAL,
+ base::WaitableEvent::InitialState::NOT_SIGNALED);
render_thread_loop_->PostTask(
FROM_HERE,
base::Bind(&FakeWindow::InvokeFunctorOnRT, base::Unretained(this),
@@ -127,7 +131,9 @@ void FakeWindow::OnDrawHardware() {
if (success && functor) {
CreateRenderThreadIfNeeded();
- base::WaitableEvent completion(true, false);
+ base::WaitableEvent completion(
+ base::WaitableEvent::ResetPolicy::MANUAL,
+ base::WaitableEvent::InitialState::NOT_SIGNALED);
render_thread_loop_->PostTask(
FROM_HERE, base::Bind(&FakeWindow::DrawFunctorOnRT,
base::Unretained(this), functor, &completion));
@@ -169,7 +175,9 @@ void FakeWindow::CreateRenderThreadIfNeeded() {
render_thread_loop_ = render_thread_->task_runner();
rt_checker_.DetachFromSequence();
- base::WaitableEvent completion(true, false);
+ base::WaitableEvent completion(
+ base::WaitableEvent::ResetPolicy::MANUAL,
+ base::WaitableEvent::InitialState::NOT_SIGNALED);
render_thread_loop_->PostTask(
FROM_HERE, base::Bind(&FakeWindow::InitializeOnRT, base::Unretained(this),
&completion));
« no previous file with comments | « android_webview/browser/aw_form_database_service.cc ('k') | android_webview/native/cookie_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698