Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我被困在这个问题上:如果设备是触觉设备(例如带有 Sun JavaME WirelessToolkit SDK 3.0 的 DefaultFxTouchPhone1),我想在用户使用笔设备在表格行(或单元格)上单击时执行一个操作。我尝试使用该addFocusListener方法,但它有错误,因为即使显示表格的表单不再显示,但FocusGain仍然调用该方法!
addFocusListener
FocusGain
那么如何仅在显示实际表单时捕获笔单击事件?
真的非常感谢
LookAndFeel.setTactileTouchDuration(int)可能是你需要的。
LookAndFeel.setTactileTouchDuration(int)
好的,我pointerListener在 Form 中添加了 ,并实现了pointerPressed测试该方法的 x 和 y 坐标pointerPressed是否在 Table 单元格的第一个absoluteX和最后一个absoluteY(加上高度)之间的方法。它有效!
pointerListener
pointerPressed
absoluteX
absoluteY