phetsims / color-vision

"Color Vision" is an educational simulation in HTML5, by PhET Interactive Simulations.
http://phet.colorado.edu/en/simulation/color-vision
GNU General Public License v3.0
1 stars 7 forks source link

Questions about utteranceQueue #122

Closed samreid closed 5 years ago

samreid commented 6 years ago

While exploring #121 I wanted to investigate having the sim say "the flashlight turned on" when the user presses the button. I added this code to SingleBulbScreenView.js constructor:

    model.flashlightOnProperty.link( function( flashlightOn ) {
      utteranceQueue.addToBack(flashlightOn ? 'The flashlight turned on.':'The flashlight turned off.');
    } );

With VoiceOver on, after it read through the initial pdom, I pushed the button several times, and then it said "the flashlight turned on" and "the flashlight turned off" several times, then would no longer say the message even if I kept pressing the button. Am I doing this correctly? Is there a bug or a misunderstanding of how this is supposed to behave?

jessegreenberg commented 6 years ago

@samreid I would expect it to say it once for every time you pressed the button. I tested the snippet in the original comment with Safari + VO and I hear it consistently. Were you using Safari or another browser? Did you happen to switch browser tabs? There is a VO bug where all alerts stop if you switch tabs.

samreid commented 6 years ago

I was using Chrome Version 66.0.3359.139 (Official Build) (64-bit) and did not switch tabs. Let me know if you can reproduce the problem on Mac/Chrome, or if you want me to try to reproduce the problem.

zepumph commented 6 years ago

For me, windows version 66.0.3359.139 (Official Build) (64-bit), I added that code to that file and it worked for me consistently. I switched tabs and it still worked as expected.

samreid commented 6 years ago

Were you using NVDA?

jessegreenberg commented 6 years ago

@samreid can you please try in Safari? Chrome is not a browser that we test with screen readers.

zepumph commented 6 years ago

Were you using NVDA?

I was using NVDA, sorry to leave that out.

@samreid can you please try in Safari? Chrome is not a browser that we test with screen readers.

I should have known better @jessegreenberg, my deepest and most regretful apologies. I should only use Firefox on windows with NVDA.

jessegreenberg commented 6 years ago

Still good to know @zepumph, makes a good data point!

ariel-phet commented 6 years ago

Removing @samreid assignment for now, as color vision isn't scheduled for work at the moment

pixelzoom commented 5 years ago

@jessegreenberg can this be closed, and/or promoted to a common-code issue? It doesn't seem specific to color-vision.

jessegreenberg commented 5 years ago

This can be closed, utteranceQueue has received many changes since this issue, and recently went through QA testing in https://github.com/phetsims/QA/issues/208