admin管理员组

文章数量:1435534

I’m encountering an issue in a Delphi app when using Android's Gesture Navigation feature. Specifically, the VirtualKeyboard hide and show events are only triggered every second attempt when performing a hardware back (HwBack) gesture. This problem does not occur when using the 3-button navigation system.

Here’s a video explaining Android Gesture Navigation for reference:

Reproduction steps:

  • Create a TForm in Delphi.
  • Add a component (e.g., an TEdit) that triggers the VirtualKeyboard.
  • Use Android Gesture Navigation and attempt to hide the keyboard using the HwBack gesture.
  • Observe that the VirtualKeyboard hide event is triggered only on every second attempt.

Additional context:

  • When using the 3-button navigation system, the events are triggered reliably.
  • Related issue reports: RSP-2040 and RSP-2047 (submitted to Embarcadero).

Has anyone encountered similar issues, and if so, is there a known workaround or fix? The issue occurs in Delphi version 12.2 with the latest patches applied. However, I believe this behavior might be present in earlier versions as well—likely those supporting Android 10, which introduced Gesture Navigation support.

Edit: Some additional insights on this. There is a difference between using the back gesture (swiping from the left or right edge to the center) and using the small button below the keyboard to hide it. When using the small keyboard button, the behavior can be consistently reproduced.

本文标签: Delphi VirtualKeyboard events not reliably triggered with Android Gesture NavigationStack Overflow