diff --git a/js/buoyancy/view/BuoyancyLabScreenView.ts b/js/buoyancy/view/BuoyancyLabScreenView.ts index e5261008..485c7339 100644 --- a/js/buoyancy/view/BuoyancyLabScreenView.ts +++ b/js/buoyancy/view/BuoyancyLabScreenView.ts @@ -81,6 +81,8 @@ export default class BuoyancyLabScreenView extends DensityBuoyancyScreenView fluidDisplacedAccordionBox.expandedProperty.reset() ); + const leftSideVBox = new VBox( { align: 'left', spacing: 5, diff --git a/js/common/view/DensityBuoyancyScreenView.ts b/js/common/view/DensityBuoyancyScreenView.ts index 490cceef..7dfb43f9 100644 --- a/js/common/view/DensityBuoyancyScreenView.ts +++ b/js/common/view/DensityBuoyancyScreenView.ts @@ -65,6 +65,7 @@ import DuckView from '../../buoyancy/view/DuckView.js'; import NumberIO from '../../../../tandem/js/types/NumberIO.js'; import Utils from '../../../../dot/js/Utils.js'; import createObservableArray, { ObservableArray } from '../../../../axon/js/createObservableArray.js'; +import Emitter from '../../../../axon/js/Emitter.js'; // constants const MARGIN = DensityBuoyancyCommonConstants.MARGIN; @@ -114,6 +115,9 @@ export default class DensityBuoyancyScreenView; + // Called upon resetting + protected readonly resetEmitter = new Emitter(); + public constructor( model: Model, providedOptions: SelfOptions ) { const scaleIncrease = 3.5; @@ -574,6 +578,7 @@ export default class DensityBuoyancyScreenView { this.interruptSubtreeInput(); model.reset(); + this.resetEmitter.emit(); }, tandem: tandem.createTandem( 'resetAllButton' ) } );