Explaining Key Events in Symbian

From Nokia Developer Wiki
Jump to: navigation, search
Article Metadata
Created: bharatuppal (19 Jul 2007)
Last edited: hamishwillee (23 Jul 2012)

Normally, keyboard key presses result in three events being delivered to the client: EEventKeyDown, EEventKey, and EEventKeyUp.


What is EEventKeyDown?

When the user presses the key, at this moment the client receives a EEventKeyDown event. This event is only delivered once, even if the user then keeps the key depressed for a long while.

What is EEventKey?

On pressing any key, a EEventKey event is received. If the key auto-repeats, multiple EEventKey events may be delivered.

What is EEventKeyUp?

When the user finally releases the key, at this moment the client receives a EEventKeyUp event.

Note: It does not matter whether the key is pressed for a long or short time, EEventKeyUp is received at the release of the key.

How to catch different KeyEvents ?

TKeyResponse CMyAppContainer::OfferKeyEventL( const TKeyEvent&
aKeyEvent, TEventCode aType )
if( aType == EEventKeyDown )
// Process EEventKeyDown
if( aType == EEventKey )
case EStdKeyDownArrow:
case EStdKeyUpArrow:
case EStdKeyLeftArrow:
case EStdKeyRightArrow:
if( aType == EEventKeyUp )
// Process EEventKeyUp
This page was last modified on 23 July 2012, at 07:46.
38 page views in the last 30 days.

Was this page helpful?

Your feedback about this content is important. Let us know what you think.


Thank you!

We appreciate your feedback.