phetsims / projectile-motion

"Projectile Motion" is an educational simulation in HTML5, by PhET Interactive Simulations.
GNU General Public License v3.0
16 stars 13 forks source link

Use TimeControlNode for Play/Pause/Step buttons #216

Closed jessegreenberg closed 4 years ago

jessegreenberg commented 4 years ago

From phetsims/scenery-phet#561. A scenery-phet/TimeControlNode was created that combines the PlayPauseButton and StepForwardButton and includes PhET-iO and PDOM instrumentation. It should be used in this sim. Assigning to responsible dev.

zepumph commented 4 years ago

I can do this since I'm in this repo right now for PhET-iO

kathy-phet commented 4 years ago

We are looking at PhET-iO and we agree it would be good!

zepumph commented 4 years ago

Implemented above, @jessegreenberg thanks for making this!

zepumph commented 4 years ago

There is a checkbox over in https://github.com/phetsims/projectile-motion/issues/219 for designers to review, so I'm going to close this.

zepumph commented 4 years ago

I think that we should have normal/slow radio button be part of this too.

zepumph commented 4 years ago

There are two review comments that I would like reviewed here instead of over in https://github.com/phetsims/projectile-motion/issues/219:

Using TimeControlNode (#216) would clean up the tree a lot. Currently, these controls are pretty scattered. (UPDATE: MK did this over in #216)

@arouinfar how does this look?

Why are normalMotionRadioButton and slowMotionRadioButton not part of a radioButtonGroup? When moving to TimeControlNode, would these end up in a common radioButtonGroup? UPDATE from MK: yes see #216

I just converted to use TimeControlNode's radio buttons. What do you think? I think it is organized as you want it, with actual hierarchy that makes sense.

P.S. @jessegreenberg the above commit was one of the most pleasurable API refactorings I have ever done. Really nice job on TimeControlNode!

arouinfar commented 4 years ago

@zepumph the timeControlNode is looking beautiful in studio. Nice work!

zepumph commented 4 years ago

Thanks!