|
Nokia N97 SDK Example Applications Guide |
#include <EnvMappingAppUi.h>
Inheritance diagram for CEnvMappingAppUi:

Definition at line 36 of file EnvMappingAppUi.h.
Public Member Functions |
|
| void | ConstructL () |
| virtual | ~CEnvMappingAppUi () |
Private Member Functions |
|
| void | DynInitMenuPaneL (TInt aResourceId, CEikMenuPane *aMenuPane) |
| void | HandleCommandL (TInt aCommand) |
| virtual TKeyResponse | HandleKeyEventL (const TKeyEvent &aKeyEvent, TEventCode aType) |
Private Attributes |
|
| CEnvMappingContainer * | iAppContainer |
|
|
Destructor. Removes CTextureContainer from the control stack and destroys it. Definition at line 47 of file EnvMappingAppUi.cpp. References iAppContainer. 00048 { 00049 if ( iAppContainer ) 00050 { 00051 RemoveFromStack( iAppContainer ); 00052 delete iAppContainer; 00053 } 00054 }
|
|
|
Second phase constructor. Creates the CTextureContainer and adds it to the control stack. Definition at line 30 of file EnvMappingAppUi.cpp. References CEnvMappingContainer::ConstructL(), and iAppContainer. 00031 { 00032 BaseConstructL(); 00033 00034 iAppContainer = new (ELeave) CEnvMappingContainer; 00035 iAppContainer->SetMopParent(this); 00036 00037 iAppContainer->ConstructL( ClientRect(), this ); 00038 AddToStackL( iAppContainer ); 00039 }
|
|
||||||||||||
|
This method is called by the EIKON framework just before it displays a menu pane. Builds the dynamic menuitems for toggling the various options in the example. Definition at line 64 of file EnvMappingAppUi.cpp.
|
|
|
CEikAppUi method that is used to handle user commands. Handles menu commands and application exit request.
Definition at line 122 of file EnvMappingAppUi.cpp. References CEnvMapping::DuckModel(), CEnvMapping::HeadModel(), iAppContainer, and CEnvMappingContainer::iEnvMapping. 00123 { 00124 switch ( aCommand ) 00125 { 00126 case EAknSoftkeyBack: 00127 case EEikCmdExit: 00128 { 00129 Exit(); 00130 break; 00131 } 00132 case EEnvMappingDuckObject: 00133 { 00134 iAppContainer->iEnvMapping->DuckModel(); 00135 break; 00136 } 00137 case EEnvMappingHeadObject: 00138 { 00139 iAppContainer->iEnvMapping->HeadModel(); 00140 break; 00141 } 00142 default: 00143 break; 00144 } 00145 }
|
|
||||||||||||
|
CEikAppUi method that is used to handle key events. Does nothing in this implemenation.
Definition at line 75 of file EnvMappingAppUi.cpp. References iAppContainer, CEnvMappingContainer::iEnvMapping, CEnvMapping::RotateObjectLeft(), and CEnvMapping::RotateObjectRight(). 00077 { 00078 if ( iAppContainer->iEnvMapping->GetState() == CEnvMapping::ERunning ) 00079 { 00080 if( aType == EEventKeyDown ) 00081 { 00082 TUint scan = aKeyEvent.iScanCode; 00083 00084 switch(scan) 00085 { 00086 case(14): 00087 iAppContainer->iEnvMapping->RotateObjectLeft(); 00088 return EKeyWasConsumed; 00089 case(15): 00090 iAppContainer->iEnvMapping->RotateObjectRight(); 00091 return EKeyWasConsumed; 00092 default: 00093 return EKeyWasNotConsumed; 00094 } 00095 } 00096 else if( aType == EEventKeyUp ) 00097 { 00098 TUint scan = aKeyEvent.iScanCode; 00099 00100 switch(scan) 00101 { 00102 case(14): 00103 iAppContainer->iEnvMapping->RotateObjectLeft(); 00104 return EKeyWasConsumed; 00105 case(15): 00106 iAppContainer->iEnvMapping->RotateObjectRight(); 00107 return EKeyWasConsumed; 00108 default: 00109 return EKeyWasNotConsumed; 00110 } 00111 } 00112 } 00113 00114 return EKeyWasNotConsumed; 00115 }
|
|
|
GUI container that resides in this application UI. Definition at line 83 of file EnvMappingAppUi.h. Referenced by ConstructL(), HandleCommandL(), HandleKeyEventL(), and ~CEnvMappingAppUi(). |
|
© Nokia 2009 |