[SDL] No unicode information in key releases
slouken at devolution.com
Tue Jan 18 10:29:27 PST 2005
You can't treat the unicode member of key events as a state.
Think of it instead as a separate event that's piggy-backed onto the
key press event ... "the unicode character X was input" Since there
is no character input generated when a key is released, the unicode
field is not filled in for a key release.
This makes a little more sense if you think about this sequence:
's' key pressed (key is SDLK_s, unicode is 'S')
's' key released (key is SDLK_s, unicode is meaningless)
-Sam Lantinga, Software Engineer, Blizzard Entertainment
More information about the SDL