Revision: 201013 RCL_3
authorDremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
Wed, 14 Apr 2010 16:32:24 +0300
branchRCL_3
changeset 8 ba42c4bd84dd
parent 7 a19c8664496d
child 9 71e7b994dff4
Revision: 201013 Kit: 201015
cbs/CbsServer/ServerSrc/CCbsSatRefresh.cpp
cellular/SSSettings/src/CSSSettingsRefreshHandler.cpp
networkhandling/networkhandlingengine/NetworkHandlingGsmSrc/CNWNetworkViagRefresh.cpp
phoneclientserver/phoneclient/Inc/SharedClientServer/PhCltClientServer.h
phonesrv_plat/call_information_api/tsrc/run_auto_tests.bat
phonesrv_plat/sat_client_api/group/bld.inf
phonesrv_plat/sat_client_api/tsrc/group/satclientapitest.mmp
phonesrv_plat/sat_client_api/tsrc/inc/satclientapitest.h
phonesrv_plat/sat_client_api/tsrc/src/satclientapitest.cpp
phonesrv_plat/sat_configuration_api/group/bld.inf
phonesrv_plat/sat_refresh_api/group/bld.inf
phonesrv_plat/sat_refresh_api/inc/RSatRefresh.h
phonesrv_plat/sat_refresh_api/tsrc/group/satrefreshapitest.mmp
phonesrv_plat/sat_refresh_api/tsrc/inc/satrefreshapitest.h
phonesrv_plat/sat_refresh_api/tsrc/inc/satrefreshobserver.h
phonesrv_plat/voice_mailbox_number_api/inc/vmnumber.h
satengine/SatServer/Commands/OpenChannelCmd/src/COpenChannelHandler.cpp
satengine/SatServer/Engine/inc/CSatApnHandler.h
satengine/SatServer/Engine/src/CSatApnHandler.cpp
satengine/SatServer/Engine/src/CSatCommandContainer.cpp
satengine/SatServer/Engine/src/CSatSUiSubSession.cpp
satengine/SatServer/SatClient/src/CSatAllowRefreshMonitor.cpp
satengine/SatServer/SatClient/src/CSatRefreshMonitor.cpp
satengine/SatServer/SatClient/src/RSatRefresh.cpp
satengine/SatServer/SatClient/src/RSatSession.cpp
satengine/SatServer/SatClient/src/rsatservice.cpp
satengine/SatServer/SatInternalClient/src/RSatUiSession.cpp
satengine/SatServer/SystemState/src/CSatSystemState.cpp
satengine/SatServer/inc/MSatApnHandler.h
satui/satapp/SATUIInc/CSatUiActionPerformer.h
satui/satapp/SATUISrc/CSatUiViewAppUi.cpp
--- a/cbs/CbsServer/ServerSrc/CCbsSatRefresh.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/cbs/CbsServer/ServerSrc/CCbsSatRefresh.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -21,8 +21,8 @@
 // INCLUDE FILES
 #include "CCbsSatRefresh.h"
 #include "CCbsServer.h"
-#include <RSatRefresh.h>
-#include <RSatSession.h>
+#include <rsatrefresh.h>
+#include <rsatsession.h>
 
 #include "CbsLogger.h"
 
--- a/cellular/SSSettings/src/CSSSettingsRefreshHandler.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/cellular/SSSettings/src/CSSSettingsRefreshHandler.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -231,6 +231,17 @@
         iRSSSettings.HandleRefresh();
         }
 
+    TBool cspEfFound =  
+        aFiles.Locate( KCsp1Ef ) != KErrNotFound || 
+        aFiles.Locate( KCsp2Ef ) != KErrNotFound; 
+
+    // KCspEf is no longer provided by SAT but GS and PS seem to depend on it, 
+    // handled here for now. 
+    TBool fileFound =  
+        aFiles.Locate( iNotifyInfo->iObservedFile ) != KErrNotFound || 
+        cspEfFound && iNotifyInfo->iObservedFile == KCspEf; 
+
+
     // By default refresh is allowed.
     TBool allow(ETrue);
 
