--- a/phone_plat/phone_application_voip_commands_api/inc/phoneappvoipcommands.hrh Wed Mar 31 21:30:06 2010 +0300
+++ b/phone_plat/phone_application_voip_commands_api/inc/phoneappvoipcommands.hrh Wed Apr 14 15:56:42 2010 +0300
@@ -74,6 +74,10 @@
EPhoneCmdServiceEnablingTimedOut,
EPhoneCmdHandoverToWlan,
EPhoneCmdHandoverToGsm,
+ /** Command id for unattended transfer callback ok. */
+ EPhoneCmdUnattendedTransferCallBackOk,
+ /** Command id for unattended transfer callback cancel. */
+ EPhoneCmdUnattendedTransferCallBackCancel,
// Last VoIP command, not used in menu nor soft key.
// Add new VoIP commands before this.
EPhoneCmdVoIPLast
--- a/phoneapp/phoneuicontrol/inc/cphonekeyeventforwarder.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuicontrol/inc/cphonekeyeventforwarder.h Wed Apr 14 15:56:42 2010 +0300
@@ -196,6 +196,14 @@
* @ return ETrue if alpha mode, EFalse otherwise.
*/
TBool IsKeyBlocked( const TKeyEvent& aKeyEvent ) const;
+
+ /**
+ * Handles dialer key event. This includes handling multitapping of *-key.
+ * If multitap happens, function creates back space event
+ * to delete previous character, and replaces it with
+ * the next one in the cyclig character list *+pw.
+ */
+ void HandleTouchDialerKeyEventL( const TKeyEvent& aKeyEvent, TEventCode aType );
private: // Data
@@ -236,6 +244,21 @@
* Own.
*/
CPhoneQwertyHandler* iQwertyHandler;
+
+ /*
+ * Time of the previous key press. Used for multitap behaviour.
+ */
+ TTime iPreviousKeyPressTime;
+
+ /*
+ * Keycode of the previous keypress. Used for multitap behaviour.
+ */
+ TInt iPreviousScanCode;
+
+ /*
+ * Points to next character in multitap character list.
+ */
+ TInt iMultitapIndex;
};
#endif // CPHONEKEYEVENTFORWARDER_H
--- a/phoneapp/phoneuicontrol/src/cphonekeyeventforwarder.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuicontrol/src/cphonekeyeventforwarder.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -43,6 +43,13 @@
const TUid KCRUidAvkon = { 0x101F876E };
const TUint32 KAknKeyBoardLayout = 0x0000000B;
+// Characters resulting from multitapping *-key.
+_LIT( KAsteriskMultitapCharacters, "*+pw" );
+
+// Multitap delay parameter in micro seconds.
+const TInt KMultitapDelay = 1000000;
+
+
// ============================ MEMBER FUNCTIONS ===============================
// -----------------------------------------------------------------------------
@@ -278,6 +285,54 @@
}
// -----------------------------------------------------------------------------
+// CPhoneKeyEventForwarder::HandleTouchDialerKeyEventL
+//
+// -----------------------------------------------------------------------------
+//
+void CPhoneKeyEventForwarder::HandleTouchDialerKeyEventL( const TKeyEvent& aKeyEvent, TEventCode aType )
+ {
+ TBool multitap = aKeyEvent.iScanCode == EStdKeyNkpAsterisk &&
+ iPreviousScanCode == EStdKeyNkpAsterisk &&
+ iKeyPressTime.MicroSecondsFrom( iPreviousKeyPressTime ) < KMultitapDelay;
+
+ if ( multitap )
+ {
+ if ( aType == EEventKeyDown )
+ {
+ // Update multitap index
+ iMultitapIndex = ( iMultitapIndex + 1 ) % KAsteriskMultitapCharacters().Length();
+
+ // Delete the previously entered character by simulating a backspace character.
+ TKeyEvent backSpaceEvent;
+ backSpaceEvent.iModifiers = 0;
+ backSpaceEvent.iRepeats = 0;
+ backSpaceEvent.iCode = EKeyBackspace;
+ backSpaceEvent.iScanCode = EStdKeyBackspace;
+ iStateMachine->State()->HandleKeyEventL( backSpaceEvent, EEventKey );
+ }
+
+ TKeyEvent keyEvent( aKeyEvent );
+
+ // Modify the key event to contain the next character on multitap list.
+ keyEvent.iCode = ( TInt ) KAsteriskMultitapCharacters()[ iMultitapIndex ];
+
+ // Send character to number entry.
+ iStateMachine->State()->HandleKeyEventL( keyEvent, aType );
+ }
+
+ else
+ {
+ iMultitapIndex = 0;
+ iStateMachine->State()->HandleKeyEventL( aKeyEvent, aType );
+ }
+
+ if ( aType == EEventKeyUp )
+ {
+ iPreviousScanCode = aKeyEvent.iScanCode;
+ }
+ }
+
+// -----------------------------------------------------------------------------
// CPhoneKeyEventForwarder::OfferKeyEventBeforeControlStackL
// Let phone handle before other components in control stack
// -----------------------------------------------------------------------------
@@ -313,23 +368,26 @@
break;
}
- // Check if keyEvent is simulated in Dialer.
+ // Check if keyEvent is simulated by Dialer.
const TBool simulatedByDialer =
( ( aKeyEvent.iModifiers & ( EModifierNumLock | EModifierKeypad ) )
== ( EModifierNumLock | EModifierKeypad ) );
- if( simulatedByDialer && iQwertyHandler->IsQwertyInput() )
+ if( simulatedByDialer )
{
- // When dialler key was pressed and
- // qwerty is open and editor is alphanumeric
- // -Dont let FEP to handle key events
- // -> Multitapping doesnt work
- // -> Numbers are inserted to dialler without modifications
- // Also effects # / * - key handling
- iStateMachine->State()->HandleKeyEventL( aKeyEvent, aType );
+ HandleTouchDialerKeyEventL( aKeyEvent, aType );
response = EKeyWasConsumed;
}
+ else
+ {
+ // If not simulated by dialer, multitap related fields are reset.
+ // Any key event not originating from dialer interrupts multitap
+ // behaviour.
+ iMultitapIndex = 0;
+ iPreviousScanCode = 0;
+ }
+
return response;
}
@@ -379,6 +437,9 @@
ConvertKeyCode( iKeyPressedDown, aKeyEvent );
// Save key scan code
iScanCode = aKeyEvent.iScanCode;
+
+ // Store the previous keypress time.
+ iPreviousKeyPressTime = iKeyPressTime;
// Start the key press timer
iKeyPressTime.UniversalTime();
--- a/phoneapp/phoneuicontrol/src/cphonesecuritymodeobserver.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuicontrol/src/cphonesecuritymodeobserver.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -18,7 +18,7 @@
#include "cphonesecuritymodeobserver.h"
#include "mphonesecuritymodechangeobserver.h"
#include "cphonelogger.h"
-#include "CPhonePubSubProxy.h"
+#include "cphonepubsubproxy.h"
#include <mpeengineinfo.h>
#include <featmgr.h>
--- a/phoneapp/phoneuicontrol/src/cphonestate.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuicontrol/src/cphonestate.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -4705,12 +4705,16 @@
//
EXPORT_C void CPhoneState::SetToolbarDimming( TBool aDimmed )
{
- if ( FeatureManager::FeatureSupported( KFeatureIdTouchCallHandling ) )
+ if ( FeatureManager::FeatureSupported( KFeatureIdTouchCallHandling ) )
{
- TPhoneCmdParamBoolean booleanParam;
- booleanParam.SetBoolean( aDimmed );
- TRAP_IGNORE( iViewCommandHandle->ExecuteCommandL(
- EPhoneViewSetToolbarDimming, &booleanParam ));
+ // Check that we are not undimming toolbar in security mode
+ if ( !( !aDimmed && iStateMachine->SecurityMode()->IsSecurityMode() ) )
+ {
+ TPhoneCmdParamBoolean booleanParam;
+ booleanParam.SetBoolean( aDimmed );
+ TRAP_IGNORE( iViewCommandHandle->ExecuteCommandL(
+ EPhoneViewSetToolbarDimming, &booleanParam ));
+ }
}
}
--- a/phoneapp/phoneuicontrol/src/cphonestateincall.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuicontrol/src/cphonestateincall.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -38,6 +38,7 @@
#include "tphonecmdparamcallstatedata.h"
#include "tphonecmdparamsfidata.h"
#include "mphonestatemachine.h"
+#include "mphonesecuritymodeobserver.h"
#include "phonestatedefinitions.h"
#include "phoneviewcommanddefinitions.h"
#include "phoneui.hrh"
@@ -611,9 +612,13 @@
// Activate DTMF list query when cancel is pressed.
// Forwards command to the framework
- HandleCommandL( EPhoneInCallCmdDtmfListQuery );
+ if ( !iStateMachine->SecurityMode()->IsSecurityMode() )
+ {
+ HandleCommandL( EPhoneInCallCmdDtmfListQuery );
+ }
}
break;
+
case EPhoneDtmfDialerExit:
{
CloseDTMFEditorL();
@@ -639,7 +644,14 @@
break;
//DTMF list query - dialog
case EPhoneInCallCmdDtmfListQuery:
- LaunchDtmfListQueryL();
+ if ( iStateMachine->SecurityMode()->IsSecurityMode() )
+ {
+ HandleCommandL( EPhoneInCallCmdDtmfManualQuery );
+ }
+ else
+ {
+ LaunchDtmfListQueryL();
+ }
break;
//DTMF list query - Search
--- a/phoneapp/phoneuicontrol/src/cphonestatestartup.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuicontrol/src/cphonestatestartup.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -277,7 +277,7 @@
{
__LOGMETHODSTARTEND(EPhoneControl, "CPhoneStateStartup::InitializationReady() ");
iStateMachine->SecurityMode()->Initialize();
- if ( !iStateMachine->SecurityMode()->IsSecurityMode() && !IsSimOk() )
+ if ( !IsSimOk() )
{
iCreateNote = CIdle::NewL( CActive::EPriorityHigh );
CreateAndShowNoteAfterIdle();
--- a/phoneapp/phoneuistates/src/cphonecallsetup.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuistates/src/cphonecallsetup.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -31,6 +31,7 @@
#include "cphonegeneralgsmmessageshandler.h"
#include "cphonemediatorfactory.h"
#include "cphonemediatorsender.h"
+#include "mphonesecuritymodeobserver.h"
// ================= MEMBER FUNCTIONS =======================
@@ -102,11 +103,20 @@
case MEngineMonitor::EPEMessageConnecting:
HandleConnectingL( aCallId );
break;
+
+ case MEngineMonitor::EPEMessageShowVersion:
+ {
+ if ( iStateMachine->SecurityMode()->IsSecurityMode() )
+ {
+ // Do nothing if security mode is enabled.
+ return;
+ }
+ }
+ // Fall through
// fall through.
case MEngineMonitor::EPEMessageIssuingSSRequest:
case MEngineMonitor::EPEMessageCallBarred:
- case MEngineMonitor::EPEMessageShowVersion:
case MEngineMonitor::EPEMessageIssuedSSRequest:
case MEngineMonitor::EPEMessageTempClirActivationUnsuccessful:
case MEngineMonitor::EPEMessageIncCallIsForw:
--- a/phoneapp/phoneuistates/src/cphonegsmincall.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuistates/src/cphonegsmincall.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -35,6 +35,7 @@
#include "tphonecmdparamcallstatedata.h"
#include "tphonecmdparamcallheaderdata.h"
+#include "mphonesecuritymodeobserver.h"
// ================= MEMBER FUNCTIONS =======================
@@ -118,10 +119,20 @@
CPhoneState::SendGlobalInfoNoteL(
EPhoneInformationRemoteCreateConferenceNote );
break;
+
+ case MEngineMonitor::EPEMessageShowVersion:
+ {
+ if ( iStateMachine->SecurityMode()->IsSecurityMode() )
+ {
+ // Do nothing if security mode is enabled.
+ return;
+ }
+ }
+ // Fall through
+
case MEngineMonitor::EPEMessageIncCallIsForw: // fall through
case MEngineMonitor::EPEMessageIssuingSSRequest: // fall through
case MEngineMonitor::EPEMessageCallBarred: // fall through
- case MEngineMonitor::EPEMessageShowVersion: // fall through
case MEngineMonitor::EPEMessageIssuedSSRequest: // fall through
case MEngineMonitor::EPEMessageTempClirActivationUnsuccessful:
case MEngineMonitor::EPEMessageIncCallForwToC: // fall through
--- a/phoneapp/phoneuistates/src/cphoneidle.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuistates/src/cphoneidle.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -22,6 +22,8 @@
#include "phonelogger.h"
#include "cphonegeneralgsmmessageshandler.h"
#include "tphonecmdparamboolean.h"
+#include "mphonesecuritymodeobserver.h"
+#include "mphonestatemachine.h"
// ================= MEMBER FUNCTIONS =======================
@@ -114,7 +116,6 @@
}
case MEngineMonitor::EPEMessageIssuingSSRequest: // fall through
case MEngineMonitor::EPEMessageCallBarred: // fall through
- case MEngineMonitor::EPEMessageShowVersion: // fall through
case MEngineMonitor::EPEMessageTempClirActivationUnsuccessful:
case MEngineMonitor::EPEMessageIncCallIsForw: // fall through
case MEngineMonitor::EPEMessageIncCallForwToC: // fall through
@@ -131,7 +132,22 @@
CleanupStack::PopAndDestroy( gsmMsgHandler );
}
break;
-
+
+ case MEngineMonitor::EPEMessageShowVersion:
+ {
+ if ( !iStateMachine->SecurityMode()->IsSecurityMode() )
+ {
+ CPhoneGeneralGsmMessagesHandler* gsmMsgHandler =
+ CPhoneGeneralGsmMessagesHandler::NewL( *iStateMachine,
+ *iViewCommandHandle,
+ *this );
+ CleanupStack::PushL( gsmMsgHandler );
+ gsmMsgHandler->HandlePhoneEngineMessageL( aMessage, aCallId );
+ CleanupStack::PopAndDestroy( gsmMsgHandler );
+ }
+ }
+ break;
+
default:
CPhoneStateIdle::HandlePhoneEngineMessageL(
aMessage, aCallId );
--- a/phoneapp/phoneuistates/src/cphoneincoming.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuistates/src/cphoneincoming.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -27,6 +27,7 @@
#include "tphonecmdparamboolean.h"
#include "phoneui.hrh"
#include "mphonestatemachine.h"
+#include "mphonesecuritymodeobserver.h"
#include "tphonecmdparamcallstatedata.h"
// ================= MEMBER FUNCTIONS =======================
@@ -122,11 +123,20 @@
case MEngineMonitor::EPEMessageRemoteResumed:
SendGlobalInfoNoteL( EPhoneInformationConnectedNote );
break;
+
+ case MEngineMonitor::EPEMessageShowVersion:
+ {
+ if ( iStateMachine->SecurityMode()->IsSecurityMode() )
+ {
+ // Do nothing if security mode is enabled.
+ return;
+ }
+ }
+ // Fall through
// fall through.
case MEngineMonitor::EPEMessageIssuingSSRequest:
case MEngineMonitor::EPEMessageCallBarred:
- case MEngineMonitor::EPEMessageShowVersion:
case MEngineMonitor::EPEMessageIssuedSSRequest:
case MEngineMonitor::EPEMessageTempClirActivationUnsuccessful:
case MEngineMonitor::EPEMessageIncCallIsForw:
--- a/phoneapp/phoneuistates/src/cphonesingleandwaiting.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuistates/src/cphonesingleandwaiting.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -622,14 +622,11 @@
CloseCustomizedDialerL();
}
- if ( IsNumberEntryUsedL() )
+ if ( IsNumberEntryUsedL() && NeedToReturnToForegroundAppL() )
{
- if ( NeedToReturnToForegroundAppL() )
- {
- iViewCommandHandle->ExecuteCommandL( EPhoneViewSetControlAndVisibility );
+ iViewCommandHandle->ExecuteCommandL( EPhoneViewSetControlAndVisibility );
- UpdateCbaL( EPhoneCallHandlingInCallCBA );
- }
+ UpdateCbaL( EPhoneCallHandlingInCallCBA );
}
else
{
--- a/phoneapp/phoneuistates/src/cphonestartup.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuistates/src/cphonestartup.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -20,6 +20,8 @@
#include "cphonestartup.h"
#include "phonerssbase.h"
#include "phonelogger.h"
+#include "mphonestatemachine.h"
+#include "mphonesecuritymodeobserver.h"
#include "cphonegeneralgsmmessageshandler.h"
// ================= MEMBER FUNCTIONS =======================
@@ -100,10 +102,19 @@
CPhoneState::SendGlobalInfoNoteL(
EPhoneInformationConnectedNote );
break;
+
+ case MEngineMonitor::EPEMessageShowVersion:
+ {
+ if ( iStateMachine->SecurityMode()->IsSecurityMode() )
+ {
+ // Do nothing if security mode is enabled.
+ return;
+ }
+ }
+ // Fall through
case MEngineMonitor::EPEMessageIssuingSSRequest: // fall through
case MEngineMonitor::EPEMessageCallBarred: // fall through
- case MEngineMonitor::EPEMessageShowVersion: // fall through
case MEngineMonitor::EPEMessageIssuedSSRequest: // fall through
case MEngineMonitor::EPEMessageTempClirActivationUnsuccessful:
case MEngineMonitor::EPEMessageIncCallIsForw: // fall through
--- a/phoneapp/phoneuiutils/inc/phonerssvoip.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuiutils/inc/phonerssvoip.h Wed Apr 14 15:56:42 2010 +0300
@@ -89,6 +89,8 @@
EPhoneVoIPCallsNotSupported,
EPhoneVoIPNotAvailableWhenConnecting,
EPhoneVoIPDefectiveSettings,
+ EPhoneVoIPTransferCallBackHeader,
+ EPhoneVoIPTransferCallBackText,
// Last
EPhoneVoIPLast
};
--- a/phoneapp/phoneuiview/inc/cphonetoolbarcontroller.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuiview/inc/cphonetoolbarcontroller.h Wed Apr 14 15:56:42 2010 +0300
@@ -72,6 +72,10 @@
void SetIhfFlag( TPhoneCommandParam* aCommandParam );
+ void SetWiredAccFlag( TPhoneCommandParam* aCommandParam );
+
+ void SetCallInProgressFlag( TPhoneCommandParam* aCommandParam );
+
/**
* Dims (greys out) or undims all toolbar items.
*
@@ -110,7 +114,15 @@
* @param aToolbar The toolbar object pointer
*/
void DynInitToolbarL( TInt aResourceId, CAknToolbar* aToolbar );
-
+
+protected:
+ /**
+ * Constructor.
+ *
+ * @param aCoeEnv
+ */
+ CPhoneToolbarController( CCoeEnv& aCoeEnv );
+
private:
/**
@@ -131,12 +143,6 @@
/**
- * Constructor.
- *
- * @param aCoeEnv
- */
- CPhoneToolbarController( CCoeEnv& aCoeEnv );
- /**
* Symbian 2nd phase constructor.
*
*/
@@ -169,6 +175,10 @@
TBool iMuteFlag;
TBool iIhfFlag;
+
+ TBool iWiredAccFlag;
+
+ TBool iCallInProgress;
};
--- a/phoneapp/phoneuiview/src/cphonebuttonscontroller.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuiview/src/cphonebuttonscontroller.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -908,16 +908,6 @@
frameId = KAknsIIDQsnFrButtonNormalReject;
break;
}
- case EPhoneInCallCmdHold:
- {
- frameId = KAknsIIDQsnFrButtonNormalHold;
- break;
- }
- case EPhoneInCallCmdUnhold:
- {
- frameId = KAknsIIDQsnFrButtonNormalHold;
- break;
- }
case EPhoneInCallCmdEndThisOutgoingCall:
{
frameId = KAknsIIDQsnFrButtonNormalReject;
--- a/phoneapp/phoneuiview/src/cphonemenucontroller.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuiview/src/cphonemenucontroller.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -553,7 +553,18 @@
}
}
break;
-
+
+ case EPhoneDialerCmdHelp: // Fall through
+ case EPhoneDialerCmdHelpDtmf: // Fall through
+ case EPhoneInCallCmdHelp:
+ {
+ if ( iSecurityMode )
+ {
+ menuPane->DeleteMenuItem( menuItemArray[i] );
+ }
+ }
+ break;
+
default:
break;
--- a/phoneapp/phoneuiview/src/cphonetoolbarcontroller.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuiview/src/cphonetoolbarcontroller.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -30,6 +30,7 @@
#include <phoneappcommands.hrh>
#include <phoneui.mbg>
+#include "tphonecmdparamincallindicatordata.h"
#include "cphonetoolbarcontroller.h"
#include "phoneui.hrh"
#include "phonerssbase.h"
@@ -379,6 +380,61 @@
}
// ---------------------------------------------------------
+// CPhoneMenuController::SetWiredAccFlag
+// ---------------------------------------------------------
+//
+void CPhoneToolbarController::SetWiredAccFlag( TPhoneCommandParam* aCommandParam )
+ {
+ __LOGMETHODSTARTEND( EPhoneUIView, "CPhoneMenuController::SetWiredAccAvailableFlag()" );
+ // Check is the given parameter valid
+ if ( aCommandParam->ParamId() == TPhoneCommandParam::EPhoneParamIdBoolean )
+ {
+ TPhoneCmdParamBoolean* accFlag =
+ static_cast<TPhoneCmdParamBoolean*>( aCommandParam );
+
+ iWiredAccFlag = accFlag->Boolean();
+ if ( iCallInProgress )
+ {
+ SetToolbarButtonDimmed( EPhoneInCallCmdActivateIhf, iWiredAccFlag );
+ UpdateToolbar();
+ }
+ }
+ }
+
+// ---------------------------------------------------------
+// CPhoneToolbarController::SetCallInProgressFlag
+// ---------------------------------------------------------
+//
+void CPhoneToolbarController::SetCallInProgressFlag( TPhoneCommandParam* aCommandParam )
+ {
+ TPhoneCmdParamIncallIndicatorData* param =
+ static_cast<TPhoneCmdParamIncallIndicatorData*>( aCommandParam );
+
+ TInt callState = param->CallState();
+
+ __PHONELOG1( EBasic, EPhoneUIView,
+ "CPhoneToolbarController::SetCallInProgressFlag - Current CallState = (%d)",
+ callState );
+
+ switch ( callState )
+ {
+ case EPSCTsyCallStateUninitialized:
+ case EPSCTsyCallStateNone:
+ {
+ // No active call in progress.
+ iCallInProgress = EFalse;
+ break;
+ }
+ default:
+ {
+ // Active call in progress.
+ iCallInProgress = ETrue;
+ break;
+ }
+ }
+ }
+
+// ---------------------------------------------------------
// CPhoneToolbarController::DimToolbar
// ---------------------------------------------------------
//
@@ -390,8 +446,12 @@
iToolbar->SetItemDimmed( EPhoneInCallCmdMute, aDimmed, ETrue );
iToolbar->SetItemDimmed( EPhoneInCallCmdUnmute, aDimmed, ETrue );
iToolbar->SetItemDimmed( EPhoneInCallCmdActivatEPhonebook, aDimmed, ETrue );
- iToolbar->SetItemDimmed( EPhoneInCallCmdActivateIhf, aDimmed, ETrue );
- iToolbar->SetItemDimmed( EPhoneInCallCmdHandset, aDimmed, ETrue );
+ iToolbar->SetItemDimmed( EPhoneInCallCmdHandset, aDimmed, ETrue );
+ // Don't dim/undim iHF when complete toolbar dimming is changed.
+ if ( !iWiredAccFlag )
+ {
+ iToolbar->SetItemDimmed( EPhoneInCallCmdActivateIhf, aDimmed, ETrue );
+ }
}
// ---------------------------------------------------------
--- a/phoneapp/phoneuiview/src/cphoneviewcontroller.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuiview/src/cphoneviewcontroller.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -877,6 +877,7 @@
iMenuController->CloseMenuBar();
iIncallIndicator->Update( aCommandParam );
iMenuController->SetCallInProgressFlag( aCommandParam );
+ iToolbarController->SetCallInProgressFlag( aCommandParam );
break;
case EPhoneViewStartCapturingKey:
@@ -3226,7 +3227,7 @@
// Wired options
iMenuController->SetWiredAccFlag( &wiredParam );
-
+ iToolbarController->SetWiredAccFlag( &wiredParam );
iMenuController->SetIhfFlag( &ihfParam );
iToolbarController->SetIhfFlag( &ihfParam );
@@ -3268,6 +3269,7 @@
// Wired options
iMenuController->SetWiredAccAvailableFlag( &wiredAvailableParam );
+ iToolbarController->SetWiredAccFlag( &wiredAvailableParam );
// btaa menu options
iMenuController->SetBTAccAvailableFlag( &btAvailableParam );
--- a/phoneapp/phoneuivoipextension/inc/cphoneunattendedtransfercmdhandler.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuivoipextension/inc/cphoneunattendedtransfercmdhandler.h Wed Apr 14 15:56:42 2010 +0300
@@ -64,6 +64,12 @@
* @param aCommand VoIP command identifier.
*/
void HandleCommandL( TInt aCommand );
+
+ /**
+ * Shows call back query in case when transfered call is
+ * not connected
+ */
+ void LaunchCallBackQueryL();
private:
--- a/phoneapp/phoneuivoipextension/src/cphonecustomizationvoip.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuivoipextension/src/cphonecustomizationvoip.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -390,6 +390,8 @@
case EPhoneCmdTransferDialerExit:
case EPhoneCmdTransferDialerSearch:
case EPhoneCmdTransferDialerContactFetch:
+ case EPhoneCmdUnattendedTransferCallBackOk:
+ case EPhoneCmdUnattendedTransferCallBackCancel:
// intended fall-through
iTransferCmdHandler->HandleCommandL( aCommand );
handled = ETrue;
@@ -606,6 +608,11 @@
SendGlobalErrorNoteL( EPhoneRemoteForwarding );
break;
}
+ case MEngineMonitor::EPEMessageTransferCallBackRequest:
+ {
+ iTransferCmdHandler->LaunchCallBackQueryL();
+ break;
+ }
default:
handled = EFalse;
break;
--- a/phoneapp/phoneuivoipextension/src/cphoneresourceresolvervoip.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuivoipextension/src/cphoneresourceresolvervoip.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -299,6 +299,12 @@
case EPhoneVoIPDefectiveSettings:
retVal = R_PHONE_VOIP_CREATING_CONN_FAILED_PERMANENTLY;
break;
+ case EPhoneVoIPTransferCallBackHeader:
+ retVal = R_VOIP_TRANSFER_CALL_BACK_HEADER;
+ break;
+ case EPhoneVoIPTransferCallBackText:
+ retVal = R_VOIP_TRANSFER_CALL_BACK;
+ break;
default:
retVal = CPhoneResourceResolverGSM::ResolveResourceID( aResource );
break;
--- a/phoneapp/phoneuivoipextension/src/cphonestatesinglevoip.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuivoipextension/src/cphonestatesinglevoip.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -380,15 +380,21 @@
MPEEngineInfo* info = iStateMachine->PhoneEngineInfo();
const TPEPhoneNumber& transferTarget =
info->UnattendedTransferTarget( CallId() );
-
+ info->SetIsTransferDial( ETrue );
TUint32 serviceId = iStateMachine->PhoneEngineInfo()->
ServiceId( CallId() );
StateUtils().SelectServiceAndDialL( transferTarget, serviceId );
+
+ // Store transferor address to phoneengine, this is used for
+ // calling back if transfer call fails for some reason
+ info->SetCallBackAddress( info->RemotePhoneNumber( CallId() ) );
}
else
{
iStateMachine->SendPhoneEngineMessage(
MPEPhoneModel::EPEMessageRejectUnattendedTransfer );
+ iStateMachine->PhoneEngineInfo()->SetCallBackAddress(
+ KNullDesC() );
}
}
--- a/phoneapp/phoneuivoipextension/src/cphoneunattendedtransfercmdhandler.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuivoipextension/src/cphoneunattendedtransfercmdhandler.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -17,6 +17,8 @@
#include <featmgr.h>
#include <mpeengineinfo.h>
+#include <StringLoader.h>
+
#include "cphoneunattendedtransfercmdhandler.h"
#include "cphonelogger.h"
@@ -32,6 +34,9 @@
#include "tphonecmdparamquery.h"
#include "tphonecmdparamglobalnote.h"
#include "cphonemainresourceresolver.h"
+#include "cphonestatemachinevoip.h"
+#include "cphonestateutilsvoip.h"
+
// ======== MEMBER FUNCTIONS ========
@@ -147,7 +152,23 @@
}
}
break;
-
+ case EPhoneCmdUnattendedTransferCallBackOk:
+ {
+ MPEEngineInfo* info = iStateMachine.PhoneEngineInfo();
+ const TDesC& callBackToAddr = info->CallBackAddress();
+ // Service id used for last call is used to call back
+ TUint32 serviceId = info->ServiceIdCommand();
+ static_cast<CPhoneStateMachineVoIP&>(
+ iStateMachine ).StateUtils().SelectServiceAndDialL(
+ callBackToAddr, serviceId );
+ }
+ break;
+ case EPhoneCmdUnattendedTransferCallBackCancel:
+ {
+ MPEEngineInfo* info = iStateMachine.PhoneEngineInfo();
+ info->SetCallBackAddress( KNullDesC );
+ }
+ break;
default:
__PHONELOG( EOnlyFatal, PhoneUIVoIPExtension,
"CPhoneUnattendedTransferCmdHandler::HandleCommandL, DEFAULT" );
@@ -322,3 +343,48 @@
iViewCommandHandle.ExecuteCommandL(
EPhoneViewShowGlobalNote, &globalNoteParam );
}
+
+// ---------------------------------------------------------------------------
+// CPhoneUnattendedTransferCmdHandler::LaunchCallBackQuery
+// ---------------------------------------------------------------------------
+//
+void CPhoneUnattendedTransferCmdHandler::LaunchCallBackQueryL()
+ {
+ __LOGMETHODSTARTEND( PhoneUIVoIPExtension,
+ "CPhoneUnattendedTransferCmdHandler::LaunchCallBackQueryL() ")
+ MPEEngineInfo* info = iStateMachine.PhoneEngineInfo();
+ const TDesC& callBackToAddr = info->CallBackAddress();
+ // We cannot do call back if original call had private address
+ if ( callBackToAddr.Compare( KNullDesC ) == 0 )
+ {
+ return;
+ }
+
+ TPhoneCmdParamQuery queryParam;
+ queryParam.SetQueryType( EPhoneGlobalMsgQuery );
+
+ HBufC* msgHeader =
+ StringLoader::LoadLC( CPhoneMainResourceResolver::Instance()->
+ ResolveResourceID( EPhoneVoIPTransferCallBackHeader ) );
+ queryParam.SetQueryPrompt( *msgHeader );
+
+ HBufC* queryText =
+ StringLoader::LoadLC( CPhoneMainResourceResolver::Instance()->
+ ResolveResourceID(
+ EPhoneVoIPTransferCallBackText ), callBackToAddr );
+
+ queryParam.SetDataText( &queryText->Des() );
+
+ queryParam.SetDefaultCba( R_AVKON_SOFTKEYS_OK_CANCEL );
+
+ // configure custom command mappings for user responses
+ queryParam.SetCbaCommandMapping(
+ EAknSoftkeyOk, EPhoneCmdUnattendedTransferCallBackOk );
+ queryParam.SetCbaCommandMapping(
+ EAknSoftkeyCancel, EPhoneCmdUnattendedTransferCallBackCancel );
+
+ iViewCommandHandle.ExecuteCommandL( EPhoneViewShowQuery, &queryParam );
+
+ CleanupStack::PopAndDestroy( queryText );
+ CleanupStack::PopAndDestroy( msgHeader );
+ }
--- a/phoneapp/phoneuivoipextension/srcdata/phoneuivoip.rss Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneapp/phoneuivoipextension/srcdata/phoneuivoip.rss Wed Apr 14 15:56:42 2010 +0300
@@ -1391,6 +1391,28 @@
{
buf = qtn_call_sub_voip_with_name;
}
+
+//-----------------------------------------------------------------------------
+//
+// r_voip_transfer_call_back "Call back to\n%U"
+//
+// -----------------------------------------------------------------------------
+//
+RESOURCE TBUF r_voip_transfer_call_back
+ {
+ buf = qtn_voip_transfer_call_back;
+ }
+
+//-----------------------------------------------------------------------------
+//
+// r_voip_transfer_call_back_header "Call back request:"
+//
+// -----------------------------------------------------------------------------
+//
+RESOURCE TBUF r_voip_transfer_call_back_header
+ {
+ buf = qtn_voip_transfer_call_back_header;
+ }
// End of File
--- a/phoneengine/PhoneCntFinder/ContactService/inc/CPhCntContact.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/PhoneCntFinder/ContactService/inc/CPhCntContact.h Wed Apr 14 15:56:42 2010 +0300
@@ -20,7 +20,7 @@
#define CPHCNTCONTACT_H
#include <e32base.h>
-#include "MPhCntMatch.h"
+#include "mphcntmatch.h"
#include "tphcntnumber.h"
class MPhCntContactFields;
@@ -333,4 +333,4 @@
CCntRawPhoneNumberExtractor* iNumberExtractor;
};
-#endif // CPHCNTCONTACT_H
\ No newline at end of file
+#endif // CPHCNTCONTACT_H
--- a/phoneengine/PhoneCntFinder/ContactService/inc/cphcntcontactdataselection.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/PhoneCntFinder/ContactService/inc/cphcntcontactdataselection.h Wed Apr 14 15:56:42 2010 +0300
@@ -20,7 +20,7 @@
#define CPHCNTCONTACTDATASELECTION_H
#include <e32base.h>
-#include "MPhCntMatch.h"
+#include "mphcntmatch.h"
NONSHARABLE_CLASS( CPhCntSelectedData ) : public CBase
{
--- a/phoneengine/PhoneCntFinder/ContactService/inc/cphcntcontactdataselectionimpl.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/PhoneCntFinder/ContactService/inc/cphcntcontactdataselectionimpl.h Wed Apr 14 15:56:42 2010 +0300
@@ -25,7 +25,7 @@
#include "tphcntcontactlinkresult.h"
#include "mphcntaiwservice.h"
#include "MPhCntContactFetchObserver.h"
-#include "MPhCntMatch.h"
+#include "mphcntmatch.h"
class MPhCntServiceRequestParamFactory;
class MPhCntServiceRequestParam;
--- a/phoneengine/PhoneCntFinder/ContactService/inc/cphcntcontactfieldsresolver.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/PhoneCntFinder/ContactService/inc/cphcntcontactfieldsresolver.h Wed Apr 14 15:56:42 2010 +0300
@@ -23,7 +23,7 @@
#include <e32base.h>
#include "tphcntcontactfield.h"
-#include "MPhCntMatch.h"
+#include "mphcntmatch.h"
#include "mphcntcontactfields.h"
class MVPbkContactLink;
--- a/phoneengine/PhoneCntFinder/ContactService/inc/mphcntcontactfields.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/PhoneCntFinder/ContactService/inc/mphcntcontactfields.h Wed Apr 14 15:56:42 2010 +0300
@@ -19,7 +19,7 @@
#define MPHCNTCONTACTFIELDS_H
#include <e32std.h>
-#include "MPhCntMatch.h"
+#include "mphcntmatch.h"
#include "tphcntnumber.h"
class MVPbkContactLinkArray;
--- a/phoneengine/PhoneCntFinder/ContactService/inc/tphcntcontactfield.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/PhoneCntFinder/ContactService/inc/tphcntcontactfield.h Wed Apr 14 15:56:42 2010 +0300
@@ -21,7 +21,7 @@
#include <e32base.h>
#include <TVPbkFieldVersitProperty.h>
-#include "MPhCntMatch.h"
+#include "mphcntmatch.h"
#include "tphcntnumber.h"
class MPhCntContactManager;
--- a/phoneengine/PhoneCntFinder/ContactService/inc/tphcntnumber.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/PhoneCntFinder/ContactService/inc/tphcntnumber.h Wed Apr 14 15:56:42 2010 +0300
@@ -21,7 +21,7 @@
#include <e32std.h>
-#include "MPhCntMatch.h"
+#include "mphcntmatch.h"
/**
* Represents phone number.
--- a/phoneengine/PhoneCntFinder/ContactService/src/cphcntmatchervoipimpl.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/PhoneCntFinder/ContactService/src/cphcntmatchervoipimpl.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -27,7 +27,7 @@
#include "cphcntmatchcontact.h"
#include "cphcntvoipcontactmatchstrategy.h"
#include "tphcntvoipmatchArray.h"
-#include "MPhCntMatch.h"
+#include "mphcntmatch.h"
#include "CPhCntContact.h"
#include "cphcntvpbkcontactid.h"
#include "cphcntfetchcontact.h"
--- a/phoneengine/PhoneCntFinder/Group/bld.inf Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/PhoneCntFinder/Group/bld.inf Wed Apr 14 15:56:42 2010 +0300
@@ -23,12 +23,12 @@
PRJ_EXPORTS
../inc/CPhoneCntFactory.h |../../../inc/cphonecntfactory.h
../inc/CPhoneCntSaveAddToName.h |../../../inc/cphonecntsaveaddtoname.h
-../inc/MPhCntMatch.h |../../../inc/mphcntmatch.h
+../inc/mphcntmatch.h |../../../inc/mphcntmatch.h
../inc/CPhCntMatcher.h |../../../inc/cphcntmatcher.h
../inc/cphcntcontactid.h |../../../inc/cphcntcontactid.h
../inc/Misc/CPhCntSingleItemFetch.h |../../../inc/cphcntsingleitemfetch.h
-../inc/Misc/CPhCntThumbnailLoader.h |../../../inc/cphcntthumbnailloader.h
+../inc/Misc/cphcntthumbnailloader.h |../../../inc/cphcntthumbnailloader.h
../inc/Misc/MPhCntThumbnailLoaderObserver.h |../../../inc/mphcntthumbnailloaderobserver.h
../inc/Misc/CPhCntSpeedDialMonitor.h |../../../inc/cphcntspeeddialmonitor.h
../inc/Misc/CPhCntRfsHandler.h |../../../inc/cphcntrfshandler.h
--- a/phoneengine/PhoneCntFinder/inc/CPhCntMatch.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/PhoneCntFinder/inc/CPhCntMatch.h Wed Apr 14 15:56:42 2010 +0300
@@ -20,7 +20,7 @@
#define CPHCNTMATCH_H
// INCLUDES
-#include "MPhCntMatch.h"
+#include "mphcntmatch.h"
// FORWARD DECLARATIONS
class CPhCntMatchItem;
--- a/phoneengine/PhoneCntFinder/inc/CPhCntMatchItem.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/PhoneCntFinder/inc/CPhCntMatchItem.h Wed Apr 14 15:56:42 2010 +0300
@@ -24,7 +24,7 @@
#include <CNTDEF.H> // TContactItemId
#include "CPhCntMatcher.h" // TFieldId
-#include "MPhCntMatch.h" // TPhCCliType
+#include "mphcntmatch.h" // TPhCCliType
// CONSTANTS
--- a/phoneengine/PhoneCntFinder/inc/Misc/CPhCntThumbnailLoaderImpl.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/PhoneCntFinder/inc/Misc/CPhCntThumbnailLoaderImpl.h Wed Apr 14 15:56:42 2010 +0300
@@ -20,7 +20,7 @@
#define CPHCNTTHUMBNAILLOADERIMPL_H
// INCLUDES
-#include "CPhCntThumbnailLoader.h"
+#include "cphcntthumbnailloader.h"
#include "mphcntthumbnailloader.h"
// FORWARD DECLARATIONS
--- a/phoneengine/PhoneCntFinder/inc/Misc/MPhCntThumbnailLoaderObserver.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/PhoneCntFinder/inc/Misc/MPhCntThumbnailLoaderObserver.h Wed Apr 14 15:56:42 2010 +0300
@@ -21,7 +21,7 @@
// INCLUDES
#include <e32base.h>
-#include "CPhCntThumbnailLoader.h"
+#include "cphcntthumbnailloader.h"
// FORWARD DECLARATIONS
class CFbsBitmap;
--- a/phoneengine/engineinfo/inc/cpecallinfo.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/engineinfo/inc/cpecallinfo.h Wed Apr 14 15:56:42 2010 +0300
@@ -465,6 +465,16 @@
*/
TPECallOrigin CallOrigin() const;
+ /**
+ * Sets transfer call back flag.
+ */
+ void SetDoCallBackRequest( TBool aDoCallBack );
+
+ /**
+ * Returns transfer call back flag.
+ */
+ TBool DoCallBackRequest() const;
+
private:
/**
@@ -634,6 +644,11 @@
* Origin of the call.
*/
TPECallOrigin iCallOrigin;
+
+ /**
+ * Flag which indicates if call back request is needed
+ */
+ TBool iDoCallBackRequest;
};
#endif // C_CPECALLINFO_H
--- a/phoneengine/engineinfo/inc/cpeengineinfoimpl.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/engineinfo/inc/cpeengineinfoimpl.h Wed Apr 14 15:56:42 2010 +0300
@@ -53,6 +53,7 @@
TPEPhoneNumber iSwitchToNumber; // Dialed Phonenumber, set by client
TPEPhoneNumber iTransferToAddress; // Unattended transfer target address
TInt iForwardToAddressIndex; // Array index for a address to be forwarded
+ TBool iTransferDial; // Flag which indicates utransfer dial
};
NONSHARABLE_STRUCT( TPEBasicInfo ) // Contains information of the phone related variables
@@ -90,6 +91,7 @@
TBool iSecureSpecified; // Secure specified status
TName iDataPortName; // the name of data port currently on-loan
TBool iSwitchToOngoing; // Switch to operation status
+ TPEPhoneNumber iCallBackAddress; // Address of the transfer originator used for calling back
};
NONSHARABLE_STRUCT( TPEConferenceCallInfo ) // Contains conference call related variables
@@ -621,6 +623,30 @@
* @param aCallState state to be checked.
*/
TBool CheckIfCallStateExists( const TPEState& aCallState );
+
+ /**
+ * From base class MPEEngineInfo
+ * @see MPEEngineInfo::SetTransferDial
+ */
+ void SetIsTransferDial( TBool aTransferDial );
+
+ /**
+ * From base class MPEEngineInfo
+ * @see MPEEngineInfo::IsTransferDial
+ */
+ TBool IsTransferDial() const;
+
+ /**
+ * From base class MPEEngineInfo
+ * @see MPEEngineInfo::SetCallBackAddress
+ */
+ void SetCallBackAddress( const TDesC& aAddress );
+
+ /**
+ * From base class MPEEngineInfo
+ * @see MPEEngineInfo::CallBackAddress
+ */
+ const TDesC& CallBackAddress() const;
// Functions from MPEDataStore (reading values)
public:
@@ -925,6 +951,12 @@
* @see MPEDataStore::CallIndex
*/
TInt CallIndex( TInt aCallId ) const;
+
+ /**
+ * From base class MPEDataStore
+ * @see MPEDataStore::DoCallBackRequest
+ */
+ TBool DoCallBackRequest( TInt aCallId ) const;
// Functions from MPEDataStore (setting values)
public:
@@ -1529,6 +1561,12 @@
* @see MPEDataStore::SetCallOrigin
*/
void SetCallOrigin( TPECallOrigin aOrigin, TInt aCallId );
+
+ /**
+ * From base class MPEDataStore
+ * @see MPEDataStore::SetDoCallBackRequest
+ */
+ void SetDoCallBackRequest( TBool aDoCallBack, TInt aCallId );
private:
/**
--- a/phoneengine/engineinfo/inc/mpedatastore.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/engineinfo/inc/mpedatastore.h Wed Apr 14 15:56:42 2010 +0300
@@ -816,6 +816,18 @@
* @param aOrigin indicates if the call is phone, client or SAT originated
*/
virtual void SetCallOrigin( TPECallOrigin aOrigin, TInt aCallId ) = 0;
+
+ /**
+ * Sets flag indicating whether this is unattended transfer dial
+ * @param aTransferDial ETrue if voip unattended transfer dial was initiated
+ */
+ virtual void SetDoCallBackRequest( TBool aDoCallBack, TInt aCallId ) = 0;
+
+ /**
+ * Returns flag indicating whether call back request is needed
+ * @param aCallId
+ */
+ virtual TBool DoCallBackRequest( TInt aCallId ) const = 0;
};
--- a/phoneengine/engineinfo/inc/mpeengineinfo.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/engineinfo/inc/mpeengineinfo.h Wed Apr 14 15:56:42 2010 +0300
@@ -698,6 +698,28 @@
*/
virtual TPECallOrigin CallOrigin( const TInt aCallId ) const = 0;
+ /**
+ * Sets flag indicating unattended transfer dial
+ * @param aTransferDial ETrue if voip unattended transfer dial was initiated
+ */
+ virtual void SetIsTransferDial( TBool aTransferDial ) = 0;
+
+ /**
+ * Returns flag indicating unattended transfer dial
+ */
+ virtual TBool IsTransferDial() const = 0;
+
+ /**
+ * Sets unattended transfer call back address
+ * @param aAddress Unattended transfer call back address
+ */
+ virtual void SetCallBackAddress( const TDesC& aAddress ) = 0;
+
+ /**
+ * Returns unattended transfer call back address
+ */
+ virtual const TDesC& CallBackAddress() const = 0;
+
}; // MPEEngineInfo
#endif //MPEENGINEINFO_H
--- a/phoneengine/engineinfo/src/cpecallinfo.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/engineinfo/src/cpecallinfo.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -106,6 +106,7 @@
iDtmfPostFix = KNullDesC;
iForwardAddressChoices = NULL;
iCallIndex = KPEInvalidCallIndex;
+ iDoCallBackRequest = EFalse;
}
// ---------------------------------------------------------------------------
@@ -649,6 +650,24 @@
{
return iCallOrigin;
}
+
+// ---------------------------------------------------------------------------
+// Sets flag indicating if unattended transfer call back request is needed
+// ---------------------------------------------------------------------------
+//
+void CPECallInfo::SetDoCallBackRequest( TBool aDoCallBack )
+ {
+ iDoCallBackRequest = aDoCallBack;
+ }
+
+// ---------------------------------------------------------------------------
+// Gets flag indicating if unattended transfer call back request is needed
+// ---------------------------------------------------------------------------
+//
+TBool CPECallInfo::DoCallBackRequest() const
+ {
+ return iDoCallBackRequest;
+ }
// End of File
--- a/phoneengine/engineinfo/src/cpeengineinfoimpl.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/engineinfo/src/cpeengineinfoimpl.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -44,6 +44,12 @@
iCallCommandInfo.iDtmfString = KNullDesC;
iCallCommandInfo.iCallType = EPECallTypeUninitialized;
iCallCommandInfo.iServiceId = 0;
+ iCallCommandInfo.iIdRestrict = RMobileCall::EIdRestrictDefault;
+ iCallCommandInfo.iEmergencyNumber = KNullDesC;
+ iCallCommandInfo.iTransferToAddress = KNullDesC;
+ iCallCommandInfo.iForwardToAddressIndex = ECCPErrorNotFound;
+ iCallCommandInfo.iTransferDial = EFalse;
+
iBasicInfo.iAudioOutputPreference = EPSAudioPrivate;
iBasicInfo.iALSLine = CCCECallParameters::ECCELineTypePrimary;
iBasicInfo.iALSLineSupport = EFalse;
@@ -69,14 +75,7 @@
iBasicInfo.iTwoDigitSupportStatus = EFalse;
iBasicInfo.iLifeTimeData.iHours = 0;
iBasicInfo.iLifeTimeData.iMinutes = 0;
-
iBasicInfo.iNetworkRegistrationStatus = ENWStatusRegistrationUnknown;
-
- iCallCommandInfo.iIdRestrict = RMobileCall::EIdRestrictDefault;
- iCallCommandInfo.iEmergencyNumber = KNullDesC;
-
- iCallCommandInfo.iTransferToAddress = KNullDesC;
- iCallCommandInfo.iForwardToAddressIndex = ECCPErrorNotFound;
iBasicInfo.iActiveForward.iActiveType = RMobilePhone::ECFUnconditionalActive;
iBasicInfo.iActiveForward.iServiceGroup = RMobilePhone::EServiceUnspecified;
iBasicInfo.iBarringInfo.iGroupCount = KPENumberInitValue;
@@ -98,6 +97,7 @@
iBasicInfo.iSecureSpecified = ETrue;
iBasicInfo.iDataPortName = KNullDesC;
iBasicInfo.iSwitchToOngoing = EFalse;
+ iBasicInfo.iCallBackAddress = KNullDesC;
iConferenceCallInfo.iConferenceCallState = EPEStateConferenceIdle;
}
@@ -663,6 +663,70 @@
{
return iCallCommandInfo.iCallOrigin;
}
+
+// -----------------------------------------------------------------------------
+// CPEEngineInfoImpl::SetTransferDial
+// Sets flag indicating unattended transfer dial
+// -----------------------------------------------------------------------------
+//
+void CPEEngineInfoImpl::SetIsTransferDial( TBool aTransferDial )
+ {
+ iCallCommandInfo.iTransferDial = aTransferDial;
+ }
+
+// -----------------------------------------------------------------------------
+// CPEEngineInfoImpl::IsTransferDial
+// Gets flag indicating unattended transfer dial
+// -----------------------------------------------------------------------------
+//
+TBool CPEEngineInfoImpl::IsTransferDial() const
+ {
+ return iCallCommandInfo.iTransferDial;
+ }
+
+// -----------------------------------------------------------------------------
+// CPEEngineInfoImpl::SetDoCallBackRequest
+// Sets flag indicating if unattended transfer call back request is needed
+// -----------------------------------------------------------------------------
+//
+void CPEEngineInfoImpl::SetDoCallBackRequest( TBool aDoCallBack, TInt aCallId )
+ {
+ __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
+ iCurrentCalls[ aCallId ]->SetDoCallBackRequest( aDoCallBack );
+ }
+
+// -----------------------------------------------------------------------------
+// CPEEngineInfoImpl::DoCallBackRequest
+// Gets flag indicating if unattended transfer call back request is needed
+// -----------------------------------------------------------------------------
+//
+TBool CPEEngineInfoImpl::DoCallBackRequest( TInt aCallId) const
+ {
+ __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
+ return iCurrentCalls[ aCallId ]->DoCallBackRequest();
+ }
+
+// -----------------------------------------------------------------------------
+// CPEEngineInfoImpl::SetCallBackAddress
+// Sets address used for calling back to transfer originator
+// in case when transfer call has been failed
+// -----------------------------------------------------------------------------
+//
+void CPEEngineInfoImpl::SetCallBackAddress( const TDesC& aAddress )
+ {
+ iBasicInfo.iCallBackAddress = aAddress;
+ }
+
+// -----------------------------------------------------------------------------
+// CPEEngineInfoImpl::CallBackAddress
+// Gets address used for calling back to transfer originator
+// in case when transfer call has been failed
+// -----------------------------------------------------------------------------
+//
+const TDesC& CPEEngineInfoImpl::CallBackAddress() const
+ {
+ return iBasicInfo.iCallBackAddress;
+ }
// CPEEngineInfoImpl::ProfileId
// Gets the profile id from the TPEBasicInfo structure.
--- a/phoneengine/phonemodel/inc/pevirtualengine.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/phonemodel/inc/pevirtualengine.h Wed Apr 14 15:56:42 2010 +0300
@@ -421,6 +421,7 @@
EPEMessageMovedPermanently,
EPEMessageMultipleChoices,
EPEMessageColpNumberAvailable,
+ EPEMessageTransferCallBackRequest,
// Contact messages 3000 - 3999
EPEMessageThumbnailLoadingCompleted = 3000,
--- a/phoneengine/phonemodel/src/cpemessagehandler.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/phonemodel/src/cpemessagehandler.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -1743,13 +1743,17 @@
errorCode = HandleSendDtmf();
}
}
-
+ // Reset unattended transfer callback flag
+ iDataStore.SetDoCallBackRequest( EFalse, aCallId );
+
iDataStore.SetErrorCode( errorCode );
- }
- }
+ }
+ }
// For Sat call ( normal or emergency )
iClientServices->CallRequestMonitor()->SendRespond( ECCPErrorNone );
+
+
// Reset Phonenumber from engine info, this is necessary so that call number
// logging works OK (see CPEMessageHandler::SetPhoneNumberForCallLogging).
iDataStore.SetPhoneNumber( KNullDesC() );
@@ -2186,6 +2190,11 @@
numberOfCalls );
}
+ if ( iDataStore.DoCallBackRequest( aCallId ) )
+ {
+ iModel.SendMessage( MEngineMonitor::EPEMessageTransferCallBackRequest, aCallId );
+ }
+
iDataStore.ResetCallInfo( aCallId );
//publish remote party info to Mediator after call info has been cleared.
--- a/phoneengine/phonemodel/src/cpeparservoipnumberhandler.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/phonemodel/src/cpeparservoipnumberhandler.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -175,6 +175,12 @@
// DialCall method will set call origin as unknow
TInt errorCode = iCallHandling.DialCall( phoneNumber, callId );
+ if ( iDataStore.IsTransferDial() )
+ {
+ iDataStore.SetDoCallBackRequest( ETrue, callId );
+ iDataStore.SetIsTransferDial( EFalse );
+ }
+
// Set dtmf string to dataStore
iDataStore.SetDtmfPostFix( iDtmfString, callId );
--- a/phoneengine/phonemodel/src/cpephonemodel.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneengine/phonemodel/src/cpephonemodel.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -481,7 +481,9 @@
return MESSAGE("EPEMessageConnectingWithInband");
case MEngineMonitor::EPEMessageColpNumberAvailable:
return MESSAGE("EPEMessageColpNumberAvailable");
-
+ case MEngineMonitor::EPEMessageTransferCallBackRequest:
+ return MESSAGE("EPEMessageTransferCallBackRequest");
+
// Contact messages 3000 - 3999
case MEngineMonitor::EPEMessageThumbnailLoadingCompleted:
return MESSAGE("EPEMessageThumbnailLoadingCompleted");
@@ -1239,6 +1241,11 @@
sendingDelayed = ETrue;
}
break;
+ case MEngineMonitor::EPEMessageTransferCallBackRequest:
+ {
+ sendingDelayed = ETrue;
+ }
+ break;
default:
// Other messages cause no action.
break;
--- a/phoneuis/BubbleManager/Src/BMBubbleOutlookBottom.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/Src/BMBubbleOutlookBottom.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -370,15 +370,7 @@
outerRect,
innerRect,
iBubble );
-
- // Add transparency
- BubbleUtils::AddTransparencyToBubbleImageL(
- coMaskFrameId,
- outerRect,
- innerRect,
- iBubble );
-
-
+
break;
}
default:
--- a/phoneuis/BubbleManager/Src/BMBubbleOutlookBottomImCnap.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/Src/BMBubbleOutlookBottomImCnap.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -256,14 +256,7 @@
outerRect,
innerRect,
iBubble );
-
- // Add transparency
- BubbleUtils::AddTransparencyToBubbleImageL(
- coMaskFrameId,
- outerRect,
- innerRect,
- iBubble );
-
+
break;
}
default:
--- a/phoneuis/BubbleManager/Src/BMBubbleOutlookBottomImage.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/Src/BMBubbleOutlookBottomImage.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -247,14 +247,7 @@
outerRect,
innerRect,
iBubble );
-
- // Add transparency
- BubbleUtils::AddTransparencyToBubbleImageL(
- coMaskFrameId,
- outerRect,
- innerRect,
- iBubble );
-
+
break;
}
case CBubbleManager::ENone:
--- a/phoneuis/BubbleManager/Src/BMBubbleOutlookBottomRiCnap.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/Src/BMBubbleOutlookBottomRiCnap.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -370,14 +370,7 @@
outerRect,
innerRect,
iBubble );
-
- // Add transparency
- BubbleUtils::AddTransparencyToBubbleImageL(
- coMaskFrameId,
- outerRect,
- innerRect,
- iBubble );
-
+
break;
}
--- a/phoneuis/BubbleManager/Src/BMBubbleOutlookBottomRight.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/Src/BMBubbleOutlookBottomRight.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -362,14 +362,7 @@
outerRect,
innerRect,
iBubble );
-
- // Add transparency
- BubbleUtils::AddTransparencyToBubbleImageL(
- coMaskFrameId,
- outerRect,
- innerRect,
- iBubble );
-
+
break;
}
case CBubbleManager::ENone:
--- a/phoneuis/BubbleManager/Src/BMBubbleOutlookMiddle.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/Src/BMBubbleOutlookMiddle.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -385,14 +385,7 @@
outerRect,
innerRect,
iBubble );
-
- // Add transparency
- BubbleUtils::AddTransparencyToBubbleImageL(
- coMaskFrameId,
- outerRect,
- innerRect,
- iBubble );
-
+
if ( iHeader->CallObjectImage() )
{
BubbleUtils::PrepareCallObjectImageL(
--- a/phoneuis/BubbleManager/Src/BMBubbleOutlookMiddleCnap.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/Src/BMBubbleOutlookMiddleCnap.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -338,14 +338,7 @@
outerRect,
innerRect,
iBubble );
-
- // Add transparency
- BubbleUtils::AddTransparencyToBubbleImageL(
- coMaskFrameId,
- outerRect,
- innerRect,
- iBubble );
-
+
if ( iHeader->CallObjectImage() )
{
BubbleUtils::PrepareCallObjectImageL(
--- a/phoneuis/BubbleManager/Src/BMBubbleOutlookTopLeft.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/Src/BMBubbleOutlookTopLeft.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -243,21 +243,18 @@
BubbleLayout2::BubbleFrameInnerOuterRects( frameRect,
outerRect,
innerRect);
- TAknsItemID coMaskFrameId;
+
if ( callState == CBubbleManager::EOnHold )
{
iFrameId = KAknsIIDQsnFrCall2Bubble;
- coMaskFrameId = KAknsIIDQsnFrCall2BubbleCoMask;
}
else if ( callState == CBubbleManager::EDisconnected )
{
iFrameId = KAknsIIDQsnFrCall2BubbleFirstDisconn;
- coMaskFrameId = KAknsIIDQsnFrCall2BubbleFirstCoMask;
}
else
{
iFrameId = KAknsIIDQsnFrCall2BubbleFirst;
- coMaskFrameId = KAknsIIDQsnFrCall2BubbleFirstCoMask;
}
iOuterRect = outerRect;
@@ -298,14 +295,7 @@
outerRect,
innerRect,
iBubble );
-
- // Add transparency
- BubbleUtils::AddTransparencyToBubbleImageL(
- coMaskFrameId,
- outerRect,
- innerRect,
- iBubble );
-
+
break;
}
case CBubbleManager::ENone:
--- a/phoneuis/BubbleManager/Src/BMBubbleOutlookTopRight.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/Src/BMBubbleOutlookTopRight.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -240,21 +240,18 @@
BubbleLayout2::BubbleFrameInnerOuterRects( frameRect,
outerRect,
innerRect);
- TAknsItemID coMaskFrameId;
+
if ( callState == CBubbleManager::EOnHold )
{
iFrameId = KAknsIIDQsnFrCall2Bubble;
- coMaskFrameId = KAknsIIDQsnFrCall2BubbleCoMask;
}
else if ( callState == CBubbleManager::EDisconnected )
{
iFrameId = KAknsIIDQsnFrCall2BubbleSecondDisconn;
- coMaskFrameId = KAknsIIDQsnFrCall2BubbleSecondCoMask;
}
else
{
iFrameId = KAknsIIDQsnFrCall2BubbleSecond;
- coMaskFrameId = KAknsIIDQsnFrCall2BubbleSecondCoMask;
}
iOuterRect = outerRect;
@@ -296,14 +293,7 @@
outerRect,
innerRect,
iBubble );
-
- // Add transparency
- BubbleUtils::AddTransparencyToBubbleImageL(
- coMaskFrameId,
- outerRect,
- innerRect,
- iBubble );
-
+
break;
}
case CBubbleManager::ENone:
--- a/phoneuis/BubbleManager/Src/BMBubbleOutlookVideo.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/Src/BMBubbleOutlookVideo.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -32,7 +32,7 @@
#include <eikenv.h>
#include <AknsUtils.h>
#include <AknsDrawUtils.h>
-#include <AknLayout2ScalableDef.h>
+#include <aknlayout2scalabledef.h>
#include <layoutmetadata.cdl.h>
--- a/phoneuis/BubbleManager/Src/BMBubbleOutlookVideoCnap.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/Src/BMBubbleOutlookVideoCnap.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -32,7 +32,7 @@
#include <eikenv.h>
#include <AknsUtils.h>
#include <AknsDrawUtils.h>
-#include <AknLayout2ScalableDef.h>
+#include <aknlayout2scalabledef.h>
#include <layoutmetadata.cdl.h>
--- a/phoneuis/BubbleManager/Src/BMTouchPaneButton.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/Src/BMTouchPaneButton.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -376,10 +376,6 @@
{
return KAknsIIDQsnFrButtonPressedReject;
}
- else if( frameId == KAknsIIDQsnFrButtonNormalHold )
- {
- return KAknsIIDQsnFrButtonPressedHold;
- }
else
{
return KAknsIIDQsnFrButtonPressed;
@@ -400,10 +396,6 @@
{
return KAknsIIDQsnFrButtonInactiveReject;
}
- else if( frameId == KAknsIIDQsnFrButtonNormalHold )
- {
- return KAknsIIDQsnFrButtonInactiveHold;
- }
else
{
return KAknsIIDQsnFrButtonInactive;
--- a/phoneuis/BubbleManager/Src/BMUtils.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/Src/BMUtils.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -36,7 +36,7 @@
#include <AknBidiTextUtils.h>
#include <featmgr.h>
#include <aknlayoutscalable_apps.cdl.h>
-#include <AknLayout2ScalableDef.h>
+#include <aknlayout2scalabledef.h>
#include <applayout.cdl.h>
#include <layoutmetadata.cdl.h>
@@ -1489,10 +1489,15 @@
CFbsBitGc* transparencyCtx;
User::LeaveIfError( transparencyDev->CreateContext( transparencyCtx ) );
CleanupStack::PushL( transparencyCtx );
- transparencyCtx->SetBrushColor( KRgbDarkGray );
- transparencyCtx->SetBrushStyle( CGraphicsContext::ESolidBrush );
- transparencyCtx->DrawRect( rect );
-
+ MAknsSkinInstance* skin = AknsUtils::SkinInstance();
+ AknsDrawUtils::DrawFrame( skin,
+ *transparencyCtx,
+ aOuterRect,
+ aInnerRect,
+ aFrameID,
+ KAknsIIDDefault,
+ KAknsDrawParamDefault );
+
CleanupStack::PopAndDestroy( 2, transparencyDev );
// create solid black mask
--- a/phoneuis/BubbleManager/laf/BMLayout.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/laf/BMLayout.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -23,7 +23,7 @@
#include <aknenv.h>
#include <applayout.cdl.h>
#include <AknUtils.h>
-#include <AknLayout2ScalableDef.h>
+#include <aknlayout2scalabledef.h>
#include <aknlayoutscalable_apps.cdl.h>
#include <layoutmetadata.cdl.h>
--- a/phoneuis/BubbleManager/laf/BMLayout.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/laf/BMLayout.h Wed Apr 14 15:56:42 2010 +0300
@@ -23,7 +23,7 @@
// INCLUDES
#include <calslbs.h>
#include <bldvariant.hrh>
-#include <AknLayoutDef.h>
+#include <aknlayoutdef.h>
/**
* Layout coordinates from Application LAF
--- a/phoneuis/BubbleManager/laf/BMLayout2.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/laf/BMLayout2.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -23,7 +23,7 @@
#include <aknenv.h>
#include <applayout.cdl.h>
#include <AknUtils.h>
-#include <AknLayout2ScalableDef.h>
+#include <aknlayout2scalabledef.h>
#include <aknlayoutscalable_apps.cdl.h>
#include <layoutmetadata.cdl.h>
--- a/phoneuis/BubbleManager/laf/BMLayout2.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/laf/BMLayout2.h Wed Apr 14 15:56:42 2010 +0300
@@ -23,7 +23,7 @@
// INCLUDES
#include <calslbs.h>
#include <bldvariant.hrh>
-#include <AknLayoutDef.h>
+#include <aknlayoutdef.h>
/**
* Layout coordinates from Application LAF
--- a/phoneuis/BubbleManager/laf/BMLayout3.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/laf/BMLayout3.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -22,7 +22,7 @@
#include <aknenv.h>
#include <applayout.cdl.h>
#include <AknUtils.h>
-#include <AknLayout2ScalableDef.h>
+#include <aknlayout2scalabledef.h>
#include <aknlayoutscalable_apps.cdl.h>
#include <layoutmetadata.cdl.h>
--- a/phoneuis/BubbleManager/laf/BMLayout3.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/laf/BMLayout3.h Wed Apr 14 15:56:42 2010 +0300
@@ -23,7 +23,7 @@
// INCLUDES
#include <calslbs.h>
#include <bldvariant.hrh>
-#include <AknLayoutDef.h>
+#include <aknlayoutdef.h>
/**
* Call3 (video cli) layout coordinates from Application LAF
--- a/phoneuis/BubbleManager/laf/BMLayout4.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/laf/BMLayout4.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -23,7 +23,7 @@
#include <aknenv.h>
#include <applayout.cdl.h>
#include <AknUtils.h>
-#include <AknLayout2ScalableDef.h>
+#include <aknlayout2scalabledef.h>
#include <aknlayoutscalable_apps.cdl.h>
#include <layoutmetadata.cdl.h>
--- a/phoneuis/BubbleManager/laf/BMLayout4.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/laf/BMLayout4.h Wed Apr 14 15:56:42 2010 +0300
@@ -23,7 +23,7 @@
// INCLUDES
#include <calslbs.h>
#include <bldvariant.hrh>
-#include <AknLayoutDef.h>
+#include <aknlayoutdef.h>
/**
* Layout coordinates from Application LAF
--- a/phoneuis/BubbleManager/laf/BMLayout6.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/laf/BMLayout6.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -22,7 +22,7 @@
#include <aknenv.h>
#include <applayout.cdl.h>
#include <AknUtils.h>
-#include <AknLayout2ScalableDef.h>
+#include <aknlayout2scalabledef.h>
#include <aknlayoutscalable_apps.cdl.h>
#include <layoutmetadata.cdl.h>
--- a/phoneuis/BubbleManager/laf/BMLayout6.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/BubbleManager/laf/BMLayout6.h Wed Apr 14 15:56:42 2010 +0300
@@ -20,7 +20,7 @@
#include <calslbs.h>
#include <bldvariant.hrh>
-#include <AknLayoutDef.h>
+#include <aknlayoutdef.h>
/**
* Layout coordinates from Application LAF
*
--- a/phoneuis/Ussd/src/UssdContainer.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/Ussd/src/UssdContainer.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -450,12 +450,8 @@
newEditor->SetAknEditorInputMode( EAknEditorNumericInputMode );
newEditor->SetAknEditorNumericKeymap( EAknEditorStandardNumberModeKeymap );
- TInt editorFlags = EAknEditorFlagNoT9 | EAknEditorFlagEnableScrollBars;
-
- if ( FeatureManager::FeatureSupported( KFeatureIdJapanese ) )
- {
- editorFlags |= EAknEditorFlagLatinInputModesOnly;
- }
+ TInt editorFlags = EAknEditorFlagNoT9 | EAknEditorFlagEnableScrollBars |
+ EAknEditorFlagLatinInputModesOnly;
if( FeatureManager::FeatureSupported( KFeatureIdPenSupport ) )
{
--- a/phoneuis/Ussd/src/UssdEditorLines.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/Ussd/src/UssdEditorLines.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -53,7 +53,10 @@
// transparency to display the editor window content as background
// for this line-window.
EnableWindowTransparency();
-
+
+ // enabled drag event to editor for highlighting the text.
+ EnableDragEvents();
+
// Create region buffer.
iRegBuf = new ( ELeave ) RRegionBuf< KUssdMaxNumberOfEditorLines >;
--- a/phoneuis/dialer/inc/cdialer.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/dialer/inc/cdialer.h Wed Apr 14 15:56:42 2010 +0300
@@ -412,7 +412,7 @@
* the availability and state of Easy dialing.
*/
void LayoutNumberEntry( const TRect& aParent, TInt aVariety );
-
+
private: // Data
// Keypad container - owned
@@ -424,9 +424,6 @@
// Is Number entry (e.g. dialer) being used at the moment
TBool iIsUsed;
- // Reference to CEikonEnv
- CEikonEnv& iEikEnv;
-
// Resource
TInt iResourceOffset;
--- a/phoneuis/dialer/src/cdialer.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/dialer/src/cdialer.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -50,7 +50,8 @@
_LIT( KDialerResourceFile, "dialer.rsc" );
// number entry, keypad area, easydialing, toolbar
-const TInt KContainedControlsInTelephonyMode = 4;
+const TInt KContainedControlsInTelephonyMode = 4;
+
// ========================= MEMBER FUNCTIONS ================================
@@ -71,7 +72,12 @@
return self;
}
+// -----------------------------------------------------------------------------
+// CDialer::~CDialer
+//
// Destructor
+// -----------------------------------------------------------------------------
+//
EXPORT_C CDialer::~CDialer()
{
DIALER_PRINT("CDialer::~CDialer<");
@@ -131,11 +137,15 @@
DIALER_PRINT("CDialer::ConstructL>");
}
-// Constructor
-CDialer::CDialer( ) :
- iEikEnv( *CEikonEnv::Static() )
+// -----------------------------------------------------------------------------
+// CDialer::CDialer
+//
+// Default constructor
+// -----------------------------------------------------------------------------
+//
+CDialer::CDialer()
{
- // Empty
+ // Empty
}
// -----------------------------------------------------------------------------
@@ -151,8 +161,6 @@
// -----------------------------------------------------------------------------
// CDialer::SetNumberEntryObserver
-//
-//
// -----------------------------------------------------------------------------
//
EXPORT_C void CDialer::SetNumberEntryObserver( MNumberEntryObserver& aObserver )
@@ -653,9 +661,9 @@
path.Append( KDC_RESOURCE_FILES_DIR );
path.Append( KDialerResourceFile );
- RFs &fsSession= iEikEnv.FsSession();
+ RFs& fsSession= ControlEnv()->FsSession();
BaflUtils::NearestLanguageFile( fsSession, path );
- iResourceOffset = iEikEnv.AddResourceFileL( path );
+ iResourceOffset = ControlEnv()->AddResourceFileL( path );
}
// -----------------------------------------------------------------------------
@@ -667,7 +675,7 @@
{
if ( iResourceOffset > 0 )
{
- iEikEnv.DeleteResourceFile( iResourceOffset );
+ ControlEnv()->DeleteResourceFile( iResourceOffset );
iResourceOffset = 0;
}
}
--- a/phoneuis/dialer/src/cdialercontainerbase.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/dialer/src/cdialercontainerbase.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -23,7 +23,7 @@
#include <aknbutton.h>
#include <AknsUtils.h>
#include <AknsDrawUtils.h>
-#include <AknLayout2Def.h>
+#include <aknlayout2def.h>
#include <AknsSkinInstance.h>
#include <AknsControlContext.h>
#include <aknlayoutscalable_apps.cdl.h>
--- a/phoneuis/dialer/src/cdialerkeypadbutton.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/dialer/src/cdialerkeypadbutton.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -195,16 +195,18 @@
if ( iOperationMode == EModeEasyDialing )
{
- // Number layout.
- iNumberLayout.LayoutText( buttonRect,
- AknLayoutScalable_Apps::cell_dia3_key_num_pane_t1( iVariety ) );
- // Use different number layout if key doens't contain any alphabets or icon.
+ // Number layout
+ TAknTextComponentLayout numLayout =
+ AknLayoutScalable_Apps::cell_dia3_key_num_pane_t1( iVariety );
+ // Center the number label if key doens't contain any alphabets or icon.
if ( !icon && !iPrimaryAlphaLabel.Length() && !iSecondaryAlphaLabel.Length() )
{
- iNumberLayout.LayoutText( buttonRect,
- AknLayoutScalable_Apps::cell_dialer2_keypad_pane_t1(),
- iNumberLayout.Font() );
+ // eliminate margins, alignment takes care of correct position
+ numLayout.Setl( 0 );
+ numLayout.Setr( 0 );
+ numLayout.SetJ( 1 ); // ID for center alignment
}
+ iNumberLayout.LayoutText( buttonRect, numLayout );
// Alphabet layout is different if two rows of alphabets are given
if ( iSecondaryAlphaLabel.Length() )
@@ -223,14 +225,20 @@
else if ( iOperationMode == EModeDialer )
{
// Number layout
- iNumberLayout.LayoutText( buttonRect,
- AknLayoutScalable_Apps::cell_dialer2_keypad_pane_t1() );
+ // Center number labels as only numbers are shown
+ TAknTextComponentLayout numLayout =
+ AknLayoutScalable_Apps::cell_dia3_key_num_pane_t1( iVariety );
+ // eliminate margins, alignment takes care of correct position
+ numLayout.Setl( 0 );
+ numLayout.Setr( 0 );
+ numLayout.SetJ( 1 ); // ID for center alignment
+ iNumberLayout.LayoutText( buttonRect, numLayout );
}
else // video mode layout
{
// Number layout
iNumberLayout.LayoutText( buttonRect,
- AknLayoutScalable_Apps::cell_video_dialer_keypad_pane_t1() );
+ AknLayoutScalable_Apps::cell_video_dialer_keypad_pane_t1() );
}
SetIconLayout( buttonRect );
@@ -395,7 +403,7 @@
{
return iScanCode;
}
-
+
// ---------------------------------------------------------------------------
//
// ---------------------------------------------------------------------------
@@ -405,7 +413,6 @@
return iKeyCode;
}
-
// ---------------------------------------------------------------------------
//
// ---------------------------------------------------------------------------
@@ -423,7 +430,6 @@
}
}
-
// ---------------------------------------------------------------------------
//
// ---------------------------------------------------------------------------
@@ -431,40 +437,39 @@
void CDialerKeyPadButton::SetIconLayout( const TRect& aRect )
{
// Calculate icon size and placement.
- TInt iconSize = aRect.Height() * KIconSizePercent / KCent;
+ TInt iconSize = aRect.Height() * KIconSizePercent / KCent;
TInt xMargin = aRect.Width() * KIconMarginXPercent / KCent;
TInt yMargin = aRect.Height() * KIconMarginYPercent / KCent;
// Adapt icon size and vertical margin. If the button has
// already two lines of text, use smaller icon size
- if ( iOperationMode == EModeEasyDialing && iSecondaryAlphaLabel.Length() )
+ if ( iOperationMode == EModeEasyDialing && iSecondaryAlphaLabel.Length() )
{
iconSize = aRect.Height() * KSmallIconSizePercent / KCent;
yMargin = 0;
}
- if ( AknLayoutUtils::LayoutMirrored() )
+ if ( AknLayoutUtils::LayoutMirrored() )
{
iIconRect.SetRect( aRect.iTl.iX + xMargin,
aRect.iTl.iY + yMargin,
aRect.iTl.iX + xMargin + iconSize,
- aRect.iTl.iY + iconSize + yMargin );
+ aRect.iTl.iY + iconSize + yMargin );
}
else
{
iIconRect.SetRect( aRect.iBr.iX - iconSize - xMargin,
aRect.iTl.iY + yMargin,
aRect.iBr.iX - xMargin,
- aRect.iTl.iY + iconSize + yMargin );
+ aRect.iTl.iY + iconSize + yMargin );
}
SetIconSize( iIconRect.Size() );
}
-
// ---------------------------------------------------------------------------
// Update icon when skin is changed
// ---------------------------------------------------------------------------
-//
+//
void CDialerKeyPadButton::UpdateIconL()
{
if ( KDialerNoIcon != iButtonIconId )
@@ -528,5 +533,5 @@
TRAP_IGNORE( UpdateIconL() );
}
}
-
+
// End of File
--- a/phoneuis/dialer/src/cdialerkeypadcontainer.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/dialer/src/cdialerkeypadcontainer.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -27,7 +27,7 @@
#include <AknsSkinInstance.h>
#include <AknsDrawUtils.h>
#include <AknsConstants.h>
-#include <AknLayout2Def.h>
+#include <aknlayout2def.h>
#include <aknlayoutscalable_apps.cdl.h>
#include <layoutmetadata.cdl.h>
#include <data_caging_path_literals.hrh> // for KDC_APP_RESOURCE_DIR
@@ -515,11 +515,15 @@
// This is needed when dialer control disappeares during keypress.
// Last pressed pointer event must be forwarted to framework
// as pointer up event. Thus button is set to unpressed state etc.
+ // This code calls HandlePointerEventL of the parent class instead of this.
+ // If we call this classes HandlePointerEventL, this classes
+ // grab status is not cleared, and later coming EButton1Up events may end
+ // up erroneously to this class, although intended elsewhere.
//
- if ( !aVisible && iButtonPressedDown )
+ if ( !aVisible && iButtonPressedDown && Parent() )
{
iPointerEvent.iType = TPointerEvent::EButton1Up;
- TRAP_IGNORE( HandlePointerEventL( iPointerEvent ) );
+ TRAP_IGNORE( Parent()->HandlePointerEventL( iPointerEvent ) );
}
CCoeControl::MakeVisible( aVisible );
}
@@ -558,11 +562,15 @@
// This is needed when dialer control disappeares during keypress.
// Last pressed pointer event must be forwarted to framework
// as pointer up event. Thus button is set to unpressed state etc.
+ // This code calls HandlePointerEventL of the parent class instead of this.
+ // If we call this classes HandlePointerEventL, this classes
+ // grab status is not cleared, and later coming EButton1Up events may end
+ // up erroneously to this class, although intended elsewhere.
//
- if ( iButtonPressedDown )
+ if ( iButtonPressedDown && Parent() )
{
iPointerEvent.iType = TPointerEvent::EButton1Up;
- TRAP_IGNORE( HandlePointerEventL( iPointerEvent ) );
+ TRAP_IGNORE( Parent()->HandlePointerEventL( iPointerEvent ) );
}
}
--- a/phoneuis/dialer/src/cdialernumberentry.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/dialer/src/cdialernumberentry.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -31,9 +31,9 @@
#include <AknsDrawUtils.h>
#include <applayout.cdl.h>
#include <AknLayoutFont.h>
-#include <AknLayout2Def.h>
+#include <aknlayout2def.h>
#include <AknPhoneNumberEditor.h>
-#include <AknLayout2ScalableDef.h>
+#include <aknlayout2scalabledef.h>
#include <AknsBasicBackgroundControlContext.h>
#include <AknsFrameBackgroundControlContext.h>
#include <aknlayoutscalable_apps.cdl.h>
--- a/phoneuis/dialer/src/cdialerstub.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/dialer/src/cdialerstub.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -40,7 +40,12 @@
return self;
}
+// ---------------------------------------------------------------------------
+// CDialer::~CDialer
+//
// Destructor
+// ---------------------------------------------------------------------------
+//
EXPORT_C CDialer::~CDialer()
{
// Empty
@@ -63,11 +68,15 @@
SetRect( aRect );
}
-// Constructor
-CDialer::CDialer( ) :
- iEikEnv( *CEikonEnv::Static() )
+// ---------------------------------------------------------------------------
+// CDialer::CDialer
+//
+// C++ default constructor
+// ---------------------------------------------------------------------------
+//
+CDialer::CDialer()
{
- // Empty
+ // Empty
}
// -----------------------------------------------------------------------------
@@ -149,8 +158,7 @@
{
// Empty
}
-
-
+
// ---------------------------------------------------------------------------
// CDialer::GetNumberEntry
//
@@ -160,7 +168,7 @@
{
return NULL;
}
-
+
// ---------------------------------------------------------------------------
// CDialer::IsNumberEntryUsed
//
@@ -170,7 +178,7 @@
{
return EFalse;
}
-
+
// ---------------------------------------------------------------------------
// CDialer::SetNumberEntryVisible
//
@@ -181,7 +189,6 @@
// Empty
}
-
// ---------------------------------------------------------------------------
// CDialer::SetTextToNumberEntry
//
@@ -191,7 +198,7 @@
{
// Empty
}
-
+
// ---------------------------------------------------------------------------
// CDialer::GetTextFromNumberEntry
//
@@ -201,7 +208,7 @@
{
aDesC = KNullDesC();
}
-
+
// ---------------------------------------------------------------------------
// CDialer::RemoveNumberEntry
//
@@ -211,7 +218,7 @@
{
iIsUsed = EFalse;
}
-
+
// ---------------------------------------------------------------------------
// CDialer::ChangeEditorMode
//
@@ -221,17 +228,17 @@
{
return KErrNotSupported;
}
-
+
// ---------------------------------------------------------------------------
// CDialer::OpenVKBL
-//
+//
// ---------------------------------------------------------------------------
//
void CDialer::OpenVkbL()
{
// Empty
}
-
+
// ---------------------------------------------------------------------------
// CDialer::GetEditorMode
//
@@ -241,7 +248,7 @@
{
return KErrNotSupported;
}
-
+
// ---------------------------------------------------------------------------
// CDialer::ResetEditorToDefaultValues
//
@@ -251,7 +258,7 @@
{
// Empty
}
-
+
// ---------------------------------------------------------------------------
// CDialer::SetNumberEntryPromptText
//
@@ -260,7 +267,7 @@
void CDialer::SetNumberEntryPromptText( const TDesC& /*aPromptText*/ )
{
// Empty
- }
+ }
// ---------------------------------------------------------------------------
// CDialer::EnableTactileFeedback
@@ -272,7 +279,6 @@
// Empty
}
-
// ---------------------------------------------------------
// CDialer::HandleQwertyModeChange
// ---------------------------------------------------------
@@ -288,8 +294,8 @@
//
EXPORT_C void CDialer::HandleKeyboardLayoutChange()
{
- // Empty
- }
+ // Empty
+ }
// ---------------------------------------------------------------------------
// CDialer::HandleControlEventL
@@ -335,7 +341,6 @@
return 0;
}
-
// ---------------------------------------------------------------------------
// CDialer::ComponentControl(TInt aIndex) const
//
@@ -392,14 +397,14 @@
// Calling base class implementation
CCoeControl::HandlePointerEventL(aPointerEvent);
}
-
+
// ---------------------------------------------------------------------------
// CDialer::MakeVisible
// ---------------------------------------------------------------------------
//
void CDialer::MakeVisible( TBool /*aVisible*/ )
- {
- }
+ {
+ }
// Private methods
@@ -423,7 +428,7 @@
{
// Empty
}
-
+
// ---------------------------------------------------------------------------
// CDialer::ComponentControlForDialerMode
//
@@ -446,7 +451,7 @@
CAknEdwinState* CDialer::EdwinState() const
{
return NULL;
- }
+ }
// ---------------------------------------------------------------------------
// CDialer::UpdateEdwinState
--- a/phoneuis/dialer/src/cdialertoolbarcontainer.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/dialer/src/cdialertoolbarcontainer.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -276,7 +276,7 @@
{
// no implementation needed
}
-
+
// ---------------------------------------------------------------------------
// HandleLosingForeground
//
@@ -286,12 +286,16 @@
{
// This is needed when dialer control disappeares during keypress.
// Last pressed pointer event must be forwarted to framework
- // as pointer up event. Thus button is set to unpressed state etc.
+ // as pointer up event. Thus button is set to unpressed state etc.
+ // This code calls HandlePointerEventL of the parent class instead of this.
+ // If we call this classes HandlePointerEventL, this classes
+ // grab status is not cleared, and later coming EButton1Up events may end
+ // up erroneously to this class, although intended elsewhere.
//
- if ( iLatestPointerEvent.iType != TPointerEvent::EButton1Up )
+ if ( iLatestPointerEvent.iType != TPointerEvent::EButton1Up && Parent() )
{
iLatestPointerEvent.iType = TPointerEvent::EButton1Up;
- TRAP_IGNORE( HandlePointerEventL( iLatestPointerEvent ) );
+ TRAP_IGNORE( Parent()->HandlePointerEventL( iLatestPointerEvent ) );
}
}
@@ -402,15 +406,7 @@
TInt commandId = KErrNotFound;
// Find out index of the button in iButtons array
- TInt btnIndex = KErrNotFound;
- for ( TInt i = 0 ; i < iButtons.Count() ; ++i )
- {
- if ( iButtons[i] == &aButton )
- {
- btnIndex = i;
- i = iButtons.Count(); // to break out of the loop
- }
- }
+ TInt btnIndex = iButtons.Find( &aButton );
__ASSERT_DEBUG( btnIndex >= 0, DialerPanic( EDialerPanicToolbarButtonNotFound ) );
// Find the corresponding command from command array
--- a/phoneuis/dialer/src/cdialervideocontainer.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/dialer/src/cdialervideocontainer.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -27,9 +27,9 @@
#include <AknUtils.h>
#include <AknsDrawUtils.h>
#include <AknLayoutFont.h>
-#include <AknLayout2Def.h>
+#include <aknlayout2def.h>
#include <layoutmetadata.cdl.h>
-#include <AknLayout2ScalableDef.h>
+#include <aknlayout2scalabledef.h>
#include <aknlayoutscalable_apps.cdl.h>
#include <AknsBasicBackgroundControlContext.h>
#include <AknsFrameBackgroundControlContext.h>
--- a/phoneuis/easydialing/inc/easydialinglistbox.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/easydialing/inc/easydialinglistbox.h Wed Apr 14 15:56:42 2010 +0300
@@ -31,6 +31,8 @@
// Easy dialing specific listbox events
const TInt KEasyDialingContactSelected( 0x1001 );
const TInt KEasyDialingContactLongTapped( 0x1002 );
+const TInt KEasyDialingScrollingStarted( 0x1003 );
+const TInt KEasyDialingScrollingStopped( 0x1004 );
// FORWARD DECLARATIONS
@@ -52,7 +54,7 @@
class CEasyDialingListBox : public CEikFormattedCellListBox,
public MAknLongTapDetectorCallBack
- {
+ {
public:
/**
@@ -72,7 +74,7 @@
*/
void ConstructL( TInt aFlags,
CEasyDialingContactDataManager* aContactDataManager );
-
+
/**
* From CEikFormattedCellListBox.
*/
@@ -86,27 +88,32 @@
/**
* From CEikFormattedCellListBox.
*/
- void Draw(const TRect& aRect) const;
+ void Draw( const TRect& aRect ) const;
/**
* From CEikFormattedCellListBox.
*/
- void HandleResourceChange(TInt aType);
+ void HandleResourceChange( TInt aType );
+
+ /**
+ * From CEikFormattedCellListBox.
+ */
+ void HandleScrollEventL( CEikScrollBar* aScrollBar, TEikScrollEvent aEventType );
/**
* From CCoeControl
*/
- void MakeVisible(TBool aVisible);
+ void MakeVisible( TBool aVisible );
/**
* From CCoeControl
*/
- void HandlePointerEventL(const TPointerEvent& aPointerEvent);
+ void HandlePointerEventL( const TPointerEvent& aPointerEvent );
/**
* The the rectangle within which the listbox must always fit.
* @param aMaxRect The largest allowed rect size, given in
- * screen relative coordinate system.
+ * screen relative coordinate system.
*/
void SetMaxRect( TRect aMaxRect );
@@ -125,7 +132,6 @@
* @return Whether the key was handled or not.
*/
TKeyResponse SetFocusedWithKeyEventL( const TKeyEvent& aKeyEvent, TEventCode aType );
-
/**
* Gets the height of the listbox based on the number of items.
@@ -158,7 +164,7 @@
/**
* From CEikFormattedCellListBox.
*/
- virtual void FocusChanged(TDrawNow aDrawNow);
+ virtual void FocusChanged( TDrawNow aDrawNow );
/**
* From CEikFormattedCellListBox.
@@ -173,7 +179,7 @@
/**
* From CCoeControl
*/
- TTypeUid::Ptr MopSupplyObject(TTypeUid aId);
+ TTypeUid::Ptr MopSupplyObject( TTypeUid aId );
private:
@@ -195,8 +201,5 @@
/** Flag set when long pointer press has been handled after latest pointer down event.*/
TBool iPointerLongPressHandled;
};
-
+
#endif // _EASYDIALINGLISTBOX_H
-
-
-
--- a/phoneuis/easydialing/inc/easydialinglistboxdata.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/easydialing/inc/easydialinglistboxdata.h Wed Apr 14 15:56:42 2010 +0300
@@ -157,7 +157,7 @@
* @param aBoundingBox Rectangle containing bounds for contact thumbnail.
* @param aDescId Descriptor containing contact id.
*/
- TBool ContactThumbnailDrawing(
+ TBool DrawContactThumbnail(
CWindowGc& aGc,
TRect aBoundingBox,
TPtrC aDescId) const;
--- a/phoneuis/easydialing/inc/easydialingplugin.h Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/easydialing/inc/easydialingplugin.h Wed Apr 14 15:56:42 2010 +0300
@@ -88,13 +88,13 @@
public MAknInputBlockCancelHandler
{
public:
-
+
/**
* Static constructor.
* @return: Created object.
*/
static CEasyDialingPlugin* NewL();
-
+
/**
* Destructor.
*/
@@ -106,7 +106,7 @@
* From CCoeControl.
*/
TKeyResponse OfferKeyEventL( const TKeyEvent& aKeyEvent, TEventCode aType );
-
+
/**
* From CCoeControl
*/
@@ -123,7 +123,7 @@
void MakeVisible( TBool aVisible );
protected:
-
+
/**
* See CCoeControl
*/
@@ -133,9 +133,9 @@
* See CCoeControl
*/
void FocusChanged( TDrawNow aDrawNow );
-
+
public: // from CDialingExtensionInterface
-
+
/**
* Does further initialization to component.
* @param: parent container of this control.
@@ -170,7 +170,7 @@
* @return: number of matches.
*/
TInt MatchingContactCount();
-
+
/**
* Gets the resource id of plugin's control button area resource.
*
@@ -204,15 +204,15 @@
* @return ETrue if command was handled, EFalse otherwise.
*/
TBool HandleCommandL( TInt aCommand );
-
+
/**
* Tells if extension is currently enabled from settings.
* @return ETrue if extension is enabled, EFalse otherwise.
*/
TBool IsEnabled() const;
-
+
public:
-
+
/**
* From MVPbkContactStoreListObserver.
*/
@@ -268,12 +268,12 @@
* From MEikListBoxObserver.
*/
void HandleListBoxEventL( CEikListBox* aListBox, TListBoxEvent aEventType );
-
+
/**
* From MAknInputBlockCancelHandler.
*/
void AknInputBlockCancel();
-
+
private:
@@ -281,14 +281,14 @@
* Constructor.
*/
CEasyDialingPlugin ();
-
+
/**
* Second phase constructor.
*/
void ConstructL ();
-
+
void InitPredictiveContactSearchL();
-
+
void SetSortOrderL( CEasyDialingContactDataManager::TNameOrder aNameOrder );
/**
@@ -314,7 +314,7 @@
* A leaving function to be trapped in HandlePsResultsUpdate.
*/
void HandlePsResultsUpdateL( RPointerArray<CPsClientData>& aResults, RPointerArray<CPsPattern>& aSeqs );
-
+
public:
/**
@@ -376,8 +376,8 @@
ELaunchSearch,
EInitializePcs
};
-
- /**
+
+ /**
* Initiates asynchronous callback to launch action and sets
* input blocker active.
*/
@@ -413,13 +413,13 @@
* Makes contact listbox invisible. Effect is used if feasible.
*/
void HideContactListBoxWithEffect();
-
-
+
+
private:
/** Textual version of current search string. */
TBuf<KEDMaxSearchStringLength> iSearchString;
-
+
/** Handle to predictive search engine. Owned. */
CPSRequestHandler* iPredictiveContactSearchHandler;
@@ -442,27 +442,27 @@
CVPbkContactManager* iContactManager;
/** Search result field index for first name field. */
- TInt iFirstNamePCSIndex;
+ TInt iFirstNamePCSIndex;
/** Search result field index for last name field. */
- TInt iLastNamePCSIndex;
+ TInt iLastNamePCSIndex;
/** Search result field index for first name field. */
- TInt iCompanyNamePCSIndex;
-
- /** Array containing observers to this class. Owned. */
- RPointerArray<MDialingExtensionObserver> iObservers;
-
- /** Contact listbox. Owned. */
- CEasyDialingListBox* iContactListBox;
-
- /** Listbox model from search results. Owned. */
- CDesCArrayFlat* iListBoxModel;
-
- /** Number of found matching contacts from most recent search. */
- TInt iNumberOfNames;
-
- /** Handle to contact launcher. */
+ TInt iCompanyNamePCSIndex;
+
+ /** Array containing observers to this class. Owned. */
+ RPointerArray<MDialingExtensionObserver> iObservers;
+
+ /** Contact listbox. Owned. */
+ CEasyDialingListBox* iContactListBox;
+
+ /** Listbox model from search results. Owned. */
+ CDesCArrayFlat* iListBoxModel;
+
+ /** Number of found matching contacts from most recent search. */
+ TInt iNumberOfNames;
+
+ /** Handle to contact launcher. */
MCCAConnectionExt* iContactLauncher;
/** ETrue if contact launcher (a.k.a. communication launcher) is open. */
@@ -471,9 +471,9 @@
/** If true, contact listbox must not reset focus when contact launcher exits. */
TBool iRememberFocus;
- /** Working buffer for creating contact string to listbox. */
+ /** Working buffer for creating contact string to listbox. */
TBuf<KEDMaxContactStringLength> iContactStringCreationBuffer;
-
+
/** Central repository listener. Owned. */
CEasyDialingCenrepListener* iCenrepListener;
@@ -482,7 +482,7 @@
/** Easy dialing contactor service. Owned. */
CEDContactorService* iContactorService;
-
+
/** Easy dialing resource file offset in current application. */
TInt iResourceFileOffset;
--- a/phoneuis/easydialing/src/easydialingcontactdatamanager.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/easydialing/src/easydialingcontactdatamanager.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -323,14 +323,17 @@
//
void CEasyDialingContactDataManager::Pause( TBool aPause )
{
- iPause = aPause;
-
- if ( !iPause && iWaitingContacts.Count() )
+ if ( iPause != aPause )
{
- TRAPD( err, LoadNextContactDataL());
- if ( err )
+ iPause = aPause;
+
+ if ( !iPause && iWaitingContacts.Count() )
{
- HandleError(err);
+ TRAPD( err, LoadNextContactDataL());
+ if ( err )
+ {
+ HandleError(err);
+ }
}
}
}
--- a/phoneuis/easydialing/src/easydialinglistbox.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/easydialing/src/easydialinglistbox.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -34,12 +34,8 @@
#include <ccappcommlauncherpluginrsc.rsg>
-// AvKON and drawing header files
-
-#include <aknpointereventsuppressor.h>
#include <aknlongtapdetector.h> // Required for touch
#include <AknsFrameBackgroundControlContext.h>
-#include <AknInfoPopupNoteController.h> // tooltips
#include <aknlayoutscalable_apps.cdl.h>
#include <layoutmetadata.cdl.h>
@@ -170,14 +166,6 @@
{
CEasyDialingListBoxView* view = static_cast<CEasyDialingListBoxView*>( iView );
view->SetCurrentItemIndexToNone();
-
- // Invalidate window area.
- // This fixes the drawing problem that the top
- // of listbox is not always redrawn on the area that overlaps
- // the status pane area.
- // TODO: This overlapping no longer happens in 9.2 so this may
- // now be unnecessary.
- Window().Invalidate();
}
CEikFormattedCellListBox::FocusChanged( aDrawNow );
}
@@ -277,6 +265,10 @@
//
void CEasyDialingListBox::SizeChanged()
{
+ // Note that within this call view rect is adjusted to fit into TGulBorder
+ // that could have been given in construction. It's not used by ED listbox.
+ // The view rect is not correct for ED after this call but it's
+ // calculated and set below.
CEikFormattedCellListBox::SizeChanged();
TRect parentRect = Rect();
@@ -317,8 +309,11 @@
scrollBarRect.SetWidth( 0 );
}
- // Set view rect
- iView->SetViewRect( viewRect );
+ // Must use this method so that all eiklistbox's internal variables are
+ // set and updated according to this viewRect. This call would
+ // add list margins but no such are defined in layouts so view's rect is
+ // set to viewRect calculated here.
+ SetViewRectFromClientRect( viewRect );
// Set scroll bar rect
if ( iSBFrame )
@@ -330,6 +325,8 @@
}
iBGContext->SetFrameRects( parentRect, viewAndScrollBarRect );
+
+ TRAP_IGNORE( CEikFormattedCellListBox::HandleViewRectSizeChangeL() );
}
@@ -492,6 +489,7 @@
}
}
+
// -----------------------------------------------------------------------------
// CurrentContactLinkLC
//
@@ -543,5 +541,42 @@
}
+// -----------------------------------------------------------------------------
+// HandleScrollEventL
+// If the EasyDialingListBox is scrolled by dragging the Scroll bar, this
+// observer function is called
+// -----------------------------------------------------------------------------
+//
+void CEasyDialingListBox::HandleScrollEventL( CEikScrollBar* aScrollBar, TEikScrollEvent aEventType )
+ {
+ // Report scrolling to the listbox observer
+ TInt scrollEvent( KErrNotFound );
+ switch ( aEventType )
+ {
+ case EEikScrollThumbDragVert:
+ scrollEvent = KEasyDialingScrollingStarted;
+ break;
+
+ case EEikScrollThumbReleaseVert:
+ case EEikScrollUp:
+ case EEikScrollDown:
+ case EEikScrollPageUp:
+ case EEikScrollPageDown:
+ scrollEvent = KEasyDialingScrollingStopped;
+ break;
+
+ default:
+ break;
+ }
+
+ if ( scrollEvent != KErrNotFound )
+ {
+ ReportListBoxEventL( static_cast<MEikListBoxObserver::TListBoxEvent>( scrollEvent ) );
+ }
+
+ // Base class(es) might be also interested about the scrollbar events
+ CEikFormattedCellListBox::HandleScrollEventL( aScrollBar, aEventType );
+ }
+
// end of file
--- a/phoneuis/easydialing/src/easydialinglistboxdata.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/easydialing/src/easydialinglistboxdata.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -130,7 +130,7 @@
static TRect ContactNameBoundingBox(
const TRect& aItemRect,
const CFont* aContactNameFont,
- TBool aIsCurrentItem,
+ TBool aArrowIconShown,
TBool aIsFavourite,
TBool aThumbnailsShown );
static TRect CompanyNameBoundingBox(
@@ -181,6 +181,10 @@
TBool aMatch,
const CFont* aFont );
+static CGulIcon* CreateIconL(
+ const TDesC& aFileName,
+ TInt aBitmapId,
+ TInt aMaskId );
// FORWARD DECLARATIONS
@@ -223,7 +227,7 @@
// CEasyDialingListBoxData
//
// -----------------------------------------------------------------------------
-//
+//
CEasyDialingListBoxData::CEasyDialingListBoxData() :
CFormattedCellListBoxData()
{
@@ -233,7 +237,7 @@
// Destructor
//
// -----------------------------------------------------------------------------
-//
+//
CEasyDialingListBoxData::~CEasyDialingListBoxData()
{
// Release fonts. ReleaseFont function can cope with null pointer
@@ -255,7 +259,7 @@
// NewL
//
// -----------------------------------------------------------------------------
-//
+//
CEasyDialingListBoxData* CEasyDialingListBoxData::NewL()
{
CEasyDialingListBoxData* self = new (ELeave) CEasyDialingListBoxData();
@@ -272,7 +276,7 @@
// DrawData
//
// -----------------------------------------------------------------------------
-//
+//
void CEasyDialingListBoxData::DrawData(
const TListItemProperties& aProperties,
CWindowGc& aGc,
@@ -298,7 +302,7 @@
// ConstructLD
//
// -----------------------------------------------------------------------------
-//
+//
void CEasyDialingListBoxData::ConstructLD()
{
CFormattedCellListBoxData::ConstructLD();
@@ -311,35 +315,26 @@
TParse parse;
User::LeaveIfError(parse.Set(KEasyDialingBitmapFile, &dllFileName, NULL));
TFileName bitmapFileName(parse.FullName());
-
- CFbsBitmap* bm;
- CFbsBitmap* mask;
- // iArrowPointingLeft is the icon displayed for the selected item in EasyDialingListBox
- AknIconUtils::CreateIconL( bm, mask, bitmapFileName, EMbmEasydialingQgn_indi_org_arrow_left,
+ // Icon displayed for the selected item in normal layout
+ iArrowPointingRight = CreateIconL( bitmapFileName, EMbmEasydialingQgn_indi_org_arrow_right,
+ EMbmEasydialingQgn_indi_org_arrow_right_mask );
+
+ // Icon displayed for the selected item in mirrored layout
+ iArrowPointingLeft = CreateIconL( bitmapFileName, EMbmEasydialingQgn_indi_org_arrow_left,
EMbmEasydialingQgn_indi_org_arrow_left_mask );
- iArrowPointingLeft = CGulIcon::NewL( bm, mask );
-
- AknIconUtils::CreateIconL( bm, mask, bitmapFileName, EMbmEasydialingQgn_indi_org_arrow_right,
- EMbmEasydialingQgn_indi_org_arrow_right_mask );
-
- iArrowPointingRight = CGulIcon::NewL( bm, mask );
-
- // Only mask for the icons are used. iColorBitmap is used for making the icon
+ // Only mask for the arrow icons are used. iColorBitmap is used for making the icon
// to follow text color changes according to skin.
iColorBitmap = new (ELeave) CFbsBitmap;
- // Contact default thumbnail is not available in themes. It is read from phonebook resource.
- AknIconUtils::CreateIconL( bm, mask, KPhonebook2EceBitmapFile,
+ // Contact default thumbnail is not available in themes. It is read from phonebook resource.
+ iDummyThumbnail = CreateIconL( KPhonebook2EceBitmapFile,
EMbmPhonebook2eceQgn_prop_pb_thumb_unknown, EMbmPhonebook2eceQgn_prop_pb_thumb_unknown_mask );
- iDummyThumbnail = CGulIcon::NewL( bm, mask );
// Create the favourite icon bitmap and mask
- AknIconUtils::CreateIconL( bm, mask, KFavouriteIconBitmapFile,
+ iFavouriteIcon = CreateIconL( KFavouriteIconBitmapFile,
EMbmPhonebook2Qgn_prop_pb_topc, EMbmPhonebook2Qgn_prop_pb_topc_mask );
-
- iFavouriteIcon = CGulIcon::NewL( bm, mask );
}
@@ -347,7 +342,7 @@
// DrawHighlight
//
// -----------------------------------------------------------------------------
-//
+//
void CEasyDialingListBoxData::DrawHighlight( CWindowGc &aGc, const TRect &aItemRect ) const
{
MAknListBoxTfxInternal* transApi = CAknListLoader::TfxApiInternal( &aGc );
@@ -417,7 +412,7 @@
__ASSERT_DEBUG( iContactNameFont, EasyDialingPanic( EEasyDialingNoFontFound ) );
__ASSERT_DEBUG( iCompanyNameFont, EasyDialingPanic( EEasyDialingNoFontFound ) );
- MAknListBoxTfxInternal *transApi = CAknListLoader::TfxApiInternal( &aGc );
+ MAknListBoxTfxInternal* transApi = CAknListLoader::TfxApiInternal( &aGc );
if ( transApi )
{
transApi->StartDrawing( MAknListBoxTfxInternal::EListItem );
@@ -433,15 +428,28 @@
boundingBox = MirrorLayoutBoundingBox( aItemRect, boundingBox );
}
- //Draws the Contact Thumbnail Icon if exists else draws the dummy contact thumbnail
- TBool fav = ContactThumbnailDrawing( aGc, boundingBox, cellText );
+ // Arrow icon is drawn if the item is in focus and listbox has focus
+ // (and not only the temporary visual focus caused by touching a list item).
+ TBool showArrowIcon = aHighlight && iControl->IsFocused();
+ if ( showArrowIcon )
+ {
+ TRect arrowRect = ArrowIconBoundingBox( aItemRect );
+ if ( AknLayoutUtils::LayoutMirrored() )
+ {
+ arrowRect = MirrorLayoutBoundingBox( aItemRect, arrowRect );
+ }
+ DrawArrowIcon( aGc, arrowRect );
+ }
+
+ //Draws the Contact Thumbnail Icon if exists, else draws the dummy contact thumbnail
+ TBool fav = DrawContactThumbnail( aGc, boundingBox, cellText );
error = TextUtils::ColumnText( cellText , 1, aText );
__ASSERT_DEBUG( error == KErrNone, EasyDialingPanic( EEasyDialingPanicInvalidListBoxModelString ) );
boundingBox = ContactNameBoundingBox( aItemRect,
iContactNameFont,
- aHighlight,
+ showArrowIcon,
fav,
iContactDataManager->GetContactThumbnailSetting() );
TRect nameRectUnMirrored = boundingBox; // used for favourite star drawing
@@ -454,18 +462,6 @@
// favourite icon size is set the same as contact name bounding box height.
TInt favouriteIconSize = boundingBox.Height();
- TRect arrowRect = ArrowIconBoundingBox( aItemRect );
- if ( AknLayoutUtils::LayoutMirrored() )
- {
- arrowRect = MirrorLayoutBoundingBox( aItemRect, arrowRect );
- }
-
- // Draw arrow icon if the item is in focus.
- if ( aHighlight )
- {
- DrawArrowIcon( aGc, arrowRect );
- }
-
TInt err( KErrNone );
TRAP( err, DrawTextWithMatchHighlightL(
boundingBox, aGc, cellText, iContactNameFont, aColors, aHighlight ) );
@@ -496,12 +492,13 @@
}
// -----------------------------------------------------------------------------
-// ContactThumbnailDrawing
+// DrawContactThumbnail
//
-// Draws the Contact Thumbnail Icon if any else draws the dummy contact thumbnail
+// Draws the Contact Thumbnail Icon if any, else draws the dummy contact thumbnail
+// Also check if this is a favorite contact and return true if this is.
// -----------------------------------------------------------------------------
-
-TBool CEasyDialingListBoxData::ContactThumbnailDrawing(CWindowGc& aGc, TRect aBoundingBox, TPtrC aCellText) const
+//
+TBool CEasyDialingListBoxData::DrawContactThumbnail(CWindowGc& aGc, TRect aBoundingBox, TPtrC aCellText) const
{
TBool fav(EFalse);
CFbsBitmap* thumbnail(NULL);
@@ -534,6 +531,7 @@
// DrawArrowIcon
// Draws the Action Menu
// -----------------------------------------------------------------------------
+//
void CEasyDialingListBoxData::DrawArrowIcon(
CWindowGc& aGc, TRect aArrowRect) const
{
@@ -561,6 +559,7 @@
//
// Draws the Favourite Icon
// -----------------------------------------------------------------------------
+//
void CEasyDialingListBoxData::DrawFavouriteIcon(
CWindowGc& aGc,
TRect aNameRectUnMirrored,
@@ -596,7 +595,7 @@
// SetContactDataManager
//
// -----------------------------------------------------------------------------
-//
+//
void CEasyDialingListBoxData::SetContactDataManager(CEasyDialingContactDataManager* aContactDataManager)
{
iContactDataManager = aContactDataManager;
@@ -623,7 +622,7 @@
// ObtainFonts
//
// -----------------------------------------------------------------------------
-//
+//
void CEasyDialingListBoxData::ObtainFonts( TInt aItemHeight )
{
CWsScreenDevice& screenDev = *( CEikonEnv::Static()->ScreenDevice() );
@@ -668,7 +667,7 @@
// UpdateColorBitmapL
// ColorBitmap is redrawn when UI layout or text color (Theme) changes
// -----------------------------------------------------------------------------
-//
+//
void CEasyDialingListBoxData::UpdateColorBitmapL( const TSize& aSize )
{
TRgb color;
@@ -707,7 +706,7 @@
// SetEDLBXControl
//
// -----------------------------------------------------------------------------
-//
+//
void CEasyDialingListBoxData::SetEDLBXControl(CEasyDialingListBox* aControl)
{
iControl = aControl;
@@ -728,7 +727,7 @@
// Calculates the area where contact thumbnail is confined
// -----------------------------------------------------------------------------
//
-TRect ContactImageBoundingBox(const TRect& aItemRect)
+TRect ContactImageBoundingBox( const TRect& aItemRect )
{
TInt leftMargin = aItemRect.Width() * KMarginXPercent / KCent;
TInt topMargin = KMarginYPercent * aItemRect.Height() / KCent;
@@ -746,13 +745,12 @@
// ContactNameBoundingBox
// Calculates the area to which the contact name and possible match highlights
// are confined.
-//
// -----------------------------------------------------------------------------
//
static TRect ContactNameBoundingBox(
const TRect& aItemRect,
const CFont* aContactNameFont,
- TBool aIsCurrentItem,
+ TBool aArrowIconShown,
TBool aIsFavourite,
TBool aThumbnailsShown )
{
@@ -771,9 +769,8 @@
TInt height = KTextBoundingBoxHeightPercent * aContactNameFont->FontMaxHeight() / KCent;
TInt rightMargin = KMarginXPercent * aItemRect.Width() / KCent;
- // Reserve space for communication launcher icon.
- // Communication launcher icon is shown only id item is highlighted.
- if ( aIsCurrentItem )
+ // Reserve space for communication launcher icon if it's shown on this item
+ if ( aArrowIconShown )
{
rightMargin += KArrowIconSizePercent * aItemRect.Height() / KCent;
}
@@ -839,7 +836,7 @@
// Calculates the area to which the action menu icon is drawn.
// -----------------------------------------------------------------------------
//
-TRect ArrowIconBoundingBox(const TRect& aItemRect)
+TRect ArrowIconBoundingBox( const TRect& aItemRect )
{
TInt iconSize = KArrowIconSizePercent * aItemRect.Height() / KCent;
TInt rightMargin = KMarginXPercent * aItemRect.Width() / KCent;
@@ -894,7 +891,7 @@
//
// -----------------------------------------------------------------------------
//
-static TRect MirrorLayoutBoundingBox(const TRect& aSourceRect, TRect& aBoundingBoxRect)
+static TRect MirrorLayoutBoundingBox( const TRect& aSourceRect, TRect& aBoundingBoxRect )
{
return TRect(
aSourceRect.iTl.iX + aSourceRect.iBr.iX - aBoundingBoxRect.iBr.iX,
@@ -914,15 +911,13 @@
// These cases must be handled elsewhere.
// -----------------------------------------------------------------------------
//
-
-_LIT( KThreeDots, "..." );
-
static void ClipTextToWidth(
TDes& aText,
const CFont& aFont,
TInt aMaxWidthInPixels,
TBool& aMatch)
{
+ _LIT( KThreeDots, "..." );
TInt minimumWidth = aFont.TextWidthInPixels( KThreeDots );
// If this is a matching piece of text, also match text marginals need to be counted.
@@ -948,7 +943,6 @@
AknTextUtils::ClipToFit( aText, aFont, aMaxWidthInPixels );
}
-
// -----------------------------------------------------------------------------
// DrawPieceOfText
// Draws a piece of text of contact, either matching or not matching.
@@ -1050,7 +1044,6 @@
return ETrue;
}
-
// -----------------------------------------------------------------------------
// DrawTextWithMatchHighlight
// Draws a string with match highlight. Highlighted and non-highlighted
@@ -1066,7 +1059,7 @@
const TDesC& aText,
const CFont* aFont,
const CEasyDialingListBoxData::TExtendedColors& aColors,
- TBool aHighLight)
+ TBool aHighLight )
{
TInt xOffset = 0;
@@ -1111,9 +1104,10 @@
// Calculates the width of the text and returns it
// -----------------------------------------------------------------------------
//
-static TInt CalculateTextWidth(const TRect& aBoundingBox, const TDesC& aText, const CFont* aFont )
+static TInt CalculateTextWidth( const TRect& aBoundingBox,
+ const TDesC& aText,
+ const CFont* aFont )
{
-
TInt xOffset = 0;
TPtrC textPiece;
TInt textPieceIndex = 0;
@@ -1254,8 +1248,8 @@
// -----------------------------------------------------------------------------
//
static HBufC* ConvertToVisualAndClipLC( const TDesC& aText,
- const CFont& aFont,
- const TRect& aBoundingBox )
+ const CFont& aFont,
+ const TRect& aBoundingBox )
{
HBufC* buf = HBufC::NewLC( aText.Length() + KAknBidiExtraSpacePerLine );
TPtr ptr = buf->Des();
@@ -1320,5 +1314,29 @@
return sepCount;
}
+// -----------------------------------------------------------------------------
+// CreateIconL
+//
+// Create and return a new icon object from given file and with given ID
+// -----------------------------------------------------------------------------
+//
+static CGulIcon* CreateIconL(
+ const TDesC& aFileName,
+ TInt aBitmapId,
+ TInt aMaskId )
+ {
+ CGulIcon* icon = CGulIcon::NewLC();
+
+ CFbsBitmap* bm;
+ CFbsBitmap* mask;
+ AknIconUtils::CreateIconL( bm, mask, aFileName, aBitmapId, aMaskId );
+
+ icon->SetBitmap( bm );
+ icon->SetMask( mask );
+
+ CleanupStack::Pop( icon );
+ return icon;
+ }
+
// End of File.
--- a/phoneuis/easydialing/src/easydialinglistboxitemdrawer.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/easydialing/src/easydialinglistboxitemdrawer.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -115,7 +115,7 @@
iGc->SetPenColor(iTextColor);
iGc->SetBrushColor(iBackColor);
- TPtrC temp=iModel->ItemText(aItemIndex);
+ TPtrC temp = iModel->ItemText(aItemIndex);
SetupGc(aItemIndex);
if ( transApi )
@@ -126,8 +126,8 @@
// TBool removeicon = (!aItemIsSelected && !ItemMarkReverse()) || (aItemIsSelected && ItemMarkReverse());
CEasyDialingListBoxData::TExtendedColors colors;
- colors.iText=iTextColor;
- colors.iBack=iBackColor;
+ colors.iText = iTextColor;
+ colors.iBack = iBackColor;
colors.iHighlightedText = iHighlightedTextColor;
colors.iHighlightedBack = iHighlightedBackColor;
colors.iMatchingText = iMatchingText;
@@ -211,7 +211,7 @@
AknsUtils::GetCachedColor( skin,
iMatchingBack,
KAknsIIDQsnHighlightColors,
- EAknsCIQsnHighlightColorsCG2 );
+ EAknsCIQsnHighlightColorsCG2 );
}
}
@@ -224,7 +224,7 @@
//
void CEasyDialingListBoxItemDrawer::DrawBackgroundAndSeparatorLines( const TRect& aItemTextRect ) const
{
- CCoeControl* control = FormattedCellData()->Control();
+ CCoeControl* control = FormattedCellData()->Control();
MAknListBoxTfxInternal* transApi = CAknListLoader::TfxApiInternal( iGc );
@@ -255,7 +255,7 @@
*Gc(),
aItemTextRect.iTl,
aItemTextRect,
- KAknsDrawParamDefault );
+ KAknsDrawParamDefault );
}
if ( !bgDrawn )
--- a/phoneuis/easydialing/src/easydialingplugin.cpp Wed Mar 31 21:30:06 2010 +0300
+++ b/phoneuis/easydialing/src/easydialingplugin.cpp Wed Apr 14 15:56:42 2010 +0300
@@ -118,7 +118,7 @@
// LOCAL FUNCTION PROTOTYPES
-TInt CompareTPsMatchLocation( const TPsMatchLocation& a1, const TPsMatchLocation& a2);
+TInt CompareTPsMatchLocation( const TPsMatchLocation& a1, const TPsMatchLocation& a2 );
void AppendStringWithMatchDataL(
TDes& aBuffer,
@@ -139,7 +139,7 @@
static TInt Find( const MVPbkContactLink* aLink, const RPointerArray<MVPbkContactLink>& aArray );
template <class T>
-inline void CleanupResetAndDestroyPushL(T& aRef);
+inline void CleanupResetAndDestroyPushL( T& aRef );
@@ -203,7 +203,7 @@
// only found in extension.
// MCCAConnection extension has to be obtained through MCCAParameter extension,
// since MCCAConnection is not designed to be extensible API.
- MCCAParameter* parameter = TCCAFactory::NewParameterL();
+ MCCAParameter* parameter = TCCAFactory::NewParameterL();
TAny* any = parameter->CcaParameterExtension( KMCCAConnectionExtUid );
// Parameter can be deallocated since "any" containing pointer to contact launcher
@@ -233,10 +233,10 @@
SetComponentsToInheritVisibility( ETrue );
}
-// ---------------------------------------------------------
+// -----------------------------------------------------------------------------
// ~CEasyDialingPlugin
// The desctructor
-// ---------------------------------------------------------
+// -----------------------------------------------------------------------------
//
CEasyDialingPlugin::~CEasyDialingPlugin()
{
@@ -322,7 +322,7 @@
iContactListBox->MakeVisible( EFalse );
- SetFocus( EFalse );
+ SetFocus( EFalse );
iContactListBox->ActivateL();
GfxTransEffect::Register( iContactListBox,
@@ -344,8 +344,7 @@
//
void CEasyDialingPlugin::Reset()
{
- // PCS searches completing must be discarded, if the complete
- // after Reset() -call.
+ // PCS searches completing after the Reset() call must be discarded
iDiscardCompletingSearches = ETrue;
iNewSearchNeeded = EFalse;
@@ -604,6 +603,15 @@
iContactListBox->SetMaxRect( rect );
iContactListBox->SetRectToNumberOfItems( iNumberOfNames );
+
+ TInt itemToMakeVisible = iContactListBox->CurrentItemIndex();
+ if ( itemToMakeVisible == KErrNotFound && iNumberOfNames )
+ {
+ // if no current item is set, make sure that the list is then
+ // scrolled to the bottom.
+ itemToMakeVisible = iNumberOfNames - 1;
+ }
+ iContactListBox->ScrollToMakeItemVisible( itemToMakeVisible );
}
@@ -828,7 +836,7 @@
}
// Reset focus unless it is flagged to be remembered.
- if ( ! iRememberFocus )
+ if ( !iRememberFocus )
{
SetFocus( EFalse );
DrawDeferred();
@@ -880,11 +888,11 @@
// in most of the normal cases, and makes the logic simpler.
if ( IsItuTCharacter( iSearchString[i] ) )
{
- item->SetMode( EItut );
+ item->SetMode( EPredictiveItuT );
}
else
{
- item->SetMode( EQwerty );
+ item->SetMode( EPredictiveDefaultKeyboard );
}
iPredictiveSearchQuery->AppendL(*item);
@@ -1148,7 +1156,7 @@
}
// Give up focus, if iRememberFocus flag is not set.
- if ( ! iRememberFocus )
+ if ( !iRememberFocus )
{
SetFocus( EFalse );
DrawDeferred();
@@ -1255,13 +1263,13 @@
HBufC* CEasyDialingPlugin::CreateContactStringLC( CPsClientData* aResult,
CEasyDialingContactDataManager::TNameOrder aNameOrder )
{
- TPtr firstName = aResult->Data( iFirstNamePCSIndex )->Des();
- TPtr lastName = aResult->Data( iLastNamePCSIndex )->Des();
- TPtr companyName( NULL, 0 );
+ TPtrC firstName = *aResult->Data( iFirstNamePCSIndex );
+ TPtrC lastName = *aResult->Data( iLastNamePCSIndex );
+ TPtrC companyName( KNullDesC );
if ( iCompanyNamePCSIndex != KErrNotFound )
{
- companyName.Set( aResult->Data( iCompanyNamePCSIndex )->Des() );
+ companyName.Set( *aResult->Data( iCompanyNamePCSIndex ) );
}
return EasyDialingUtils::CreateContactStringLC( firstName, lastName, companyName, aNameOrder );
}
@@ -1279,7 +1287,7 @@
return;
}
- User::LeaveIfError( iObservers.Append( aObserver ) );
+ iObservers.AppendL( aObserver );
}
@@ -1418,7 +1426,7 @@
{
if ( IsEnabled() )
{
- aMenuPane.SetItemButtonState( EEasyDialingOn, EEikMenuItemSymbolOn );
+ aMenuPane.SetItemButtonState( EEasyDialingOn, EEikMenuItemSymbolOn );
}
else
{
@@ -1749,12 +1757,23 @@
// This ensures smooth and responsive listbox touch handling.
case EEventFlickStarted:
case EEventPanningStarted:
+ case KEasyDialingScrollingStarted:
iContactDataManager->Pause( ETrue );
break;
case EEventFlickStopped:
case EEventPanningStopped:
+ case KEasyDialingScrollingStopped:
iContactDataManager->Pause( EFalse );
+
+ // Touching the listbox always removes the visual focus from any list item.
+ // Move the focus away from the listbox after panning has ended to
+ // align our internal state with the visual lack of focus.
+ if ( IsFocused() )
+ {
+ SetFocus( EFalse );
+ DrawDeferred();
+ }
break;
// We are not interested about the other listbox events.
@@ -1788,7 +1807,7 @@
if ( iContactLauncherActive )
{
// Set the flag to make a search when communication launcher exits.
- iNewSearchNeeded = ETrue;
+ iNewSearchNeeded = ETrue;
}
else
{
@@ -1869,11 +1888,7 @@
//
TInt CompareTPsMatchLocation( const TPsMatchLocation& a1, const TPsMatchLocation& a2)
{
- if ( a1.index == a2.index )
- {
- return 0;
- }
- return ( a1.index > a2.index ) ? 1 : -1;
+ return a1.index - a2.index;
}
@@ -1907,7 +1922,7 @@
TInt numberOfIndices = matchIndices.Count();
TInt textOffset = 0;
- for (TInt i = 0; i < numberOfIndices ; i++ )
+ for ( TInt i = 0; i < numberOfIndices ; i++ )
{
TInt matchingPartStart = matchIndices[i].index;
TInt matchingPartLength = matchIndices[i].length;
@@ -1924,10 +1939,10 @@
TPtrC matchingPart = aText.Mid( matchingPartStart, matchingPartLength );
aBuffer.Append( matchingPart );
-
+
// Append matching separator charactes.
aBuffer.Append( KHighlightSeparatorChar );
-
+
textOffset = matchingPartStart + matchingPartLength;
}