186 |
186 |
187 // Menu items to array |
187 // Menu items to array |
188 TInt menuItemCount = menuPane->NumberOfItemsInPane(); |
188 TInt menuItemCount = menuPane->NumberOfItemsInPane(); |
189 for ( TInt i( 0 ); i < menuItemCount; i++ ) |
189 for ( TInt i( 0 ); i < menuItemCount; i++ ) |
190 { |
190 { |
191 menuItemArray.Append( menuPane->MenuItemCommandId( i ) ); |
191 menuItemArray.AppendL( menuPane->MenuItemCommandId( i ) ); |
192 } |
192 } |
193 |
193 |
194 // Menu items to be deleted |
194 // Menu items to be deleted |
195 for ( TInt i( 0 ); i < menuItemArray.Count(); i++ ) |
195 for ( TInt i( 0 ); i < menuItemArray.Count(); i++ ) |
196 { |
196 { |
770 // ----------------------------------------------------------- |
770 // ----------------------------------------------------------- |
771 // CPhoneCustomizationVoip::InsertTextInputModeChangeMenuItemL |
771 // CPhoneCustomizationVoip::InsertTextInputModeChangeMenuItemL |
772 // ----------------------------------------------------------- |
772 // ----------------------------------------------------------- |
773 // |
773 // |
774 void CPhoneCustomizationVoip::InsertTextInputModeChangeMenuItemL( |
774 void CPhoneCustomizationVoip::InsertTextInputModeChangeMenuItemL( |
775 CEikMenuPane& aMenuPane ) |
775 CEikMenuPane& /*aMenuPane*/ ) |
776 { |
776 { |
777 __LOGMETHODSTARTEND( PhoneUIVoIPExtension, |
777 __LOGMETHODSTARTEND( PhoneUIVoIPExtension, |
778 "CPhoneCustomizationVoip::InsertTextInputModeChangeMenuItemL" ); |
778 "CPhoneCustomizationVoip::InsertTextInputModeChangeMenuItemL" ); |
779 |
779 |
780 TInt modeChangeOptionIndex = KErrNotFound; |
|
781 if ( aMenuPane.MenuItemExists( |
|
782 EPhoneNumberAcqCmdToggleNeAlphaMode, modeChangeOptionIndex ) || |
|
783 aMenuPane.MenuItemExists( |
|
784 EPhoneNumberAcqCmdToggleNeNumericMode, modeChangeOptionIndex ) ) |
|
785 { |
|
786 __PHONELOG( EBasic, PhoneUIVoIPExtension, |
|
787 "InsertTextInputModeChangeMenuItemL, MENU ITEM ALREADY EXISTS" ); |
|
788 __ASSERT_DEBUG( EFalse, Panic( EPhoneCtrlInvariant ) ); |
|
789 } |
|
790 |
|
791 CEikMenuPaneItem* menuItem = NULL; |
|
792 TBool numberEntryInNumericMode = iViewCommandHandle.HandleCommandL( |
|
793 EPhoneViewIsNumberEntryNumericMode ) == EPhoneViewResponseSuccess; |
|
794 if ( numberEntryInNumericMode ) |
|
795 { |
|
796 menuItem = CreateMenuPaneItemLC( |
|
797 EPhoneNumberAcqCmdToggleNeAlphaMode, |
|
798 R_PHONEUI_NUMBERACQ_OPTIONS_MENU_ITEM_ALPHA_MODE ); |
|
799 } |
|
800 else |
|
801 { |
|
802 menuItem = CreateMenuPaneItemLC( |
|
803 EPhoneNumberAcqCmdToggleNeNumericMode, |
|
804 R_PHONEUI_NUMBERACQ_OPTIONS_MENU_ITEM_NUMERIC_MODE ); |
|
805 } |
|
806 |
|
807 // alpha/numeric mode option is always second item in number entry menu |
|
808 const TInt KTextInputModeChangeMenuItemIndex = 1; |
|
809 aMenuPane.InsertMenuItemL( |
|
810 menuItem->iData, KTextInputModeChangeMenuItemIndex ); |
|
811 CleanupStack::PopAndDestroy( menuItem ); |
|
812 } |
780 } |
813 |
781 |
814 |
782 |
815 // ----------------------------------------------------------- |
783 // ----------------------------------------------------------- |
816 // CPhoneCustomizationVoip::GetActiveCallArrayL |
784 // CPhoneCustomizationVoip::GetActiveCallArrayL |