Skip to content
Prev Previous commit
Next Next commit
Correction to commit 515167a; need to adjust mouse position Y for use…
… by FlyViewInputHandler, and per frame mouse/key events.
  • Loading branch information
gbburkhardt committed Jan 11, 2024
commit afdb4d90ca653492c523d07d5087b0011af85379
6 changes: 3 additions & 3 deletions src/gov/nasa/worldwind/awt/BasicViewInputHandler.java
Original file line number Diff line number Diff line change
Expand Up @@ -219,10 +219,10 @@ public boolean inputActionPerformed(KeyEventState keys, String target,

Point movement = ViewUtil.subtract(point, lastPoint);
int headingInput = movement.x;
int pitchInput = movement.y;
int pitchInput = -movement.y;
Point totalMovement = ViewUtil.subtract(point, mouseDownPoint);
int totalHeadingInput = totalMovement.x;
int totalPitchInput = totalMovement.y;
int totalPitchInput = -totalMovement.y;

ViewInputAttributes.DeviceAttributes deviceAttributes =
getAttributes().getDeviceAttributes(ViewInputAttributes.DEVICE_MOUSE);
Expand Down Expand Up @@ -267,7 +267,7 @@ public boolean inputActionPerformed(AbstractViewInputHandler inputHandler,
mouseDownPoint = lastPoint;
Point totalMovement = ViewUtil.subtract(point, mouseDownPoint);
int totalHeadingInput = totalMovement.x;
int totalPitchInput = totalMovement.y;
int totalPitchInput = -totalMovement.y;

ViewInputAttributes.DeviceAttributes deviceAttributes =
getAttributes().getDeviceAttributes(ViewInputAttributes.DEVICE_MOUSE);
Expand Down