@@ -240,96 +251,46 @@
         // Handle only if observer wants to listen this event.
         if ( iNotifyInfo->iObservedRefreshType & aType )
             {
-            TInt changedFiles(0);     
-            // Only change notification will contain file list.
-            if ( aType == EFileChangeNotification )
-                {              
-                if ( aFiles.Locate( KCspEf ) != KErrNotFound )
-                    {
-                    changedFiles += KCspEf;
-                    }
-                // Check if the changed files is what is wanted to be listened.
-                changedFiles = changedFiles & iNotifyInfo->iObservedFile;
-                }
-
-            // For change notification the filelist must contain files, for
-            // other refresh types it is empty.
-            if ( ( aType != EFileChangeNotification ) ||
-                 ( ( aType == EFileChangeNotification ) && 
-                   changedFiles ) )
+            if ( aType != EFileChangeNotification || fileFound )
                 {
                 if ( aFunctionality == ESSSettingsRefresh )
                     {
                     // Inform the observer about the refresh event.
                     iNotifyInfo->iObserver->Refresh(
-                        aType,
-                        ( TSatElementaryFiles ) changedFiles  );
-                        
-                    if ( aFiles.Locate( KCsp1Ef ) != KErrNotFound )
-	                    {
-	                    iRSatRefresh->RefreshEFRead( ETrue );
-	                    }
-	                else if( aFiles.Locate( KCsp2Ef ) != KErrNotFound )
-	                	{
-	                	iRSatRefresh->RefreshEFRead( ETrue );
-	                	}
-	                else
-	                	{
-	                	iRSatRefresh->RefreshEFRead( EFalse );
-	                	}
+                        aType, iNotifyInfo->iObservedFile );
+                    iRSatRefresh->RefreshEFRead( cspEfFound );
                     }
                 else // ESSSettingsAllowRefresh
                     {
                     // Inform the observer about the coming refresh event.
                     allow = iNotifyInfo->iObserver->AllowRefresh(
-                        aType,
-                        ( TSatElementaryFiles ) changedFiles );
+                        aType, iNotifyInfo->iObservedFile );
                     }
                 }
             
             // If there is no client listening changed files SSSettings has to
             // check if some CSP file is into the list and send right response
             // since itself reads CSP files.    
-            if ( !changedFiles )
+            if ( !fileFound )
             	{
-            	if ( aFiles.Locate( KCsp1Ef ) != KErrNotFound )
-                    {
-                    iRSatRefresh->RefreshEFRead( EFalse );
-                    }
-                else if( aFiles.Locate( KCsp2Ef ) != KErrNotFound )
-                	{
-                	iRSatRefresh->RefreshEFRead( EFalse );
-                	}
-                else
-                	{
-                	iRSatRefresh->RefreshEFRead( ETrue );
-                	}
-            	}
-            __SSSLOGSTRING1("[SSS]    DoHandleRefresh: changedFiles: %d", changedFiles);
+                iRSatRefresh->RefreshEFRead( !cspEfFound );
+                }
             }
         else
             {
-            iRSatRefresh->RefreshEFRead( EFalse );    
+            iRSatRefresh->RefreshEFRead( EFalse );
             }
         }
-
-    if ( !iNotifyInfo->iObserver && ( aType == EFileChangeNotification 
-    	|| aType == ESimInitFileChangeNotification 
-    	|| aType == ESimInit ) )
-    	{
-        if ( aFiles.Locate( KCsp1Ef ) != KErrNotFound )
-        	{
-            iRSatRefresh->RefreshEFRead( EFalse );
-            }
-        else if( aFiles.Locate( KCsp2Ef ) != KErrNotFound )
-          	{
-           	iRSatRefresh->RefreshEFRead( EFalse );
-          	}           
-        else 
-            {
-            iRSatRefresh->RefreshEFRead( ETrue );
-            }
-    	}	
+    else if ( aType == EFileChangeNotification 
+        || aType == ESimInitFileChangeNotification 
+        || aType == ESimInit )
+        {
+        iRSatRefresh->RefreshEFRead( !cspEfFound );
+        }
+    else 
+        {
+        // Do nothing
+        }
     	    	
     __SSSLOGSTRING("[SSS] <--CSSSettingsRefreshHandler::DoHandleRefresh");
     return allow;
--- a/networkhandling/networkhandlingengine/NetworkHandlingGsmSrc/CNWNetworkViagRefresh.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/networkhandling/networkhandlingengine/NetworkHandlingGsmSrc/CNWNetworkViagRefresh.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -22,8 +22,8 @@
 #include    "CNWNetworkViagRefresh.h"
 #include    "CNWNetworkViagBaseEngine.h"
 #include    "NWLogger.h"
