-
Notifications
You must be signed in to change notification settings - Fork 7
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
Multitouch can't pick up multiple atoms at onces #193
Comments
This behavior was implemented to handle #162 and #118 (maybe another multitouch related issue too). I didn't consider that we would want to drag two molecules at the same time. If that is the case, I'll have to revisit how we are interrupting input handlers and specify which inputs should be interrupted. I don't think this would be a minor change so I'll leave for @arouinfar to decide. Raising priority because this will require mostly model changes. |
I did a brief look around other sims like Build-An-Atom, Function-Builder-Basics, and Masses-and-Springs. It looks like draggable items will hold their drag state during a multi-touch event. This goes as far as allowing a dragged item to still be draggable even when switching scenes (seen in Function-Builder-Basics and Masses-and Springs). It seems like we are very lenient with our multi-touch policy and maybe we should adopt the same behavior here. |
If there isn't a problem with the current implementation then I'll leave as is. Dragging more than one item has some consequences in this sim. Some considerations: Every time Molecule A (first dragged item) is dragged we would need to make sure it isn't contained within Molecule B (second dragged item). Also, if both Molecule A and Molecule B are released at the same time, there may be conflicts in how the molecules in the play area are separated. Kit.separateMoleculeDestinations() would be called twice in that case. This may have performance concerns if a user chooses to drag 10 different molecules at the same time. We would need QA to take a look at sim performance and I'll have to do some optimizations. As I said above, I'll leave for now, but if we were to revisit these concerns should be taken into account. Closing. |
Also noting, the specific listener that would need to be reviewed would be in |
Test device
Dell
Operating System
Win 10
Browser
Chrome
Problem description
For phetsims/qa#506. Using multitouch on Windows touch screen.
You can only pick up and drag one atom or molecule at a time. If you grab a second, the first is dropped. This happens whether you are dragging from the bucket or are in the play area. If this is intended behavior, please close.
Troubleshooting information:
!!!!! DO NOT EDIT !!!!!
Name: Build a Molecule
URL: https://phet-dev.colorado.edu/html/build-a-molecule/1.0.0-dev.75/phet/build-a-molecule_all_phet.html
Version: 1.0.0-dev.75 2020-06-01 13:20:12 UTC
Features missing: touch
Flags: pixelRatioScaling
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.97 Safari/537.36
Language: en-US
Window: 1536x722
Pixel Ratio: 2.5/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: 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: