-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Long hold on kick button leads to multiple clicks #102
Comments
I think the bug here is that only 5 kicks should have happened in this case, because the mouse was released and kicks continued to occur. |
Noting that this doesn't seem to happen at all with the "Kick 5" button. |
@samreid and I thought about a fix for this and came up with two ideas:
We think 2 will be simplest to try out first. |
We experimented with (2), by changing the kick rate to match the 0.5 second delay (and also accounting for the 0.075 poise time), and it seemed better but still wasn't perfect. By that I mean that you could still sometimes see one more kick right after releasing the button. We weren't sure if that was good enough, so we investigated (1) above. However, the current implementation schedules single and multi-kicks through the same channel, so it would be a lot of increased complexity and work to get it to exactly track whether the kick 1 button is pressed but only for limiting those kicks. We estimate maybe 1-3 hours for the initial implementation if we want to invest in that. After further investigation, we found that a delay of 650ms seemed to have a very good matchup rate, very few false positives. We'll commit that and see if it is good enough. |
@KatieWoe can you please review the proposal in phettest? If it seems OK, please relabel as "ready for cherry pick". |
I found this behavior much, much better. My only note is that "Kick 5" does not behave the same way, and only fires when you let go. Is this intended? |
Thanks @KatieWoe! Yes, fire-on-hold is intentionally disabled for "Kick 5". |
@chrisklus and I confirmed this is fixed in in #122, closing. |
Test device
Dell
Operating System
Win 11
Browser
Firefox
Problem description
For phetsims/qa#789
If you hold the "Kick 1" button down for a moment, more than one kick will happen, and it will continue after you let go.
Visuals
![longclick](https://user-images.githubusercontent.com/41024075/159586662-775d6bae-dd31-4578-a6e5-1cfa17f909e5.gif)
Troubleshooting information:
!!!!! DO NOT EDIT !!!!!
Name: Center and Variability
URL: https://phet-dev.colorado.edu/html/center-and-variability/1.0.0-rc.1/phet/center-and-variability_all_phet.html
Version: 1.0.0-rc.1 2022-03-21 16:46:53 UTC
Features missing: touch
Flags: pixelRatioScaling
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:98.0) Gecko/20100101 Firefox/98.0
Language: en-US
Window: 1280x667
Pixel Ratio: 1.5/1
WebGL: WebGL 1.0
GLSL: WebGL GLSL ES 1.0
Vendor: Mozilla (ANGLE (Intel, Intel(R) HD Graphics Direct3D11 vs_5_0 ps_5_0))
Vertex: attribs: 16 varying: 30 uniform: 4096
Texture: size: 16384 imageUnits: 16 (vertex: 16, combined: 32)
Max viewport: 32767x32767
OES_texture_float: true
Dependencies JSON: {}
The text was updated successfully, but these errors were encountered: