[PATCH] 8143596: FXCanvas does not forward touch gestures to embedded scene

Alexander Nyssen alexander at nyssen.org
Thu Aug 18 14:22:19 UTC 2016

Hi Kevin,

I think we can go for option 1) and can approach the manual test as you outlined in your second comment. Attached please find an updated patch, which no longer contains the SWT upgrade but instead provides a respective comment within the manual test. I have also updated the manual test to provide detailed test steps and expectations, which were still missing in the initial patch.

I could get hold of a Windows PC with touch screen today and can confirm proper behavior there as well. Please note that while my patch contains handling of SWIPE events, I was not able to obtain any SWIPE events from SWT, neither on Windows 10 nor on MaxOS El Capitan, while PAN, ROTATE, and ZOOM events were properly delivered on both platforms (which is why I have excluded SWIPE from the manual test). I further noticed one difference of behavior on both platforms: while on MacOS SWT delivers inertia events for PAN, this is not the case on Windows (here, the gesture end event is always the last event that is delivered), but this is rather an SWT issue and cannot be handled by FXCanvas.

Even while we go with option 1), upgrading the SWT library would not be a bad idea, as the version currently used (3.7.2) is from 2012. Maybe you could open a separate issue for it, which does not „block“ this issue but simply „relates“ to it?

Best Regards,

> Am 17.08.2016 um 23:42 schrieb Kevin Rushforth <kevin.rushforth at oracle.com>:
> I uploaded the patch. I also added a comment [1] to the bug report with a concern about updating the dependent SWT library. You can read the details in the bug report.
> -- Kevin
> [1] https://bugs.openjdk.java.net/browse/JDK-8143596?focusedCommentId=13989256&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13989256
> Alexander Nyssen wrote:
>> Hi all, Kevin,
>> attached please find a patch for JDK-8143596 <https://bugs.openjdk.java.net/browse/JDK-8143596> (FXCanvas does not forward touch gestures to embedded scene). The patch depends on the most recent patch I provided for JDK-8161282 (revision 15_08_16, which was already uploaded). I developed and tested it on MacOSX, as SWT does not support any gestures on Linux. I could not test it on Windows yet, but will try to do so tomorrow (I cannot use my virtual machine but need to get hold of a windows device with touch support). I have added a simple manual test but no automated test yet.
>> Best Regards,
>> Alexander
>> =
>> ------------------------------------------------------------------------

More information about the openjfx-dev mailing list