--- a/applicationmanagement/server/inc/AMDownload.h Thu Jan 07 12:39:15 2010 +0200
+++ b/applicationmanagement/server/inc/AMDownload.h Mon Jan 18 20:09:30 2010 +0200
@@ -19,7 +19,7 @@
#define __CAMDOWNLOAD_H__
#include <e32base.h>
-#include <DownloadMgrClient.h>
+#include <downloadmgrclient.h>
// FORWARD DECLARATIONS
--- a/applicationmanagement/server/inc/AMDownloadManager.h Thu Jan 07 12:39:15 2010 +0200
+++ b/applicationmanagement/server/inc/AMDownloadManager.h Mon Jan 18 20:09:30 2010 +0200
@@ -19,7 +19,7 @@
#define __CAMDOWNLOADMANAGER_H__
#include <e32base.h>
-#include <DownloadMgrClient.h>
+#include <downloadmgrclient.h>
#include "AMDeploymentComponent.h"
#include "aminstalloptions.h"
--- a/applicationmanagement/server/src/ApplicationManagementServer.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/applicationmanagement/server/src/ApplicationManagementServer.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -2487,10 +2487,39 @@
add = sisEntry.IsPresentL();
- if(add)
- RDEBUG( "CApplicationManagementSession::ActiveComponentsL ETrue" );
- else
- RDEBUG( "CApplicationManagementSession::ActiveComponentsL EFalse" );
+ if(add)
+ {
+
+ // If Present update the Version, name and other info to that deployement component. Since application would have got an update
+ // by some other means
+
+ TVersion version = sisEntry.VersionL();
+ TBuf8<KVersionLength> pkgDes;
+ pkgDes.AppendNum(version.iMajor);
+ pkgDes.Append(KLiteralPeriod);
+ pkgDes.AppendNum(version.iMinor);
+
+
+ HBufC *packagename = sisEntry.PackageNameL();
+ TBuf8<512> packagename8;
+ packagename8.Copy(*packagename);
+ delete packagename;
+
+ compo.SetNameL(packagename8);
+ compo.SetVersionL(pkgDes);
+
+
+ Server().Storage()->UpdateL( compo );
+
+
+
+
+ RDEBUG( "CApplicationManagementSession::ActiveComponentsL ETrue" );
+
+
+ }
+ else
+ RDEBUG( "CApplicationManagementSession::ActiveComponentsL EFalse" );
CleanupStack::PopAndDestroy(2, &sisSession);
@@ -3662,6 +3691,8 @@
preInstallCompo->SetNameL(preInstalledAppName);
preInstallCompo->SetVersionL(preInstalledAppParams[count]->iVersion);
preInstallCompo->SetMimeTypeL(preInstalledAppParams[count]->iMimeType);
+ preInstallCompo->SetAppRemovableStatus(ETrue);
+
Server().Storage()->UpdateL( *preInstallCompo );
Server().Storage()->CheckForDuplicateNodesInDeployedL(*preInstallCompo);
}
--- a/customization/EmbeddedLinkAdapter/inc/EmbeddedLinkHandler.h Thu Jan 07 12:39:15 2010 +0200
+++ b/customization/EmbeddedLinkAdapter/inc/EmbeddedLinkHandler.h Mon Jan 18 20:09:30 2010 +0200
@@ -19,7 +19,7 @@
#define EMBEDDEDLINKHANDLER_H
#include <e32base.h>
-#include <FavouritesLimits.h>
+#include <favouriteslimits.h>
#include <e32std.h>
#include <FavouritesDb.h>
--- a/customization/isadapter/inc/IdleSoftkeysWebTargetManager.h Thu Jan 07 12:39:15 2010 +0200
+++ b/customization/isadapter/inc/IdleSoftkeysWebTargetManager.h Mon Jan 18 20:09:30 2010 +0200
@@ -24,7 +24,7 @@
#include <e32base.h>
#include <smldmadapter.h>
// s60
-#include <FavouritesDb.h> // Favourites Database
+#include <favouritesdb.h> // Favourites Database
class CUiSettingsUtil;
--- a/customization/isadapter/inc/UiSettingsUtil.h Thu Jan 07 12:39:15 2010 +0200
+++ b/customization/isadapter/inc/UiSettingsUtil.h Mon Jan 18 20:09:30 2010 +0200
@@ -19,7 +19,7 @@
#ifndef __UISETTINGSUTIL_H__
#define __UISETTINGSUTIL_H__
-#include <FavouritesDb.h> // Favourites Database
+#include <favouritesdb.h> // Favourites Database
#include <msvapi.h>
#include <apgcli.h>
#include <centralrepository.h>
--- a/customization/isadapter/src/UiSettingsUtil.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/customization/isadapter/src/UiSettingsUtil.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -17,7 +17,7 @@
// s60
-#include <FavouritesItemList.h>
+#include <favouritesitemlist.h>
#include <msvuids.h>
#include <SenduiMtmUids.h>
#include <javaregistryentrytype.h>
--- a/devicediagnostics/devdiagapp/src/devdiagsuitecontainer.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/devicediagnostics/devdiagapp/src/devdiagsuitecontainer.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -427,11 +427,13 @@
{
icons = iListBox->ItemDrawer()->ColumnData()->IconArray();
}
-
- for ( TInt i = 0; i < iChildren.Count(); ++i )
+ if(icons)
+ {
+ for ( TInt i = 0; i < iChildren.Count(); ++i )
{
icons->AppendL( iChildren[i]->CreateIconL( ));
- }
+ }
+ }
}
--- a/omadm/omadmextensions/adapters/connmoadapter/src/AddBuffer.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/omadm/omadmextensions/adapters/connmoadapter/src/AddBuffer.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -174,13 +174,17 @@
}
}
}
- OstTraceExt1( TRACE_NORMAL,
+ if ( resultNode != NULL )
+ {
+ OstTraceExt1( TRACE_NORMAL,
CADDBUFFER_FINDDYNAMICNODE_EXIT,
"EXIT: CAddBuffer::FindDynamicNode;resultNode=%s",
resultNode->iUri );
+ }
return resultNode;
}
+
//------------------------------------------------------------------------------
// CAddBuffer::Find
--- a/omadm/omadmextensions/adapters/connmoadapter/src/NapBranch.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/omadm/omadmextensions/adapters/connmoadapter/src/NapBranch.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -1192,11 +1192,24 @@
// Sanity check: If the dynamic name of the NAP node has is the same as deleted previously and
// DM Framework hasn't updated the tree, it will give the LUID when calling this method. Thus,
// it's needed to check that the connection method really exists.
- RCmConnectionMethodExt cm;
-
- if ( !GetConnectionMethodLC( *iCmManager, cm, CUtils::IntLUID( aParentLUID) ) )
- {
- // New node, add to buffer
+ TBuf8<KSmlMaxURISegLen> parentLUID;
+ parentLUID.Zero();
+ parentLUID = aParentLUID;
+ RCmConnectionMethodExt cm;
+ if ( !GetConnectionMethodLC( *iCmManager, cm, CUtils::IntLUID( parentLUID) ) )
+ {
+ if(aParentLUID.Length() > 0)
+ {
+ TInt ret = iCallback->RemoveMappingL(KConnMoAdapterUid,
+ GetDynamicNAPNodeUri( aURI ), ETrue );
+ if(ret)
+ {
+ iCallback->SetStatusL( aStatusRef, CSmlDmAdapter::EError );
+ CleanupStack::PopAndDestroy( &cm );
+ return;
+ }
+ }
+ // New node, add to buffer
iBuffer->AddNodeToBufferL( aURI, KNullDesC8, aStatusRef );
OstTrace0( TRACE_NORMAL, CNAPBRANCH_ADDNODEOBJECTL_NEW_NODE2,
"CNapBranch::AddNodeObjectL;New node -> Add to buffer." );
--- a/omadm/omadmextensions/adapters/connmoadapter/traces/OstTraceDefinitions.h Thu Jan 07 12:39:15 2010 +0200
+++ b/omadm/omadmextensions/adapters/connmoadapter/traces/OstTraceDefinitions.h Mon Jan 18 20:09:30 2010 +0200
@@ -1,19 +1,3 @@
-/*
-* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
-* All rights reserved.
-* This component and the accompanying materials are made available
-* under the terms of the License "Eclipse Public License v1.0"
-* which accompanies this distribution, and is available
-* at the URL "http://www.eclipse.org/legal/epl-v10.html".
-*
-* Initial Contributors:
-* Nokia Corporation - initial contribution.
-*
-* Contributors:
-*
-* Description:
-*
-*/
#ifndef __OSTTRACEDEFINITIONS_H__
#define __OSTTRACEDEFINITIONS_H__
// OST_TRACE_COMPILER_IN_USE flag has been added by Trace Compiler
--- a/omadm/omadmextensions/adapters/email/inc/nsmldmemailadapter.h Thu Jan 07 12:39:15 2010 +0200
+++ b/omadm/omadmextensions/adapters/email/inc/nsmldmemailadapter.h Mon Jan 18 20:09:30 2010 +0200
@@ -725,6 +725,13 @@
*/
TInt ConstructTreeL(const TDesC8& aURI);
+ /**
+ * The function extracts Email/x node from aURI
+ * @param aURI Email aURI.
+ * @return Email/x node.
+ */
+ TPtrC8 GetDynamicEmailNodeUri( const TDesC8& aURI );
+
private:
// Pointer to CMsvSession
CMsvSession* iMsvSession;
--- a/omadm/omadmextensions/adapters/email/src/nsmldmemailadapter.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/omadm/omadmextensions/adapters/email/src/nsmldmemailadapter.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -767,12 +767,19 @@
{
data = iBuffer->At(index).iImap4Settings->ServerAddress().AllocLC();
}
- HBufC8 *data8 = HBufC8::NewLC(data->Size());
- TPtr8 dataPtr8 = data8->Des();
- CnvUtfConverter::ConvertFromUnicodeToUtf8( dataPtr8, data->Des() );
+ else
+ {
+ status = CSmlDmAdapter::ENotFound;
+ }
+ if(data)
+ {
+ HBufC8 *data8 = HBufC8::NewLC(data->Size());
+ TPtr8 dataPtr8 = data8->Des();
+ CnvUtfConverter::ConvertFromUnicodeToUtf8( dataPtr8, data->Des() );
- object->InsertL(0,dataPtr8);
- CleanupStack::PopAndDestroy(2); //data, data8
+ object->InsertL(0,dataPtr8);
+ CleanupStack::PopAndDestroy(2); //data, data8
+ }
}
else if(lastUriSeg.Compare(KNSmlDMEmailMsnd)==0)
@@ -1246,6 +1253,17 @@
_DBG_FILE("CNSmlDmEmailAdapter::AddNodeObjectL(): EAlreadyExists end");
return;
}
+ else
+ {
+ TInt ret = Callback().RemoveMappingL( KNSmlDMEmailAdapterImplUid,
+ GetDynamicEmailNodeUri(aURI), ETrue );
+ if(ret != KErrNone)
+ {
+ Callback().SetStatusL(aStatusRef, CSmlDmAdapter::EError);
+ _DBG_FILE("CNSmlDmEmailAdapter::AddNodeObjectL(): EError end");
+ return;
+ }
+ }
Callback().SetMappingL(aURI,KNullDesC8);
}
@@ -2832,6 +2850,11 @@
{
data = iBuffer->At(index).iImap4Settings->ServerAddress().AllocLC();
}
+ else
+ {
+ status = CSmlDmAdapter::ENotFound;
+ return status;
+ }
HBufC8 *data8 = HBufC8::NewLC(data->Size());
TPtr8 dataPtr8 = data8->Des();
CnvUtfConverter::ConvertFromUnicodeToUtf8( dataPtr8, data->Des() );
@@ -3331,4 +3354,27 @@
CleanupStack::PopAndDestroy(); //emailAccs
return ret;
}
+
+//------------------------------------------------------------------------------
+// TPtrC8 CNSmlDmEmailAdapter::GetDynamicEmailNodeUri( const TDesC8& aURI )
+// returns Email/xxx URI
+//------------------------------------------------------------------------------
+TPtrC8 CNSmlDmEmailAdapter::GetDynamicEmailNodeUri( const TDesC8& aURI )
+ {
+ DBG_ARGS8(_S8("CNSmlDmEmailAdapter::GetDynamicEmailNodeUri() - <%S> "), &aURI);
+ TInt i= 0;
+ TBuf8<50> EmailAccRoot(KNSmlDMEmailNodeName);
+ for ( i = aURI.Find( KNSmlDMEmailNodeName ) + EmailAccRoot.Length() + 1;
+ i < aURI.Length(); i++ )
+ {
+ if( aURI[i] == '/' )
+ {
+ break;
+ }
+ }
+ _DBG_FILE("CNSmlDmEmailAdapter::GetDynamicEmailNodeUri(): end");
+ return aURI.Left( i );
+ }
+
+
// End of File
--- a/omadm/omadmextensions/adapters/imps/bld/nsmldmimpsadapter.mmp Thu Jan 07 12:39:15 2010 +0200
+++ b/omadm/omadmextensions/adapters/imps/bld/nsmldmimpsadapter.mmp Mon Jan 18 20:09:30 2010 +0200
@@ -42,4 +42,6 @@
LIBRARY euser.lib ecom.lib charconv.lib
LIBRARY sysutil.lib wvsapsettingsstore.lib efsrv.lib
LIBRARY nsmldmclientserverutils.lib nsmldmiapmatcher.lib nsmldebug.lib
-LIBRARY featmgr.lib
\ No newline at end of file
+LIBRARY featmgr.lib
+
+SMPSAFE
\ No newline at end of file
--- a/omadm/omadmextensions/adapters/nsmldinternet/src/NSmlInternetAdapter.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/omadm/omadmextensions/adapters/nsmldinternet/src/NSmlInternetAdapter.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -3694,12 +3694,8 @@
if ( aLUID.Length() > 0 )
{
// Stale data, remove mapping.
- RNSmlDMCallbackSession dMCbSession;
- User::LeaveIfError( dMCbSession.Connect() );
- CleanupClosePushL( dMCbSession );
-
- dMCbSession.RemoveMappingInfoL( KNSmlInternetAdapterImplUid, GetDynamicAPNodeUri( aURI ), ETrue );
- CleanupStack::PopAndDestroy( &dMCbSession );
+ TInt ret = iCallBack->RemoveMappingL( KNSmlInternetAdapterImplUid,
+ GetDynamicAPNodeUri( aURI ), ETrue );
}
iCallBack->SetStatusL( aStatusRef, CSmlDmAdapter::ENotFound );
@@ -4837,15 +4833,10 @@
tableView->ReadTextL( TPtrC(COMMDB_NAME ), name);
if ( name.Compare( aObject ) != 0 )
{
- // Not correct name
- RNSmlDMCallbackSession dMCbSession;
- User::LeaveIfError( dMCbSession.Connect() );
- CleanupClosePushL( dMCbSession );
-
+ // Not correct name
// Remove all mappings from AP/xxx level
- dMCbSession.RemoveMappingInfoL( KNSmlInternetAdapterImplUid, GetDynamicAPNodeUri( aURI ), ETrue );
- CleanupStack::PopAndDestroy( &dMCbSession );
-
+ TInt ret = iCallBack->RemoveMappingL( KNSmlInternetAdapterImplUid,
+ GetDynamicAPNodeUri( aURI ) , ETrue );
iPrevURI->Des().Format( KNullDesC8 );
iPrevLUID = 0;
}
@@ -4905,16 +4896,14 @@
!APExistsL( apId ) )
{
// AP has been deleted. Handle as new data.
- _DBG_FILE("CNSmlInternetAdapter::AddNodeObjectL(): parentLUID.Length() > 0 && !APExistsL() -> Remove mapping ");
-
- RNSmlDMCallbackSession dMCbSession;
- User::LeaveIfError( dMCbSession.Connect() );
- CleanupClosePushL( dMCbSession );
-
- // Remove all mappings from AP/xxx level
- dMCbSession.RemoveMappingInfoL( KNSmlInternetAdapterImplUid, GetDynamicAPNodeUri( aURI ), ETrue );
- CleanupStack::PopAndDestroy( &dMCbSession );
-
+ _DBG_FILE("CNSmlInternetAdapter::AddNodeObjectL(): parentLUID.Length() > 0 && !APExistsL() -> Remove mapping ");
+ TInt ret = iCallBack->RemoveMappingL( KNSmlInternetAdapterImplUid,
+ GetDynamicAPNodeUri( aURI ) , ETrue );
+ if(ret)
+ {
+ iCallBack->SetStatusL( aStatusRef, CSmlDmAdapter::EError );
+ return;
+ }
parentLUID.Zero();
iPrevURI->Des().Format( KNullDesC8 );
iPrevLUID = 0;
--- a/omadm/omadmextensions/adapters/nsmldinternet/src/NSmlWLanAdapter.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/omadm/omadmextensions/adapters/nsmldinternet/src/NSmlWLanAdapter.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -673,6 +673,10 @@
if (eapId == KErrNotFound)
{
_DBG_FILE("CNSmlWLanAdapter::AddLeafObjectL(): Non-EAP setting.");
+ if(luid==KErrNotFound)
+ {
+ return;
+ }
err = iWlanSettings->GetWlanSettings( luid, *iSettings );
}
else
@@ -1559,6 +1563,10 @@
if( ( NumOfUriSegs( aURI ) < 6 )
|| (aURI.Match( _L8("AP/*/NAPDef/*/WLAN/*") ) != KErrNotFound && NumOfUriSegs( aURI ) == 6 ) )
{
+ if(luid==KErrNotFound)
+ {
+ return;
+ }
TInt ret = iWlanSettings->DeleteWlanSettings( luid );
if( ret == KErrNone )
@@ -1743,7 +1751,12 @@
}
TPtrC8 lastUriSeg = GetLastUriSeg( aURI );
-
+
+ if(luid==KErrNotFound)
+ {
+ return;
+ }
+
TInt err = iWlanSettings->GetWlanSettings( luid, *iSettings );
if( err == KErrNotFound )
@@ -2451,7 +2464,11 @@
if( aURI.Match( _L8("AP/*/NAPDef/*") ) != KErrNotFound && uriSegs==4 )
{
DBG_ARGS8(_S8("WLanAdapter::ChildURIListL->NAPDef - <%S> <%S>"), &aURI, &aLUID );
- if( iWlanSettings->RecordExists( luid ) < 0 )
+ if(luid==KErrNotFound)
+ {
+ return;
+ }
+ if( iWlanSettings->RecordExists( luid ) < 0 )
{
currentUriSegmentList->InsertL( 0, KNSmlNAPDefWlanNode );
iCallBack->SetStatusL( aStatusRef, CSmlDmAdapter::EOk );
@@ -2484,6 +2501,10 @@
}
else
{
+ if(luid==KErrNotFound)
+ {
+ return;
+ }
if( iWlanSettings->RecordExists( luid ) < 0)
{
iCallBack->SetStatusL(aStatusRef,CSmlDmAdapter::ENotFound);
@@ -2522,6 +2543,10 @@
else if( aURI.Match( _L8("AP/*/NAPDef/*/WLAN/*") ) != KErrNotFound && uriSegs==6 )
{
DBG_ARGS8(_S8("WLanAdapter::ChildURIListL->NAPDef - <%S> <%S>"), &aURI, &aLUID );
+ if(luid==KErrNotFound)
+ {
+ return;
+ }
if( iWlanSettings->RecordExists( luid ) < 0 )
{
iCallBack->SetStatusL( aStatusRef, CSmlDmAdapter::ENotFound );
@@ -2574,6 +2599,10 @@
else if( aURI.Match( _L8("AP/*/NAPDef/*/WLAN/*/WEPKey/*") ) != KErrNotFound && uriSegs==8 )
{
DBG_ARGS8(_S8("WLanAdapter::ChildURIListL->WEPKey/* - <%S> <%D>"), &aURI, luid );
+ if(luid==KErrNotFound)
+ {
+ return;
+ }
if( iWlanSettings->RecordExists( luid ) < 0 )
{
//wlan settings not found for aLUID
@@ -2620,6 +2649,10 @@
}
else
{
+ if(luid==KErrNotFound)
+ {
+ return;
+ }
if( iWlanSettings->RecordExists( luid ) < 0)
{
iCallBack->SetStatusL(aStatusRef,CSmlDmAdapter::ENotFound);
@@ -2655,6 +2688,10 @@
else if( aURI.Match( _L8("AP/*/NAPDef/*/WLAN/*/SecondarySSID/*") ) != KErrNotFound && uriSegs==8 )
{
DBG_ARGS8(_S8("WLanAdapter::ChildURIListL->SecondarySSID/* - <%S> <%D>"), &aURI, luid );
+ if(luid==KErrNotFound)
+ {
+ return;
+ }
if( iWlanSettings->RecordExists( luid ) < 0 )
{
//wlan settings not found for aLUID
@@ -2677,6 +2714,10 @@
// Need to get the service id from parent node
luid = GetServiceIdFromUriL ( aURI );
+ if(luid==KErrNotFound)
+ {
+ return;
+ }
if( iWlanSettings->RecordExists( luid ) < 0 )
{
//wlan settings not found for aLUID
--- a/omadm/omadmextensions/adapters/streamingadapter/src/nsmlstreamingadapter.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/omadm/omadmextensions/adapters/streamingadapter/src/nsmlstreamingadapter.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -117,7 +117,8 @@
CleanupStack::PopAndDestroy(); // implArray
// Load default values
//iModel->LoadSettingsL(EConfigDefault);
- iModel->LoadSettingsL(EConfigUser);
+ if(iModel)
+ iModel->LoadSettingsL(EConfigUser);
}
_DBG_FILE("CNSmlDmStreamingAdapter::ConstructL: end");
}
--- a/omadm/omadmextensions/adapters/syncmldm12/inc/NSmlDMSettingsAdapter12.h Thu Jan 07 12:39:15 2010 +0200
+++ b/omadm/omadmextensions/adapters/syncmldm12/inc/NSmlDMSettingsAdapter12.h Mon Jan 18 20:09:30 2010 +0200
@@ -947,6 +947,13 @@
*/
TInt ConstructTreeL(const TDesC8& aURI);
+
+ /**
+ * The function extracts DMAcc/x node from aURI
+ * @param aURI DMAcc aURI.
+ * @return DMAcc/x node.
+ */
+ TPtrC8 GetDynamicDMNodeUri(const TDesC8& aURI);
private: // Data
--- a/omadm/omadmextensions/adapters/syncmldm12/src/NSmlDmSettingsAdapter12.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/omadm/omadmextensions/adapters/syncmldm12/src/NSmlDmSettingsAdapter12.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -1000,6 +1000,16 @@
iCallBack->SetStatusL( aStatusRef, CSmlDmAdapter::EAlreadyExists );
return;
}
+ else
+ {
+ TInt ret = iCallBack->RemoveMappingL(KNSmlDMSettingsAdapterImplUid,
+ GetDynamicDMNodeUri( aURI ), ETrue );
+ if(ret != KErrNone)
+ {
+ iCallBack->SetStatusL( aStatusRef, CSmlDmAdapter::EError );
+ return;
+ }
+ }
}
iNewProfile = ETrue;
AddNodeBufferL (aURI, aStatusRef);
@@ -3961,5 +3971,23 @@
return ImplementationTable;
}
+//------------------------------------------------------------------------------
+// TPtrC8 CNSmlDMSettingsAdapter12::GetDynamicDMNodeUri( const TDesC8& aURI )
+// returns DM/xxx URI
+//------------------------------------------------------------------------------
+TPtrC8 CNSmlDMSettingsAdapter12::GetDynamicDMNodeUri(const TDesC8& aURI)
+ {
+ TInt i= 0;
+ TBuf8<50> DmAccRoot(KNSmlDefDMAcc);
+ for ( i = aURI.Find( KNSmlDefDMAcc ) + DmAccRoot.Length() + 1; i < aURI.Length(); i++ )
+ {
+ if( aURI[i] == '/' )
+ {
+ break;
+ }
+ }
+
+ return aURI.Left( i );
+ }
// End of File
--- a/omadm/omadmextensions/adapters/syncmlds/inc/NSmlDSSettingsAdapter.h Thu Jan 07 12:39:15 2010 +0200
+++ b/omadm/omadmextensions/adapters/syncmlds/inc/NSmlDSSettingsAdapter.h Mon Jan 18 20:09:30 2010 +0200
@@ -919,6 +919,13 @@
TInt ConstructTreeL(const TDesC8& aURI);
+ /**
+ * The function extracts Syncml/DSAcc/x node from aURI
+ * @param aURI Syncml/DSAcc aURI.
+ * @return Syncml/DSAcc/x node.
+ */
+ TPtrC8 GetDynamicDSNodeUri(const TDesC8& aURI);
+
private: // Data
// Callback interface for returning result or status
--- a/omadm/omadmextensions/adapters/syncmlds/src/NSmlDsSettingsAdapter.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/omadm/omadmextensions/adapters/syncmlds/src/NSmlDsSettingsAdapter.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -941,6 +941,16 @@
}
else
{
+ if( aParentLUID.Length() > 0 )
+ {
+ TInt ret = iCallBack->RemoveMappingL(KNSmlDSSettingsAdapterImplUid,
+ GetDynamicDSNodeUri( aURI ), ETrue );
+ if(ret)
+ {
+ iCallBack->SetStatusL( aStatusRef, CSmlDmAdapter::EError );
+ return;
+ }
+ }
//
// Create new profile
//
@@ -3817,5 +3827,24 @@
CleanupStack::PopAndDestroy( 1 );//profileIdArray
return profileID;
}
+
+//------------------------------------------------------------------------------
+// TPtrC8 CUtils::GetDynamicDSNodeUri( const TDesC8& aURI )
+// returns Syncml/DSAcc/xxx URI
+//------------------------------------------------------------------------------
+TPtrC8 CNSmlDSSettingsAdapter::GetDynamicDSNodeUri(const TDesC8& aURI)
+ {
+ TInt i= 0;
+ TBuf8<50> DsAccRoot(KDSAcc1);
+ for ( i = aURI.Find( KDSAcc1 ) + DsAccRoot.Length() + 1 ; i < aURI.Length(); i++ )
+ {
+ if( aURI[i] == '/' )
+ { break;
+ }
+ }
+
+ return aURI.Left( i );
+ }
+
// End of File
--- a/pnpmobileservices/pnpms/OnlineSupport/inc/CCMAppUi.h Thu Jan 07 12:39:15 2010 +0200
+++ b/pnpmobileservices/pnpms/OnlineSupport/inc/CCMAppUi.h Mon Jan 18 20:09:30 2010 +0200
@@ -26,7 +26,7 @@
#include <e32std.h>
#include <coeccntx.h>
#include <aknappui.h>
-#include <FavouritesLimits.h> // for KFavouritesMaxUrl
+#include <favouriteslimits.h> // for KFavouritesMaxUrl
#include <sysutil.h>
#include <ApDataHandler.h> // for creating new Init Access
#include <ApAccessPointItem.h> // for creating new Init Access
--- a/pnpmobileservices/pnpms/OnlineSupport/src/CCMAppUi.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/pnpmobileservices/pnpms/OnlineSupport/src/CCMAppUi.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -28,7 +28,7 @@
#include <etelmm.h>
#include <textresolver.h>
#include <sysutil.h>
-#include <HttpFilterCommonStringsExt.h>
+#include <httpfiltercommonstringsext.h>
#include <OnlineSupport.rsg> // has to be system include.
#include <centralrepository.h> // link against centralrepository.lib
#include <BrowserUiSDKCRKeys.h> // for KCRUidBrowser
--- a/pnpmobileservices/pnpms/PnP/PnpProvisioningAppInc/PnpProvisioningSaver.h Thu Jan 07 12:39:15 2010 +0200
+++ b/pnpmobileservices/pnpms/PnP/PnpProvisioningAppInc/PnpProvisioningSaver.h Mon Jan 18 20:09:30 2010 +0200
@@ -47,7 +47,7 @@
* C++ default constructor.
* @param aEngine Engine to be used for saving
*/
- CPnpProvisioningSaver( CWPEngine& aEngine, TBool aSetAsDefault );
+ CPnpProvisioningSaver( CWPEngine& aEngine, TBool aSetAsDefault, TBool aWaitNote );
/**
* Destructor.
@@ -158,6 +158,7 @@
//End key pressed or not
TBool iEndKeyPressed;
+ TBool iShowWaitNote;
};
--- a/pnpmobileservices/pnpms/PnP/PnpProvisioningAppInc/PnpServiceActivation.h Thu Jan 07 12:39:15 2010 +0200
+++ b/pnpmobileservices/pnpms/PnP/PnpProvisioningAppInc/PnpServiceActivation.h Mon Jan 18 20:09:30 2010 +0200
@@ -59,6 +59,8 @@
* settings ID
*/
TBool ValidateAppUidWithProvappIDL();
+ TUint32 iLaunchUid;
+ TUint32 iPosition;
public:
@@ -79,7 +81,12 @@
// Additional functions can be added if new functions are required
// for service activation
+ TBool isPresent(TDesC& p );
+ void ParseValues(RPointerArray<HBufC>& array, TDesC& aValue);
+ void GetCenrepValueL(const TUid aRepositoryUid,TUint32 aKey, TDes16& aValue);
+ TBool Search(RPointerArray<HBufC>& array,TDesC& p);
+ TBool isFound(TDesC& p,TUint32 position);
};
--- a/pnpmobileservices/pnpms/PnP/PnpProvisioningAppSrc/PnpProvisioningAppUi.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/pnpmobileservices/pnpms/PnP/PnpProvisioningAppSrc/PnpProvisioningAppUi.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -24,7 +24,7 @@
#include <rconnmon.h>
#include <ApUtils.h>
#include <PnpProvisioning.rsg>
-#include <BrowserUiSDKCRKeys.h> // for KCRUidBrowser
+#include <browseruisdkcrkeys.h> // for KCRUidBrowser
#include <AknGlobalNote.h> // for CAknGlobalNote
#include <AknGlobalConfirmationQuery.h> // for CAknGlobalConfirmationQuery
--- a/pnpmobileservices/pnpms/PnP/PnpProvisioningAppSrc/PnpProvisioningDocument.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/pnpmobileservices/pnpms/PnP/PnpProvisioningAppSrc/PnpProvisioningDocument.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -237,11 +237,11 @@
TInt numSaved( 0 );
- CPnpProvisioningSaver* saver = new(ELeave) CPnpProvisioningSaver( *wpengine, EFalse );
+ CPnpProvisioningSaver* saver = new(ELeave) CPnpProvisioningSaver( *wpengine, EFalse, EFalse );
TInt retValue( KErrNone );
LOGSTRING("saver created");
// dismiss waitdialog, saver will show own waitdialog
- iAppUi->WaitDialogDismissedL(EAknSoftkeyEmpty);
+ //iAppUi->WaitDialogDismissedL(EAknSoftkeyEmpty);
TRAPD( saverErr, retValue = saver->ExecuteLD( numSaved ) );
@@ -328,8 +328,17 @@
if( setAsDefault )
{
LOGSTRING( "create setter" );
- CPnpProvisioningSaver* setter = new(ELeave) CPnpProvisioningSaver( *wpengine, ETrue );
+ CPnpProvisioningSaver* setter = NULL;
TInt numSet( 0 );
+ if(!activate)
+ {
+ setter = new(ELeave) CPnpProvisioningSaver( *wpengine, ETrue, ETrue );
+ iAppUi->WaitDialogDismissedL(EAknSoftkeyEmpty);
+ }
+ else
+ {
+ setter = new(ELeave) CPnpProvisioningSaver( *wpengine, ETrue, EFalse );
+ }
LOGSTRING( "setter->ExecuteLD" );
setter->ExecuteLD( numSet );
}
@@ -347,12 +356,6 @@
globalNote->ShowNoteL( EAknGlobalInformationNote , *msgTextSaved );
CleanupStack::PopAndDestroy( 2 );
}
- else
- {
- CPnpServiceActivation *service = CPnpServiceActivation::NewLC();
- service->DisplayAppSpecNoteL();
- CleanupStack::PopAndDestroy();
- }
}
else
--- a/pnpmobileservices/pnpms/PnP/PnpProvisioningAppSrc/PnpProvisioningSaver.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/pnpmobileservices/pnpms/PnP/PnpProvisioningAppSrc/PnpProvisioningSaver.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -39,10 +39,10 @@
// ================= MEMBER FUNCTIONS =======================
// C++ default constructor.
-CPnpProvisioningSaver::CPnpProvisioningSaver( CWPEngine& aEngine, TBool aSetAsDefault )
+CPnpProvisioningSaver::CPnpProvisioningSaver( CWPEngine& aEngine, TBool aSetAsDefault, TBool aWaitNote )
: CActive( EPriorityStandard ), iEngine( aEngine ),
iSetAsDefault( aSetAsDefault ),
- iCurrentItem( 0 ), iResult( KErrNone ),iEndKeyPressed(EFalse)
+ iCurrentItem( 0 ), iResult( KErrNone ),iEndKeyPressed(EFalse), iShowWaitNote(aWaitNote)
{
CActiveScheduler::Add( this );
}
@@ -64,6 +64,7 @@
LOGSTRING("Constructing dialog");
// Set up the dialog and callback mechanism.
+ if(iSetAsDefault && iShowWaitNote)
ShowWaitNoteL();
}
@@ -161,16 +162,10 @@
}
else
{
- if(iWaitDialogMonitor->iStatus != KErrCancel)
- {
+
LOGSTRING2("Saving item: %i", iCurrentItem );
TRAP( err, iEngine.SaveL( iCurrentItem ) );
- }
- else
- {
- iEndKeyPressed = ETrue; //means End key or cancel pressed before saving some sttings
- LOGSTRING2("item: %i not saved", iCurrentItem );
- }
+
}
// If CommsDB or BookmarkDB are locked, schedule a retry
@@ -203,12 +198,12 @@
if( iCurrentItem == iEngine.ItemCount()-1 )
{
LOGSTRING("All saved");
- LOGSTRING2( "Saver RunL iWaitDialogMonitor->iStatus %i", iWaitDialogMonitor->iStatus.Int() );
+ //LOGSTRING2( "Saver RunL iWaitDialogMonitor->iStatus %i", iWaitDialogMonitor->iStatus.Int() );
ProcessFinishedL();
}
else
{
- LOGSTRING2( "Saver RunL 2nd iWaitDialogMonitor->iStatus %i", iWaitDialogMonitor->iStatus.Int() );
+ //LOGSTRING2( "Saver RunL 2nd iWaitDialogMonitor->iStatus %i", iWaitDialogMonitor->iStatus.Int() );
iCurrentItem++;
CompleteRequest();
}
@@ -220,7 +215,10 @@
//
void CPnpProvisioningSaver::ProcessFinishedL()
{
- LOGSTRING2( "Saver iWaitDialogMonitor->iStatus %i", iWaitDialogMonitor->iStatus.Int() );
+ //LOGSTRING2( "Saver iWaitDialogMonitor->iStatus %i", iWaitDialogMonitor->iStatus.Int() );
+ iWait.AsyncStop();
+ if(iWaitDialogMonitor)
+ {
//End key or cancel pressed after saving settings
if(iWaitDialogMonitor->iStatus == KErrCancel)
{
@@ -231,6 +229,7 @@
delete iGlobalWaitNote;
iGlobalWaitNote = NULL;
}
+ }
}
// ---------------------------------------------------------
--- a/pnpmobileservices/pnpms/PnP/PnpProvisioningAppSrc/PnpServiceActivation.cpp Thu Jan 07 12:39:15 2010 +0200
+++ b/pnpmobileservices/pnpms/PnP/PnpProvisioningAppSrc/PnpServiceActivation.cpp Mon Jan 18 20:09:30 2010 +0200
@@ -27,21 +27,22 @@
#include <StringLoader.h>
#include <PnpProvisioning.rsg>
#include <AknGlobalNote.h>
+#include <centralrepository.h>
+
+#include <e32svr.h>
+#include <centralrepository.h>
+#include "PnpLogger.h"
-const TUint32 KEmailApplicationUID[] = {0x100058C5};
-
+const TUid KCRUidPnPProvisioning = {0x10204338};
// Browser UID
const TUid KWAPBrowserUID = { 0x10008d39 };
-
+const TInt KMaxLength = 255;
// POP3 and IMAP4 provisioning settings application ID
-_LIT(KEmailProvAppPOP3ID, "110");
-_LIT(KEmailProvAppIMAP4ID, "143");
// Literal constants
-_LIT( KMessagingAppName, "z:\\sys\\bin\\mce.exe" );
-_LIT( KEmptyDoc, "");
-
+
+const TUint32 KServiceAct1 = 0x00000100;
// INCLUDE FILES
@@ -111,18 +112,19 @@
{
- CApaCommandLine* cmd = CApaCommandLine::NewLC();
- cmd->SetExecutableNameL( KMessagingAppName );
- cmd->SetDocumentNameL( KEmptyDoc );
- cmd->SetCommandL( EApaCommandOpen );
RApaLsSession appArcSession;
User::LeaveIfError( appArcSession.Connect() );
- appArcSession.StartApp( *cmd );
- appArcSession.Close();
- CleanupStack::PopAndDestroy( cmd );
+ CleanupClosePushL( appArcSession );
+ TApaAppInfo appInfo;
+ User::LeaveIfError(appArcSession.GetAppInfo( appInfo, TUid::Uid( iLaunchUid) ) );
+ CApaCommandLine* cmdLine = CApaCommandLine::NewLC();
+ cmdLine->SetCommandL( EApaCommandRun );
+ cmdLine->SetExecutableNameL( appInfo.iFullName );
+ User::LeaveIfError( appArcSession.StartApp( *cmdLine ) );
+ CleanupStack::PopAndDestroy( 2 ); // cmdLine, appArcSession
}
}
@@ -137,23 +139,35 @@
// Get application ID and Provisioning settings application
// ID and validate the application launcher
- TBool flag (EFalse);
+
RPointerArray<HBufC> appID;
+ TBuf<16> pLaunchUid;
+ TBool returnFlag (EFalse);
+ TBool FoundUid(EFalse);
+ TBool FoundAppid(EFalse);
CPnpProvUtil *provutil = CPnpProvUtil::NewLC();
- TUint32 val = provutil->GetApplicationUidL();
- if(val == KEmailApplicationUID[0])
- {
+ iLaunchUid = provutil->GetApplicationUidL();
+
provutil->GetProvAdapterAppIdsL(appID);
+ pLaunchUid.Num(iLaunchUid);
+ FoundUid = isPresent(pLaunchUid);
+ TUint32 secondPosition = iPosition+200;
+ if(FoundUid)
+ {
for(TInt i=0; i<appID.Count(); i++)
{
TPtrC ptr(*appID[i]);
- if(ptr.Compare(KEmailProvAppPOP3ID) ==0||
- ptr.Compare(KEmailProvAppIMAP4ID) ==0 )
- flag = ETrue;
-
+ FoundAppid = isFound(ptr,secondPosition);
+ if(FoundAppid)
+ {
+ if(iPosition == KServiceAct1){
+ DisplayAppSpecNoteL();
+ }
+ returnFlag = ETrue;
+ }
}
}
@@ -162,7 +176,7 @@
appID.ResetAndDestroy();
appID.Close();
- return flag;
+ return returnFlag;
}
@@ -205,5 +219,95 @@
CleanupStack::PopAndDestroy( 2 );
}
+TBool CPnpServiceActivation::isPresent(TDesC& p)
+{
+ TBool flag(EFalse);
+ TUint32 position = KServiceAct1;
+ for(TInt i=0;i<=299;i++)
+ {
+ TBool val = isFound(p,position);
+ if(val)
+ {
+ iPosition = position;
+ flag = ETrue;
+ break;
+ }
+ position++;
+ }
+ return flag;
+ }
+TBool CPnpServiceActivation::isFound(TDesC& p,TUint32 position)
+{
+ TBool val(EFalse);
+ TBuf16<KMaxLength> keys;
+ HBufC* heapBuf = HBufC::NewLC(20);
+ TPtr ptr(heapBuf->Des());
+ ptr = keys;
+ RPointerArray<HBufC> array;
+ TRAPD( errVal,GetCenrepValueL(KCRUidPnPProvisioning,position,keys));
// End of File
+ if(errVal != KErrNone)
+ {
+ CleanupStack::PopAndDestroy();
+ return val;
+ }
+ ParseValues(array, keys);
+ val = Search(array,p);
+ CleanupStack::PopAndDestroy(heapBuf);
+ array.ResetAndDestroy();
+ array.Close();
+ return val;
+}
+TBool CPnpServiceActivation::Search(RPointerArray<HBufC>& array,TDesC& p)
+{
+ TBool flag(EFalse);
+ for(TInt j=0; j<array.Count(); j++)
+ {
+ TPtrC ptr(*array[j]);
+ if(!ptr.Compare(p))
+ {
+ flag = ETrue;
+ }
+ }
+ return flag;
+}
+void CPnpServiceActivation::ParseValues(RPointerArray<HBufC>& array, TDesC& aValue)
+{
+ TLex aLex(aValue);
+ while(aLex.Peek() != '\x00')
+ {
+ aLex.Mark();
+ while(aLex.Peek()!=',' && aLex.Peek()!='\x00')
+ aLex.Inc();
+ TPtrC aPtr = aLex.MarkedToken();
+ HBufC *buf18 = aPtr.AllocL();
+ array.Append(buf18);
+ if(aLex.Peek()=='\x00') // end of string
+ break;
+ aLex.Inc();
+ }
+}
+void CPnpServiceActivation::GetCenrepValueL(const TUid aRepositoryUid,TUint32 aKey, TDes16& aValue)
+ {
+ CRepository * rep = NULL;
+ TInt errorStatus = KErrNone;
+ TRAPD( errVal, rep = CRepository::NewL(aRepositoryUid));
+ if(errVal == KErrNone)
+ {
+ errorStatus = rep->Get( aKey , aValue );
+ }
+ else
+ {
+ errorStatus = errVal;
+ }
+
+ if(rep)
+ {
+ delete rep;
+ }
+ if(errorStatus != KErrNone )
+ {
+ User::Leave(errorStatus);
+ }
+ }
Binary file pnpmobileservices/pnpms/conf/pnpms.confml has changed
Binary file pnpmobileservices/pnpms/conf/pnpms_10204338.crml has changed
Binary file pnpmobileservices/pnpms/conf/pnpms_1020433A.crml has changed
--- a/pnpmobileservices/pnpms/group/OnlineSupport.mmp Thu Jan 07 12:39:15 2010 +0200
+++ b/pnpmobileservices/pnpms/group/OnlineSupport.mmp Mon Jan 18 20:09:30 2010 +0200
@@ -27,7 +27,7 @@
UID 0x100039CE 0x10204338
SECUREID 0x10204338
VENDORID VID_DEFAULT
-CAPABILITY CAP_APPLICATION PowerMgmt
+CAPABILITY CAP_APPLICATION PowerMgmt AllFiles
SOURCEPATH ../OnlineSupport/src
--- a/pnpmobileservices/pnpms/group/Pnpprovisioning.mmp Thu Jan 07 12:39:15 2010 +0200
+++ b/pnpmobileservices/pnpms/group/Pnpprovisioning.mmp Mon Jan 18 20:09:30 2010 +0200
@@ -29,7 +29,7 @@
VENDORID VID_DEFAULT
-CAPABILITY CAP_APPLICATION NetworkControl // NetworkControl needed when closing connections
+CAPABILITY CAP_APPLICATION NetworkControl AllFiles // NetworkControl needed when closing connections
SOURCEPATH ../PnP/PnpProvisioningAppSrc
SOURCE PnpProvisioningApp.cpp
@@ -78,7 +78,7 @@
LIBRARY efsrv.lib hash.lib apgrfx.lib
LIBRARY commdb.lib // for commdb
LIBRARY nhwrparser.lib charconv.lib
-LIBRARY connmon.lib pnp.lib
+LIBRARY connmon.lib pnp.lib centralrepository.lib
DEBUGLIBRARY flogger.lib
SMPSAFE