×
Namespaces

Variants
Actions
Revision as of 13:28, 24 August 2007 by Forum Nokia KB (Talk | contribs)

Capturing the End (red) key during a call using Symbian C++

From Nokia Developer Wiki
Jump to: navigation, search

Template:KBTS

Subject:

Capturing the End (red) key during a call TSS000375

 

Platform(s): Device(s), SW version(s):
S60 3rd Edition
S60 3rd Edition, FP1
 

Category:

Symbian C++

Subcategory:

 

Description:

An application can capture the the End key even during an active call using the following kind of code.
Please note that SwEvent capability is needed to make successful calls to the mentioned Window Server functions.
<code>
#include <W32STD.H> // link against ws32.lib
#include <e32keys.h>
...
RWindowGroup& groupWin = CCoeEnv::Static()->RootWin();
TInt endKey1 = groupWin.CaptureKeyUpAndDowns( EStdKeyNo, 0, 0 );
TInt endKey2 = groupWin.CaptureKey( EKeyNo, 0, 0 );
// -> End key can now be processed before the phone application of the device...
...
// Cancel the capture
groupWin.CancelCaptureKeyUpAndDowns( endKey1 );
groupWin.CancelCaptureKey( endKey2 );
</code>
This solution has been tested using Nokia N73 (SW: 2.0620.0.05).

Creation date:

July 7, 2006

Last modified:

 
83 page views in the last 30 days.
×