-#include    <RSatRefresh.h>
-#include    <RSatSession.h>
+#include    <rsatrefresh.h>
+#include    <rsatsession.h>
 #include    "CNWNetworkViagSimReader.h"
 
 
--- a/phoneclientserver/phoneclient/Inc/SharedClientServer/PhCltClientServer.h	Wed Mar 31 22:34:38 2010 +0300
+++ b/phoneclientserver/phoneclient/Inc/SharedClientServer/PhCltClientServer.h	Wed Apr 14 16:32:24 2010 +0300
@@ -58,7 +58,7 @@
 _LIT( KPhClientAndServerResourceFileName, "PhoneServer" );
 _LIT( KPhCltServerZDrive, "z:" );
 
-_LIT( KPhClientAndServerResourceFileExtensionWild, ".R??" );
+_LIT( KPhClientAndServerResourceFileExtensionWild, ".R*" );
 _LIT( KPhClientAndServerResourceFileExtensionNoWild, ".RSC" );
 const TInt KPhSrvMagicResourceFileSignature = 0;
 
--- a/phonesrv_plat/call_information_api/tsrc/run_auto_tests.bat	Wed Mar 31 22:34:38 2010 +0300
+++ b/phonesrv_plat/call_information_api/tsrc/run_auto_tests.bat	Wed Apr 14 16:32:24 2010 +0300
@@ -54,7 +54,7 @@
 set INSTRUMENT=TRUE
 set REMOVEINSTRUMENT=TRUE
 set DOMODULESTESTS=TRUE
-set ABLD_CALL=abld test build winscw udeb -keepgoing
+set SBS_CALL=sbs --config winscw_udeb.test --keepgoing build
 set PATH_TO_DLL=\epoc32\release\winscw\udeb
 set PATH_TO_MOVE_DLL=\epoc32\release\winscw\udeb\z\sys\bin
 set PATH_TO_COVERAGE_DATA=\coverage_data
@@ -145,13 +145,12 @@
 
 pushd .
 call cd %1\group
-call bldmake bldfiles
-call abld -k test clean winscw udeb
-call abld -k test reallyclean winscw udeb
+call sbs --config winscw_udeb.test --keepgoing clean
+call sbs --config winscw_udeb.test --keepgoing reallyclean
 if [%INSTRUMENT%] EQU [TRUE] (
-call ctcwrap -n %PATH_TO_COVERAGE_DATA%\%1 -i d -C "EXCLUDE=*" -C "NO_EXCLUDE=%TESTED_SRC%" %ABLD_CALL%
+call ctcwrap -2comp -n %PATH_TO_COVERAGE_DATA%\%1 -i d -C "EXCLUDE=*" -C "NO_EXCLUDE=%TESTED_SRC%" "%SBS_CALL%"
 ) else (
-call %ABLD_CALL%
+call %SBS_CALL%
 )
 
 popd
--- a/phonesrv_plat/sat_client_api/group/bld.inf	Wed Mar 31 22:34:38 2010 +0300
+++ b/phonesrv_plat/sat_client_api/group/bld.inf	Wed Apr 14 16:32:24 2010 +0300
@@ -12,7 +12,7 @@
 * Contributors:
 *
 * Description:  File that exports the files belonging to 
-:                SAT Client API
+*               SAT Client API
 *
 */
 
@@ -24,4 +24,4 @@
 
 PRJ_EXPORTS
 
-../inc/RSatSession.h     MW_LAYER_PLATFORM_EXPORT_PATH( RSatSession.h )
+../inc/RSatSession.h     MW_LAYER_PLATFORM_EXPORT_PATH( rsatsession.h )
--- a/phonesrv_plat/sat_client_api/tsrc/group/satclientapitest.mmp	Wed Mar 31 22:34:38 2010 +0300
+++ b/phonesrv_plat/sat_client_api/tsrc/group/satclientapitest.mmp	Wed Apr 14 16:32:24 2010 +0300
@@ -11,7 +11,7 @@
 *
 * Contributors:
 *
-* Description:  Test class for SAT Client API / RSatSession.h
+* Description:  Test class for SAT Client API / rsatsession.h
 *
 */
 
--- a/phonesrv_plat/sat_client_api/tsrc/inc/satclientapitest.h	Wed Mar 31 22:34:38 2010 +0300
+++ b/phonesrv_plat/sat_client_api/tsrc/inc/satclientapitest.h	Wed Apr 14 16:32:24 2010 +0300
@@ -11,7 +11,7 @@
 *
 * Contributors:
 *
