I had a fairly bad instance of freezing with multitouch. I saw it on iPad, and don't have a touch screen on my computer, so I don't have a console readout.
Steps:
Go to the third screen and turn on the interval tools.
Drag around one of the ends of the tool,
While dragging, press reset all, make sure the dragging finger is moving at this point
With that finger still down, turn on interval tools again
Drag the down finger over the tool to snag it and drag it. It should catch the "middle" of the tool
```diff
Subject: [PATCH] Avoid infinite loop updating edges during reset during multitouch interaction, see https://github.com/phetsims/projectile-data-lab/issues/321
---
Index: js/measures/view/IntervalToolNode.ts
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/js/measures/view/IntervalToolNode.ts b/js/measures/view/IntervalToolNode.ts
--- a/js/measures/view/IntervalToolNode.ts (revision 550aaa9980fe589bd77123cf60970c5a89040e80)
+++ b/js/measures/view/IntervalToolNode.ts (date 1714496286655)
@@ -423,7 +423,10 @@
}, edge2DragListenerOptions, dragListenerOptions ) ) );
desiredCenterLocationProperty.lazyLink( ( value: Vector2, oldValue: Vector2 ) => {
- if ( this.isCenterDraggingProperty.value ) {
+
+ // During a drag, update the edge positions based on the center drag. During a reset all, this would cause an
+ // infinite loop, and the edges are reset elsewhere, so this can be avoided during reset all.
+ if ( this.isCenterDraggingProperty.value && !ResetAllButton.isResettingAllProperty.value ) {
let delta = value.x - oldValue.x;
const max = Math.max( intervalTool.edge1Property.value, intervalTool.edge2Property.value );
From https://github.com/phetsims/projectile-data-lab/issues/290#issuecomment-2083428976 and discovered in https://github.com/phetsims/qa/issues/1079
@KatieWoe said:
I had a fairly bad instance of freezing with multitouch. I saw it on iPad, and don't have a touch screen on my computer, so I don't have a console readout.
Steps:
https://github.com/phetsims/projectile-data-lab/assets/41024075/c4df07dd-004b-4e13-8338-bdabc96698d4