HumbleUI / JWM

Cross-platform window management and OS integration library for Java

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

macOS: trackpad touch events

shaunlebron opened this issue · comments

commented

Looking at adding access to macOS trackpad touch events. Some references to start:

I think web api should be studied for this too

commented

setAcceptsTouchEvents:YES seems to be deprecated for allowedTouchTypes. I had to find a usage example on GitHub.

The acceptsTouchEvents property also seemed necessary. Does Apple have newer docs on this?

I confirmed that the touch events are being caught now (see 49a4483). I will look at logging the touch event data to the window.

commented

I added EventTrackpadTouch* events and the dashboard event panel is logging them successfully. I will look at drawing the touch points in a new trackpad panel.

That would be cool!

commented

I put a trackpad panel next to the mouse panel:

CleanShot.2022-12-01.at.13.27.59.mp4

Problems so far:

  1. The dashboard starts hiccuping when I move the touch points too quickly. Not sure what’s going on there.
  2. Touch point state goes out of sync if you use a four-finger gesture that exits the view (swipe up, down, out or in). Not sure how to get external touch events to keep those in sync.