iOS: How to detect the escape/control keys on a hardware bluetooth keyboard?

后端 未结 3 1696
南方客
南方客 2021-02-04 00:41

I\'m trying to figure out how to detect that the Escape (and other key combinations like Ctrl and alt) have been pressed on a bluetooth keyboard attached to an iOS device.

3条回答
  •  心在旅途
    2021-02-04 01:24

    There are no public APIs for what you intend to accomplish, so this may lead to a rejection.

    If you are willing to risk it, you can try this. Wich basically intercepts all events sent to your App by overwriting sendEvent: in your UIApplication.

提交回复
热议问题