aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/Touchable.tsx
diff options
context:
space:
mode:
authorStanley Yip <stanley_yip@brown.edu>2019-12-07 16:53:43 -0500
committerStanley Yip <stanley_yip@brown.edu>2019-12-07 16:53:43 -0500
commit766e47cd144be6f0bcbb5787dbd174aa1bba3690 (patch)
tree4e456732770a2be4ffff0801a06d471b42c8558d /src/client/views/Touchable.tsx
parentb3b81c8400ce2a92df1ae8c0db9b422cf4a2cf4c (diff)
box !!!!
Diffstat (limited to 'src/client/views/Touchable.tsx')
-rw-r--r--src/client/views/Touchable.tsx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/Touchable.tsx b/src/client/views/Touchable.tsx
index 5dcfec768..a647dec04 100644
--- a/src/client/views/Touchable.tsx
+++ b/src/client/views/Touchable.tsx
@@ -18,9 +18,9 @@ export abstract class Touchable<T = {}> extends React.Component<T> {
protected onTouchStart = (e: React.TouchEvent): void => {
for (let i = 0; i < e.targetTouches.length; i++) {
let pt: any = e.targetTouches.item(i);
- // pen is also a touch, but with a radius of 0.5 (at least with the surface pens). i doubt anyone's fingers are 2 pixels wide,
+ // pen is also a touch, but with a radius of 0.5 (at least with the surface pens).
// and this seems to be the only way of differentiating pen and touch on touch events
- if (pt.radiusX > 2 && pt.radiusY > 2) {
+ if (pt.radiusX > 0.5 && pt.radiusY > 0.5) {
this.prevPoints.set(pt.identifier, pt);
}
}