Remove InputChannel::setToken
The token is now assigned in the constructor. It is read-only. When you
open inputchannelpair, the same token is assigned to both server and client
side channels.
Bug: 142581626
Test: presubmit
Change-Id: I603603844b41f478e244b89dcdd1dab7e6260347
diff --git a/libs/gui/tests/EndToEndNativeInputTest.cpp b/libs/gui/tests/EndToEndNativeInputTest.cpp
index 03b9cd7..8d36ba7 100644
--- a/libs/gui/tests/EndToEndNativeInputTest.cpp
+++ b/libs/gui/tests/EndToEndNativeInputTest.cpp
@@ -69,7 +69,6 @@
mSurfaceControl = sc;
InputChannel::openInputChannelPair("testchannels", mServerChannel, mClientChannel);
- mServerChannel->setToken(new BBinder());
mInputFlinger = getInputFlinger();
mInputFlinger->registerInputChannel(mServerChannel);
@@ -165,7 +164,7 @@
}
void populateInputInfo(int width, int height) {
- mInputInfo.token = mServerChannel->getToken();
+ mInputInfo.token = mServerChannel->getConnectionToken();
mInputInfo.name = "Test info";
mInputInfo.layoutParamsFlags = InputWindowInfo::FLAG_NOT_TOUCH_MODAL;
mInputInfo.layoutParamsType = InputWindowInfo::TYPE_BASE_APPLICATION;