Skip to content

Commit

Permalink
Rename timer => stepTimer, see phetsims/axon#329
Browse files Browse the repository at this point in the history
  • Loading branch information
samreid committed Sep 11, 2020
1 parent 09e8256 commit bb85cb4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions js/Carousel.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*/

import Property from '../../axon/js/Property.js';
import timer from '../../axon/js/timer.js';
import stepTimer from '../../axon/js/stepTimer.js';
import Dimension2 from '../../dot/js/Dimension2.js';
import Utils from '../../dot/js/Utils.js';
import Shape from '../../kite/js/Shape.js';
Expand Down Expand Up @@ -72,7 +72,7 @@ const DEFAULT_OPTIONS = {
// animation, scrolling between pages
animationEnabled: true, // {boolean} is animation enabled when scrolling between pages?,
animationDuration: 0.4, // {number} seconds
stepEmitter: timer, // {string} see Animation options.stepEmitter
stepEmitter: stepTimer, // {string} see Animation options.stepEmitter

// phet-io
tandem: Tandem.OPTIONAL
Expand Down
6 changes: 3 additions & 3 deletions js/demo/ComponentsScreenView.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
import BooleanProperty from '../../../axon/js/BooleanProperty.js';
import Property from '../../../axon/js/Property.js';
import StringProperty from '../../../axon/js/StringProperty.js';
import timer from '../../../axon/js/timer.js';
import stepTimer from '../../../axon/js/stepTimer.js';
import Dimension2 from '../../../dot/js/Dimension2.js';
import Range from '../../../dot/js/Range.js';
import inherit from '../../../phet-core/js/inherit.js';
Expand Down Expand Up @@ -530,7 +530,7 @@ var demoAlignGroup = function( layoutBounds ) {
const randomRect = new Rectangle( 0, 0, phet.joist.random.nextDouble() * 60 + 10, phet.joist.random.nextDouble() * 60 + 10, {
fill: 'black'
} );
timer.addListener( function() {
stepTimer.addListener( function() {
if ( phet.joist.random.nextDouble() < 0.02 ) {
randomRect.rectWidth = phet.joist.random.nextDouble() * 60 + 10;
randomRect.rectHeight = phet.joist.random.nextDouble() * 60 + 10;
Expand All @@ -547,7 +547,7 @@ var demoAlignGroup = function( layoutBounds ) {

function randomText() {
const text = new Text( 'Test', { fontSize: 20 } );
timer.addListener( function() {
stepTimer.addListener( function() {
if ( phet.joist.random.nextDouble() < 0.03 ) {
let string = '';
while ( phet.joist.random.nextDouble() < 0.94 && string.length < 20 ) {
Expand Down

0 comments on commit bb85cb4

Please sign in to comment.