phetsims / utterance-queue

Alerting library powered by aria-live
MIT License
0 stars 2 forks source link

Don't step SpeechSynthesisAnnouncer if it is disabled? #76

Open jessegreenberg opened 2 years ago

jessegreenberg commented 2 years ago

We might be doing unecessary operations when Voicing/SpeechSynthesis is not enabled by stepping in this case.

The UtteranceQueue returns in step if not enabled. Maybe we can/should do the same for SpeechSynthesisAnnouncer. The UtteranceQueue used to step the SpeechSynthesisAnnouncer, so this actually seems like a safe thing to do after we moved the announcer.step call out of the UTteranceQueue in #71.

zepumph commented 2 years ago

Perhaps in addition to this, we should add a listener that applies to chromium wake engine workaround to speak an empty string right when we enable, so that it doesn't interfere with that on chromium.