inputflinger: make parameter comment style consistent
The Google C++ style guide [0] suggests that parameter name comments
should be of the form `/*paramName=*/value`. This potentially allows
tooling to check that the parameter names are correct, too.
[0]: https://google.github.io/styleguide/cppguide.html#Function_Argument_Comments
Bug: none
Test: host-side inputflinger_tests
Change-Id: I89625844bcd19d27c43b4f14f1f207ade39a4718
diff --git a/services/inputflinger/benchmarks/InputDispatcher_benchmarks.cpp b/services/inputflinger/benchmarks/InputDispatcher_benchmarks.cpp
index 3d4dd7e..f03c837 100644
--- a/services/inputflinger/benchmarks/InputDispatcher_benchmarks.cpp
+++ b/services/inputflinger/benchmarks/InputDispatcher_benchmarks.cpp
@@ -141,7 +141,7 @@
ALOGE("Waited too long for consumer to produce an event, giving up");
break;
}
- result = mConsumer->consume(&mEventFactory, true /*consumeBatches*/, -1, &consumeSeq,
+ result = mConsumer->consume(&mEventFactory, /*consumeBatches=*/true, -1, &consumeSeq,
&event);
}
if (result != OK) {
@@ -308,13 +308,13 @@
for (auto _ : state) {
MotionEvent event = generateMotionEvent();
// Send ACTION_DOWN
- dispatcher.injectInputEvent(&event, {} /*targetUid*/, InputEventInjectionSync::NONE,
+ dispatcher.injectInputEvent(&event, /*targetUid=*/{}, InputEventInjectionSync::NONE,
INJECT_EVENT_TIMEOUT,
POLICY_FLAG_FILTERED | POLICY_FLAG_PASS_TO_USER);
// Send ACTION_UP
event.setAction(AMOTION_EVENT_ACTION_UP);
- dispatcher.injectInputEvent(&event, {} /*targetUid*/, InputEventInjectionSync::NONE,
+ dispatcher.injectInputEvent(&event, /*targetUid=*/{}, InputEventInjectionSync::NONE,
INJECT_EVENT_TIMEOUT,
POLICY_FLAG_FILTERED | POLICY_FLAG_PASS_TO_USER);
@@ -344,7 +344,7 @@
for (auto _ : state) {
dispatcher.onWindowInfosChanged(windowInfos, displayInfos);
- dispatcher.onWindowInfosChanged({} /*windowInfos*/, {} /*displayInfos*/);
+ dispatcher.onWindowInfosChanged(/*windowInfos=*/{}, /*displayInfos=*/{});
}
dispatcher.stop();
}