phetsims / gravity-and-orbits

"Gravity And Orbits" is an educational simulation in HTML5, by PhET Interactive Simulations.
GNU General Public License v3.0
12 stars 6 forks source link

Restart button becomes enabled when star/plant/moon is grabbed #473

Closed Nancy-Salpepi closed 1 year ago

Nancy-Salpepi commented 1 year ago

Test device MacBook Air (m1 chip)

Operating System macOS 13.0

Browser safari 16.1 and with chrome

Problem description For https://github.com/phetsims/qa/issues/850, When I grab an interactive object in the play area, the restart button becomes enabled. Once I let go, it becomes disabled again.

**This is not seen in the published version.

Steps to reproduce

  1. On either screen with any scene, grab the sun, moon, planet or satellite--the restart button turns from gray to blue.
  2. Release the object--the restart button turns back to gray.

Visuals

https://user-images.githubusercontent.com/87318828/200937454-42e6e01c-0431-4ae5-a229-cc8da99bf653.mp4

Troubleshooting information: !!!!! DO NOT EDIT !!!!! Name: ‪Gravity and Orbits‬ URL: https://phet-dev.colorado.edu/html/gravity-and-orbits/1.6.0-rc.4/phet/gravity-and-orbits_all_phet.html Version: 1.6.0-rc.4 2022-11-08 22:23:49 UTC Features missing: applicationcache, applicationcache, touch Flags: pixelRatioScaling User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36 Language: en-US Window: 2068x1060 Pixel Ratio: 1.3333333730697632/1 WebGL: WebGL 1.0 (OpenGL ES 2.0 Chromium) GLSL: WebGL GLSL ES 1.0 (OpenGL ES GLSL ES 1.0 Chromium) Vendor: WebKit (WebKit WebGL) Vertex: attribs: 16 varying: 31 uniform: 1024 Texture: size: 16384 imageUnits: 16 (vertex: 16, combined: 32) Max viewport: 16384x16384 OES_texture_float: true Dependencies JSON: {}
Nancy-Salpepi commented 1 year ago

also seen with PhET-iO brand (standalone, studio, etc)

samreid commented 1 year ago

I pushed a proposed fix that seems to have the correct behavior. The restore state is now set on drag start and drag, in addition to drag end. I was concerned about the performance during dragging but a performance trace did not show troublesome CPU in my test.

samreid commented 1 year ago

Ready for testing in https://github.com/phetsims/qa/issues/857, please close if all is well.

Nancy-Salpepi commented 1 year ago

Looks good in 1.6.0-rc.6. Closing.