-* Description:  Test class for SAT Client API / RSatSession.h
+* Description:  Test class for SAT Client API / rsatsession.h
 *
 */
 
@@ -22,7 +22,7 @@
 #include <testscripterinternal.h>
 #include <stiftestmodule.h>
 // API under testing:
-#include <RSatSession.h>
+#include <rsatsession.h>
 
 // Logging path
 _LIT( KSatClientAPILogPath, "\\logs\\testframework\\SATClientAPITest\\" ); 
@@ -31,7 +31,7 @@
 
 
 /**
-*  Test class for SAT Client API / RSatSession.h
+*  Test class for SAT Client API / rsatsession.h
 *
 *  @lib satclientapitest.dll
 *  @since S60 5.0
--- a/phonesrv_plat/sat_client_api/tsrc/src/satclientapitest.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/phonesrv_plat/sat_client_api/tsrc/src/satclientapitest.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -11,7 +11,7 @@
 *
 * Contributors:
 *
-* Description:  Test class for SAT Client API / RSatSession.h
+* Description:  Test class for SAT Client API / rsatsession.h
 *
 */
 
--- a/phonesrv_plat/sat_configuration_api/group/bld.inf	Wed Mar 31 22:34:38 2010 +0300
+++ b/phonesrv_plat/sat_configuration_api/group/bld.inf	Wed Apr 14 16:32:24 2010 +0300
@@ -12,7 +12,7 @@
 * Contributors:
 *
 * Description:  File that exports the files belonging to 
-:                SAT Configuration API
+*               SAT Configuration API
 *
 */
 
@@ -24,4 +24,4 @@
 
 PRJ_EXPORTS
 
-../inc/SATDomainPSKeys.h     MW_LAYER_PLATFORM_EXPORT_PATH(SATDomainPSKeys.h)
+../inc/SATDomainPSKeys.h     MW_LAYER_PLATFORM_EXPORT_PATH(satdomainpskeys.h)
--- a/phonesrv_plat/sat_refresh_api/group/bld.inf	Wed Mar 31 22:34:38 2010 +0300
+++ b/phonesrv_plat/sat_refresh_api/group/bld.inf	Wed Apr 14 16:32:24 2010 +0300
@@ -12,7 +12,7 @@
 * Contributors:
 *
 * Description:  File that exports the files belonging to 
-:                SAT Refresh API
+*               SAT Refresh API
 *
 */
 
@@ -24,5 +24,5 @@
 
 PRJ_EXPORTS
 
-../inc/RSatRefresh.h     MW_LAYER_PLATFORM_EXPORT_PATH(RSatRefresh.h)
+../inc/RSatRefresh.h     MW_LAYER_PLATFORM_EXPORT_PATH(rsatrefresh.h)
 ../inc/MSatRefreshObserver.h     MW_LAYER_PLATFORM_EXPORT_PATH(msatrefreshobserver.h)
--- a/phonesrv_plat/sat_refresh_api/inc/RSatRefresh.h	Wed Mar 31 22:34:38 2010 +0300
+++ b/phonesrv_plat/sat_refresh_api/inc/RSatRefresh.h	Wed Apr 14 16:32:24 2010 +0300
@@ -23,7 +23,7 @@
 //  INCLUDES
 #include <e32std.h>
 #include <Etelsat.h>
-#include <MSatRefreshObserver.h>
+#include <msatrefreshobserver.h>
 
 // FORWARD DECLARATIONS
 class RSatSession;
--- a/phonesrv_plat/sat_refresh_api/tsrc/group/satrefreshapitest.mmp	Wed Mar 31 22:34:38 2010 +0300
+++ b/phonesrv_plat/sat_refresh_api/tsrc/group/satrefreshapitest.mmp	Wed Apr 14 16:32:24 2010 +0300
@@ -12,7 +12,7 @@
 * Contributors:
 *
 * Description:  Test class for SAT Refresh API / 
-*                RSatRefresh.h, MSatRefreshObserver.h
+*                rsatrefresh.h, msatrefreshobserver.h
 *
 */
 
--- a/phonesrv_plat/sat_refresh_api/tsrc/inc/satrefreshapitest.h	Wed Mar 31 22:34:38 2010 +0300
+++ b/phonesrv_plat/sat_refresh_api/tsrc/inc/satrefreshapitest.h	Wed Apr 14 16:32:24 2010 +0300
@@ -24,10 +24,10 @@
 #include <stiftestmodule.h>
 #include "satrefreshobserver.h"
 // API under testing:
