Skip to content

Commit

Permalink
use localBoundsProperty, #600
Browse files Browse the repository at this point in the history
  • Loading branch information
zepumph committed Jul 9, 2020
1 parent 611bcf9 commit 9757182
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions js/HomeScreenView.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,8 @@ function HomeScreenView( simNameProperty, model, tandem, options ) {
titleText.setText( simTitle );
} );

// Have this before adding the child to support the startup layout.
titleText.boundsProperty.link( () => {
// Have this before adding the child to support the startup layout. Use `localBoundsProperty` to avoid an infinite loop.
titleText.localBoundsProperty.link( () => {
titleText.centerX = this.layoutBounds.centerX;
} );

Expand Down

0 comments on commit 9757182

Please sign in to comment.