power-libperfmgr: Always wait after changing DOUBLE_TAP_TO_WAKE

This avoids that we enter a screen state where it doesn't react anymore
if you quickly turn off and on the screen.

Change-Id: I8d7fc756d1631e9f739dbe10554b58ba0c0c5576
tirimbino
Andreas Schneider 4 years ago
parent f53128d8d8
commit 0b60aa2746
  1. 3
      hidl/power-libperfmgr/Power.cpp

@ -194,7 +194,7 @@ Return<void> Power::setInteractive(bool interactive) {
// It takes some time till the cmd is executed in the Kernel, there
// is an interface to check that. To avoid that just wait for 25ms
// till we turn off the touchscreen and lcd.
std::this_thread::sleep_for(25ms);
std::this_thread::sleep_for(20ms);
}
updateHint("NOT_INTERACTIVE", !interactive);
@ -202,6 +202,7 @@ Return<void> Power::setInteractive(bool interactive) {
// Disable dt2w after turning TSP back on
if (mDoubleTapEnabled && interactive) {
updateHint("DOUBLE_TAP_TO_WAKE", false);
std::this_thread::sleep_for(10ms);
}
return Void();

Loading…
Cancel
Save