-#include <RSatRefresh.h>
-#include <MSatRefreshObserver.h>
+#include <rsatrefresh.h>
+#include <msatrefreshobserver.h>
 // This is needed for Refresh API
-#include <RSatSession.h>
+#include <rsatsession.h>
 
 // Logging path
 _LIT( KSatRefreshAPILogPath, "\\logs\\testframework\\SATRefreshAPITest\\" ); 
--- a/phonesrv_plat/sat_refresh_api/tsrc/inc/satrefreshobserver.h	Wed Mar 31 22:34:38 2010 +0300
+++ b/phonesrv_plat/sat_refresh_api/tsrc/inc/satrefreshobserver.h	Wed Apr 14 16:32:24 2010 +0300
@@ -23,10 +23,10 @@
 #include <testscripterinternal.h>
 #include <stiftestmodule.h>
 // API under testing:
-#include <RSatRefresh.h>
-#include <MSatRefreshObserver.h>
+#include <rsatrefresh.h>
+#include <msatrefreshobserver.h>
 // This is needed for Refresh API
-#include <RSatSession.h>
+#include <rsatsession.h>
 
 /**
 *  Refresh event observer
--- a/phonesrv_plat/voice_mailbox_number_api/inc/vmnumber.h	Wed Mar 31 22:34:38 2010 +0300
+++ b/phonesrv_plat/voice_mailbox_number_api/inc/vmnumber.h	Wed Apr 14 16:32:24 2010 +0300
@@ -33,9 +33,9 @@
 #include <PhCltTypes.h>         // from PhoneClient
 
 #include <MSSSettingsObserver.h>
-#include <MSatRefreshObserver.h>
-#include <RSatSession.h>
-#include <RSatRefresh.h>
+#include <msatrefreshobserver.h>
+#include <rsatsession.h>
+#include <rsatrefresh.h>
 #include <centralrepository.h>
 #include <CenRepNotifyHandler.h>
 #include <aknappui.h>
--- a/satengine/SatServer/Commands/OpenChannelCmd/src/COpenChannelHandler.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/satengine/SatServer/Commands/OpenChannelCmd/src/COpenChannelHandler.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies). 
+* Copyright (c) 2002-2010 Nokia Corporation and/or its subsidiary(-ies). 
 * All rights reserved.
 * This component and the accompanying materials are made available
 * under the terms of "Eclipse Public License v1.0"
@@ -633,6 +633,8 @@
         "OPENCHANNEL: COpenChannelHandler::SetConnectionSettingsL calling,\
         aBearerType: %d", aBearerType )
 
+    RPacketContext::TProtocolType pdpType = RPacketContext::EPdpTypeIPv4;
+    TUint32 defaultId( 0 );
     switch ( aBearerType )
         {
         case MSatBIPUtils::ESatGPRS:
@@ -648,9 +650,8 @@
                 TUint32 nwId( 0 );
                 TBool apnCreated( EFalse );
 
-                RPacketContext::TProtocolType pdpType = 
-                           RPacketContext::EPdpTypeIPv6;
-                
+                pdpType = RPacketContext::EPdpTypeIPv6;
+
                 if ( RSat::EIPv4Address ==
                     iOpenChannelData.iDestinationAddress.iType )
                     {
@@ -684,10 +685,14 @@
                 }
             else
                 {
-                LOG( NORMAL, "OPENCHANNEL: COpenChannelHandler::SetConnectionSettingsL \
+                LOG( NORMAL, "OPENCHANNEL: SetConnectionSettingsL \
                 No APN, using defaults" )
                 // No APN, use default settings
-                SetOverrideSettingsL( 0 );
+                TRAPD( err, defaultId = 
+                iUtils->BipUtils().ApnHandler().FindDefaultApL( pdpType ) );
+                LOG2( NORMAL, "OPENCHANNEL: SetConnectionSettingsL \
+                    No APN, using defaults err = %i", err )
+                SetOverrideSettingsL( defaultId );
                 }
             break;
             }
@@ -703,7 +708,11 @@
 
 #ifdef SAT_USE_DUMMY_TSY
     // No APN, use default settings
-    SetOverrideSettingsL( 0 );
+    TRAPD( err, 
+    defaultId = iUtils->BipUtils().ApnHandler().FindDefaultApL( pdpType ) );
+    LOG2( NORMAL, "OPENCHANNEL: COpenChannelHandler::SetConnectionSettingsL \
+        No APN, using defaults err = %i", err )
+    SetOverrideSettingsL( defaultId );
 #endif // SAT_USE_DUMMY_TSY
 
     LOG( SIMPLE,
--- a/satengine/SatServer/Engine/inc/CSatApnHandler.h	Wed Mar 31 22:34:38 2010 +0300
+++ b/satengine/SatServer/Engine/inc/CSatApnHandler.h	Wed Apr 14 16:32:24 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2002-2008 Nokia Corporation and/or its subsidiary(-ies). 
+* Copyright (c) 2002-2010 Nokia Corporation and/or its subsidiary(-ies). 
 * All rights reserved.
 * This component and the accompanying materials are made available
 * under the terms of "Eclipse Public License v1.0"
@@ -80,6 +80,13 @@
         */
         void DeleteApnL( TUint32 aApnId );
 
