Skip to content

Commit

Permalink
voicing and pdom visibility for modal dialogs should be handled in th…
Browse files Browse the repository at this point in the history
  • Loading branch information
zepumph committed Oct 7, 2022
1 parent ea6b914 commit 62254f0
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions js/Dialog.ts
Original file line number Diff line number Diff line change
Expand Up @@ -364,21 +364,13 @@ export default class Dialog extends Popupable( Panel, 1 ) {
// sound generation
options.openedSoundPlayer.play();

// pdom - modal dialogs should be the only readable content in the sim
// TODO: https://github.com/phetsims/joist/issues/293 non-modal dialogs shouldn't hide other accessible content,
// and this should be dependant on other things in the sim modalNodeStack
this.sim.setAccessibleViewsVisible( false );

// Do this last
options.showCallback && options.showCallback();
}
else {
// sound generation
options.closedSoundPlayer.play();

// pdom - when the dialog is hidden, make all ScreenView content visible to assistive technology
this.sim.setAccessibleViewsVisible( true );

// Do this last
options.hideCallback && options.hideCallback();
}
Expand Down

0 comments on commit 62254f0

Please sign in to comment.