Index: sky/shell/org/domokit/sky/shell/PlatformView.java |
diff --git a/sky/shell/org/domokit/sky/shell/PlatformView.java b/sky/shell/org/domokit/sky/shell/PlatformView.java |
index 07af2b46745bbbae2b91eb6994e55d44779fe19f..a4b98cd5fbf9a31a7d8794f65d87c38baa2ab5cc 100644 |
--- a/sky/shell/org/domokit/sky/shell/PlatformView.java |
+++ b/sky/shell/org/domokit/sky/shell/PlatformView.java |
@@ -112,11 +112,19 @@ public class PlatformView extends SurfaceView |
pointerData.x = event.getX(pointerIndex); |
pointerData.y = event.getY(pointerIndex); |
+ pointerData.pressure = event.getPressure(pointerIndex); |
+ // TODO(eseidel): Could get the calibrated range if necessary: |
+ // event.getDevice().getMotionRange(MotionEvent.AXIS_PRESSURE) |
+ pointerData.pressureMin = 0.0f; |
+ pointerData.pressureMax = 1.0f; |
+ |
InputEvent inputEvent = new InputEvent(); |
inputEvent.type = getTypeForAction(event.getActionMasked()); |
inputEvent.timeStamp = event.getEventTime(); |
inputEvent.pointerData = pointerData; |
+ |
+ |
abarth-chromium
2015/02/28 03:42:30
So many blank lines. :)
abarth-chromium
2015/02/28 03:42:30
So many blank lines. :)
|
mViewportObserver.onInputEvent(inputEvent); |
} |