wasPressed

fun wasPressed(key: Key): Boolean

Returns whether key went down since the last edge-consuming step — a latched edge.

Return

true on the first step run for the frame containing the press; false after.

Parameters

key

The Compose key code to test.