summaryrefslogtreecommitdiff
path: root/libs/gui/tests/EndToEndNativeInputTest.cpp
diff options
context:
space:
mode:
authorVishnu Nair <vishnun@google.com>2021-01-15 12:55:14 -0800
committerVishnu Nair <vishnun@google.com>2021-01-15 13:53:19 -0800
commit9ad01462a742d3b44fd4258bc794f99b130ef73a (patch)
treee1ec004fef1069cb8fc14beb5215d1a542c36b43 /libs/gui/tests/EndToEndNativeInputTest.cpp
parent88ce0fa5e59d2b19ece38708672baebbc4a19bc0 (diff)
Pass in window name along with focus request
Used for generating focus event logs and debug logs. Test: go/wm-smoke, check event logs and logcat Change-Id: I7d96c706ea350ec122c254fb4c327756e8267df5
Diffstat (limited to 'libs/gui/tests/EndToEndNativeInputTest.cpp')
-rw-r--r--libs/gui/tests/EndToEndNativeInputTest.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/libs/gui/tests/EndToEndNativeInputTest.cpp b/libs/gui/tests/EndToEndNativeInputTest.cpp
index 3965ea0fdb..31cbbdc75c 100644
--- a/libs/gui/tests/EndToEndNativeInputTest.cpp
+++ b/libs/gui/tests/EndToEndNativeInputTest.cpp
@@ -202,8 +202,14 @@ public:
void requestFocus() {
SurfaceComposerClient::Transaction t;
- t.setFocusedWindow(mInputInfo.token, nullptr, systemTime(SYSTEM_TIME_MONOTONIC),
- 0 /* displayId */);
+ FocusRequest request;
+ request.token = mInputInfo.token;
+ request.windowName = mInputInfo.name;
+ request.focusedToken = nullptr;
+ request.focusedWindowName = "";
+ request.timestamp = systemTime(SYSTEM_TIME_MONOTONIC);
+ request.displayId = 0;
+ t.setFocusedWindow(request);
t.apply(true);
}