Touch screen java launch

I am creating a java program using swing, which should work on a touch monitor. Right now I do not have a monitor, so I only program with a laptop without the ability to touch. Will my click event be triggered by touching the monitor and scrolling the bar correctly, or do I need events specially encoded for touch screen monitors? NOTE. I do not support touch screens such as a tablet, I use a raspberry pi connected to the touch monitor via HDMI.

+4
source share
1 answer

When you use your touchmonitor using the Swing app, touching the monitor will send mouse clicks. Therefore, if you are already responding to mouse clicks in your Swing application, your program should work when you connect your touch screen.

+1
source

Source: https://habr.com/ru/post/1527173/


All Articles