+        /**
+         * Find the default APN Id
+         * @param aPdpType, indicates the address type is IPv4  or IPv6
+         * @return a default iap id
+         */
+        TUint32 FindDefaultApL(
+                const RPacketContext::TProtocolType& aPdpType );
     private:
 
         /**
--- a/satengine/SatServer/Engine/src/CSatApnHandler.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/satengine/SatServer/Engine/src/CSatApnHandler.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -22,6 +22,8 @@
 #include <cmconnectionmethodext.h>
 #include <cmconnectionmethoddef.h>
 #include <cmpluginpacketdatadef.h>
+#include <cmdestination.h>
+#include <cmmanagerdef.h>
 
 #include    "MSatUtils.h"
 #include    "CSatApnHandler.h"
@@ -386,4 +388,74 @@
     return formatApnName;
     }
 
+// -----------------------------------------------------------------------------
+// CSatApnHandler::FindDefaultApL
+// -----------------------------------------------------------------------------
+//
+TUint32 CSatApnHandler::FindDefaultApL(
+        const RPacketContext::TProtocolType& aPdpType )
+    {
+    LOG( SIMPLE, "SATENGINE: CSatApnHandler::FindDefaultApL calling" );
+    TUint32 defaultIap( 0 );
+    TInt pdpType;
+    TBool isFound( EFalse );
+
+    // create a network destination
+    RCmDestination des;
+    RCmConnectionMethod cm;
+
+    // Create CMManager Session
+    RCmManager cmManager;
+    cmManager.OpenL();
+    CleanupClosePushL( cmManager );
+
+    // Get the Connection Method list from the open CMManager session
+    RArray<TUint32> array = RArray<TUint32>( KSatCMGranularity );
+    CleanupClosePushL( array );
+
+    // list all available destinations' id
+    cmManager.AllDestinationsL( array );
+    for( TInt i = 0; ( i < array.Count() ) && !isFound; ++i )
+        {
+        des = cmManager.DestinationL( array[i] );
+        CleanupClosePushL( des );
+
+        if ( CMManager::ESnapPurposeInternet ==
+        des.MetadataL( CMManager::ESnapMetadataPurpose ) )
+            {
+            LOG( SIMPLE, "SATENGINE: CSatApnHandler::FindDefaultApL \
+            the fixed destination is identified as 'Internet'" );
+            for( TInt j = 0; ( j < des.ConnectionMethodCount() ) &&
+            !isFound; ++j )
+                {
+                cm = des.ConnectionMethodL( j );
+                CleanupClosePushL( cm );
+                pdpType = cm.GetIntAttributeL(
+                        CMManager::EPacketDataPDPType );
+                LOG2( SIMPLE, "SATENGINE: CSatApnHandler::FindDefaultApL \
+                        current protocol type is %d", pdpType )
+                if ( pdpType == aPdpType )
+                    {
+                    defaultIap = cm.GetIntAttributeL( CMManager::ECmIapId );
+                    isFound  = ETrue;
+                    LOG2( SIMPLE, "SATENGINE: CSatApnHandler::FindDefaultApL \
+                            default iap had been found %d", defaultIap )
+                    }
+                CleanupStack::PopAndDestroy( &cm );
+                }
+            }
+        CleanupStack::PopAndDestroy( &des );
+        }
+    CleanupStack::PopAndDestroy( &array );
+    CleanupStack::PopAndDestroy( &cmManager );
+
+    if ( !isFound )
+        {
+        LOG( SIMPLE, "SATENGINE: CSatApnHandler: default AP not found" );
+        User::Leave( KErrNotFound );
+        }
+
+    LOG( SIMPLE, "SATENGINE: CSatApnHandler::FindDefaultApL exit" )
+    return defaultIap;
+    }
 //  End of File
--- a/satengine/SatServer/Engine/src/CSatCommandContainer.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/satengine/SatServer/Engine/src/CSatCommandContainer.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -25,7 +25,7 @@
 #include    <e32property.h>
 #include    <data_caging_path_literals.hrh>
 #include    <startupdomainpskeys.h>
-#include    <SATDomainPSKeys.h>
+#include    <satdomainpskeys.h>
 
 #include    "MSatSystemState.h"
 #include    "TSatSystemStateFactory.h"
--- a/satengine/SatServer/Engine/src/CSatSUiSubSession.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/satengine/SatServer/Engine/src/CSatSUiSubSession.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -19,7 +19,7 @@
 
 // INCLUDE FILES
 #include    <e32property.h>
-#include    <SATDomainPSKeys.h>
+#include    <satdomainpskeys.h>
 
 #include    "CSatSUiSubSession.h"
 #include    "CSatSSession.h"
--- a/satengine/SatServer/SatClient/src/CSatAllowRefreshMonitor.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/satengine/SatServer/SatClient/src/CSatAllowRefreshMonitor.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -20,7 +20,7 @@
 // INCLUDE FILES
 #include    "CSatAllowRefreshMonitor.h"
 #include    "msatrefreshobserver.h"
-#include    "RSatRefresh.h"
+#include    "rsatrefresh.h"
 #include    "SatLog.h"
 
 // ============================ MEMBER FUNCTIONS ===============================
--- a/satengine/SatServer/SatClient/src/CSatRefreshMonitor.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/satengine/SatServer/SatClient/src/CSatRefreshMonitor.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -18,8 +18,8 @@
 
 
 // INCLUDE FILES
-#include    <RSatSession.h>
-#include    <RSatRefresh.h>
+#include    <rsatsession.h>
+#include    <rsatrefresh.h>
 
 #include    "CSatRefreshMonitor.h"
 #include    "SatLog.h"
--- a/satengine/SatServer/SatClient/src/RSatRefresh.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/satengine/SatServer/SatClient/src/RSatRefresh.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -18,8 +18,8 @@
 
 
 // INCLUDE FILES
-#include    <RSatRefresh.h>
-#include    <RSatSession.h>
+#include    <rsatrefresh.h>
+#include    <rsatsession.h>
 #include    "SatSOpcodes.h"
 #include    "CSatAllowRefreshMonitor.h"
 #include    "CSatRefreshMonitor.h"
--- a/satengine/SatServer/SatClient/src/RSatSession.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/satengine/SatServer/SatClient/src/RSatSession.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -16,7 +16,7 @@
 */
 
 
