Add Pause and Resume in Select to Speak
This CL partially implements the Pause and Resume feature in STS. It can only pause or resume at a user-selected region, without automatically continuing reading outside user-selected content. I will add the auto-continue feature and tests in a follow up CL. To enable this feature: 1. When pause triggered, we simply stop the current TTS. When resume triggered, we use startCurrentNodeGroup_ to read from the current index. 2. Refactored the update functions of floating panel. Creating one function (i.e.,updateNavigationPanel_) that updates the visibility and position of the panel. AX-Relnotes: When #select-to-speak-navigation-control chrome://flag enabled, when Select-to-speak is activated and speaking, pressing pause will pause the audio and resume will continue from the last stop position. Bug: 1143817 Change-Id: I4b28dfdfe1724e2b7cf138587d0b8818b7172966 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2558981 Commit-Queue: Lei Shi <leileilei@google.com> Reviewed-by:Dominic Mazzoni <dmazzoni@chromium.org> Reviewed-by:
Akihiro Ota <akihiroota@chromium.org> Cr-Commit-Position: refs/heads/master@{#834423}
Showing
Please register or sign in to comment