From 1897194e0ac8a49465c9c053a39cd9177dbb295c Mon Sep 17 00:00:00 2001 From: zepumph Date: Tue, 19 Nov 2019 15:47:12 -0900 Subject: [PATCH] add getter to Sim.js to access Display.prototype.utteranceQueue, https://github.com/phetsims/utterance-queue/issues/7 --- js/accessibility/AccessibleValueHandler.js | 2 +- sun_a11y_view.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/js/accessibility/AccessibleValueHandler.js b/js/accessibility/AccessibleValueHandler.js index 01e4de6a..9602f49e 100644 --- a/js/accessibility/AccessibleValueHandler.js +++ b/js/accessibility/AccessibleValueHandler.js @@ -348,7 +348,7 @@ define( require => { */ setUtteranceAndAlert() { if ( this.a11yCreateValueChangeAlert ) { - const utteranceQueue = phet.joist.sim.display.utteranceQueue; + const utteranceQueue = phet.joist.sim.utteranceQueue; this.endInteractionUtterance.resetTimingVariables(); diff --git a/sun_a11y_view.html b/sun_a11y_view.html index 203e59d0..f226b095 100644 --- a/sun_a11y_view.html +++ b/sun_a11y_view.html @@ -269,7 +269,7 @@

PDOM & Descriptions for sun demo

var PDOMCopy = PDOMRoot.cloneNode( true ); // get the alert dom elements from the iframe's inner document - var ariaLiveElementsContainer = innerWindow.phet.joist.sim.display.utteranceQueue.getAriaLiveContainer(); + var ariaLiveElementsContainer = innerWindow.phet.joist.sim.utteranceQueue.getAriaLiveContainer(); // get the alert dom elements from the PDOM copy var alertList = document.getElementById( 'alert-list' );