-#include    <RSatSession.h>
+#include    <rsatsession.h>
 #include    "SatSOpcodes.h"
 #include    "SatServerFactory.h"
 #include    "SatLog.h"
--- a/satengine/SatServer/SatClient/src/rsatservice.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/satengine/SatServer/SatClient/src/rsatservice.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -22,7 +22,7 @@
 #include    <centralrepository.h>
 #include    <etelsat.h>
 #include    <rsatservice.h>
-#include    <RSatSession.h>
+#include    <rsatsession.h>
 #include    <tsaticoninfo.h>
 
 #include    "tsatinternaliconinfo.h"
--- a/satengine/SatServer/SatInternalClient/src/RSatUiSession.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/satengine/SatServer/SatInternalClient/src/RSatUiSession.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -19,7 +19,7 @@
 
 //  INCLUDE FILES
 #include <e32def.h>
-#include <RSatSession.h>
+#include <rsatsession.h>
 #include <data_caging_path_literals.hrh>
 
 #include "RSatUiSession.h"
--- a/satengine/SatServer/SystemState/src/CSatSystemState.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/satengine/SatServer/SystemState/src/CSatSystemState.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -24,13 +24,12 @@
 #include    <CommonEngineDomainCRKeys.h>
 #include    <ProfileEngineSDKCRKeys.h>
 #include    <settingsinternalcrkeys.h>
-#include    <SATDomainPSKeys.h>
+#include    <satdomainpskeys.h>
 #include    <activeidle2domainpskeys.h>
 #include    <ScreensaverInternalPSKeys.h>
 #include    <ctsydomainpskeys.h>
 #include    <sbdefs.h>
 #include    <BTSapDomainPSKeys.h>
