mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-19 18:58:19 +00:00
Previously this used the content description which was generally the same as the displayed text with whitespace adjustments + additional text (e.g. "Play Store has 7 notifications"). That worked fine, but I thought it would be a bit more robust to work with the text directly. Specifically, we consider it a match if all of the non-whitespace characters are there, along with optional added whitespace between characters. See TaplUtilityTests for examples. More importantly for the other change in this topic, this Pattern is also used for search result icons, to allow those tests to pass with multiline labels enabled. Bug: 315053839 Flag: LEGACY ENABLE_TWOLINE_DEVICESEARCH ENABLED Test: Manual and TaplTestsTaskbarSearch + other unit tests Change-Id: I4ad52840d743f06576d415f4e5ea6d8870e5dd2c