-#include    <SATDomainPSKeys.h>
 
 #include    "SATInternalPSKeys.h"
 #include    "CSatSystemState.h"
--- a/satengine/SatServer/inc/MSatApnHandler.h	Wed Mar 31 22:34:38 2010 +0300
+++ b/satengine/SatServer/inc/MSatApnHandler.h	Wed Apr 14 16:32:24 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2002-2008 Nokia Corporation and/or its subsidiary(-ies). 
+* Copyright (c) 2002-2010 Nokia Corporation and/or its subsidiary(-ies). 
 * All rights reserved.
 * This component and the accompanying materials are made available
 * under the terms of "Eclipse Public License v1.0"
@@ -76,6 +76,13 @@
         */
         virtual void DeleteApnL( TUint32 aApnId ) = 0;
 
+        /**
+         * Find the default APN Id
+         * @param aPdpType, indicates the address type is IPv4  or IPv6
+         * @return a default iap id
+         */
+        virtual TUint32 FindDefaultApL(
+                const RPacketContext::TProtocolType& aPdpType ) = 0;
     private:
 
         // Prohibit copy constructor if not deriving from CBase.
--- a/satui/satapp/SATUIInc/CSatUiActionPerformer.h	Wed Mar 31 22:34:38 2010 +0300
+++ b/satui/satapp/SATUIInc/CSatUiActionPerformer.h	Wed Apr 14 16:32:24 2010 +0300
@@ -23,7 +23,7 @@
 //  INCLUDES
 #include <msatuiobserver.h>
 #include <rsatuisession.h>
-#include <RSatSession.h>
+#include <rsatsession.h>
 
 #include <cenrepnotifyhandler.h>
 
--- a/satui/satapp/SATUISrc/CSatUiViewAppUi.cpp	Wed Mar 31 22:34:38 2010 +0300
+++ b/satui/satapp/SATUISrc/CSatUiViewAppUi.cpp	Wed Apr 14 16:32:24 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies). 
+* Copyright (c) 2002-2010 Nokia Corporation and/or its subsidiary(-ies). 
 * All rights reserved.
 * This component and the accompanying materials are made available
 * under the terms of "Eclipse Public License v1.0"
@@ -110,6 +110,10 @@
 const TUint8 KKeyNine = 0x39;
 const TUint8 KHwAsterisk = 0x2a;    // In hw scan code value for asterisk
 
+// The max volume value from settings.
+// From TProfileToneSettings.h
+const TInt KMaxVolumeFromProfile( 10 );
+
 // ================= MEMBER FUNCTIONS =======================
 
 // C++ default constructor can NOT contain any code, that
@@ -1559,6 +1563,8 @@
 
     TInt volume( iPlayer->MaxVolume() );
     iPlayer->SetVolume( volume );
+    TFLOGSTRING2( "CSatUiViewAppUi::PlayStandardToneL SetVolume %d",
+        volume )    
 
     iPlayer->PrepareToPlayDesSequence( aSequence );
 
@@ -3221,6 +3227,22 @@
     const TProfileToneSettings& ts = tones.ToneSettings();
     iWarningAndPlayTones = ts.iWarningAndGameTones;
     iVolume = ts.iRingingVolume;
+    TFLOGSTRING2( "CSatUiViewAppUi::GetProfileParamsL \
+        iVolume before mapping %d", iVolume )
+    
+    // Max volume from profile is KMaxVolumeFromProfile, Max volume from 
+    // CMdaAudioToneUtility is different, maybe 10,000. So, 
+    // rate = maxVolumeFromPlayer / KMaxVolumeFromProfile
+    // User may never hear the TONE, because volume is too small.
+    // iVolume times the rate make it can be heard.
+    
+    CMdaAudioToneUtility* toneUtl = CMdaAudioToneUtility::NewL( *this );
+    TInt maxVolumeFromPlayer( toneUtl->MaxVolume() );
+    iVolume *= maxVolumeFromPlayer / KMaxVolumeFromProfile;
+    delete toneUtl;
+    toneUtl = NULL;
+    TFLOGSTRING2( "CSatUiViewAppUi::GetProfileParamsL \
+        iVolume after mapping %d", iVolume )
     
     if ( ( ESatUserSelectedToneIncomingSms == aTone ) && ( aToneName ) )
         {