# HG changeset patch # User Dremov Kirill (Nokia-D-MSW/Tampere) # Date 1265062990 -7200 # Node ID 1a2a00e7866593e713ff15666bc8b4ca304b2a8e # Parent ff572005ac2309eeaea59875c12a2ae588009cba Revision: 201003 Kit: 201005 diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/hspsdom/src/hspsdomstringpool.cpp --- a/homescreenpluginsrv/hspsdom/src/hspsdomstringpool.cpp Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/hspsdom/src/hspsdomstringpool.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -153,7 +153,10 @@ // const TDesC8& ChspsDomStringPool::String( const TInt aStringRef ) { - return (*iStringPool[ aStringRef ]); + if ( aStringRef < iStringPool.Count() ) + return (*iStringPool[ aStringRef ]); + else + return KNullDesC8; } // ----------------------------------------------------------------------------- diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/hspsmanager/bwins/hspsclientsessionu.def --- a/homescreenpluginsrv/hspsmanager/bwins/hspsclientsessionu.def Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/hspsmanager/bwins/hspsclientsessionu.def Tue Feb 02 00:23:10 2010 +0200 @@ -24,4 +24,5 @@ ?AccessResourceFile@RhspsClientSession@@IAEHAAVTDes8@@ABUThspsConfiguration@@ABVTDesC16@@AAH@Z @ 23 NONAME ; int RhspsClientSession::AccessResourceFile(class TDes8 &, struct ThspsConfiguration const &, class TDesC16 const &, int &) ?GetODTUpdate@RhspsClientSession@@IAEXAAVTDes8@@00AAVTRequestStatus@@@Z @ 24 NONAME ; void RhspsClientSession::GetODTUpdate(class TDes8 &, class TDes8 &, class TDes8 &, class TRequestStatus &) ?ReinstallConf@RhspsClientSession@@IAEHAAVTDes8@@ABUThspsParamReinstallConf@@@Z @ 25 NONAME ; int RhspsClientSession::ReinstallConf(class TDes8 &, struct ThspsParamReinstallConf const &) + ?RestoreConfigurations@RhspsClientSession@@IAEHAAVTDes8@@ABUThspsParamRestoreConfigurations@@@Z @ 26 NONAME ; int RhspsClientSession::RestoreConfigurations(class TDes8 &, struct ThspsParamRestoreConfigurations const &) diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/hspsmanager/bwins/hspsclientu.def --- a/homescreenpluginsrv/hspsmanager/bwins/hspsclientu.def Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/hspsmanager/bwins/hspsclientu.def Tue Feb 02 00:23:10 2010 +0200 @@ -28,4 +28,5 @@ ?hspsMovePluginsL@ChspsClient@@UAE?AW4ThspsServiceCompletedMessage@@HHABV?$CArrayFixFlat@H@@@Z @ 27 NONAME ; enum ThspsServiceCompletedMessage ChspsClient::hspsMovePluginsL(int, int, class CArrayFixFlat const &) ?hspsGetListHeaders@ChspsClient@@UAE?AW4ThspsServiceCompletedMessage@@ABVChspsODT@@AAV?$CArrayPtrFlat@VChspsODT@@@@@Z @ 28 NONAME ; enum ThspsServiceCompletedMessage ChspsClient::hspsGetListHeaders(class ChspsODT const &, class CArrayPtrFlat &) ?hspsRemoveThemeL@ChspsClient@@UAE?AW4ThspsServiceCompletedMessage@@ABVChspsODT@@@Z @ 29 NONAME ; enum ThspsServiceCompletedMessage ChspsClient::hspsRemoveThemeL(class ChspsODT const &) + ?hspsRestoreConfigurations@ChspsClient@@QAE?AW4ThspsServiceCompletedMessage@@HH@Z @ 30 NONAME ; enum ThspsServiceCompletedMessage ChspsClient::hspsRestoreConfigurations(int, int) diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/hspsmanager/client/hspsclient.cpp --- a/homescreenpluginsrv/hspsmanager/client/hspsclient.cpp Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/hspsmanager/client/hspsclient.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -880,6 +880,29 @@ return ret; } + + +// ----------------------------------------------------------------------------- +// ChspsClient::hspsRestoreConfigurations +// ----------------------------------------------------------------------------- +// +EXPORT_C ThspsServiceCompletedMessage ChspsClient::hspsRestoreConfigurations( + const TInt aAppUid, + const TBool aReinstall ) + { + ThspsServiceCompletedMessage ret = EhspsRestoreConfigurationsFailed; + + ThspsParamRestoreConfigurations params; + params.appUid = aAppUid; + params.restoreAll = aReinstall; + + ret = ( ThspsServiceCompletedMessage )iSession.RestoreConfigurations( iResultData, params ); + + UpdatehspsResult( iResultData ); + + return ret; + } + // ----------------------------------------------------------------------------- // ChspsClient::hspsPluginUpdateL // ----------------------------------------------------------------------------- diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/hspsmanager/client/hspsclientsession.cpp --- a/homescreenpluginsrv/hspsmanager/client/hspsclientsession.cpp Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/hspsmanager/client/hspsclientsession.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -469,5 +469,18 @@ return SendReceive( EhspsRestoreActiveAppConf, TIpcArgs( &aResultData, &packagedStruct ) ); } +// ----------------------------------------------------------------------------- +// RhspsClientSession::RestoreConfigurations +// ----------------------------------------------------------------------------- +// +EXPORT_C TInt RhspsClientSession::RestoreConfigurations( + TDes8& aResultData, + const ThspsParamRestoreConfigurations& aParams ) + { + aResultData.Zero(); + TPckgC packagedStruct( aParams ); + return SendReceive( EhspsRestoreConfigurations, TIpcArgs( &aResultData, &packagedStruct ) ); + } + // end of file diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/hspsmanager/eabi/hspsclientsessionu.def --- a/homescreenpluginsrv/hspsmanager/eabi/hspsclientsessionu.def Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/hspsmanager/eabi/hspsclientsessionu.def Tue Feb 02 00:23:10 2010 +0200 @@ -24,4 +24,5 @@ _ZN18RhspsClientSession6GetODTER5TDes8RK18ThspsConfigurationRK6TDesC8R6TDes16 @ 23 NONAME _ZN18RhspsClientSession7ConnectEv @ 24 NONAME _ZN18RhspsClientSession9AddPluginER5TDes8RK18ThpsParamAddPluginRi @ 25 NONAME + _ZN18RhspsClientSession21RestoreConfigurationsER5TDes8RK31ThspsParamRestoreConfigurations @ 26 NONAME diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/hspsmanager/eabi/hspsclientu.def --- a/homescreenpluginsrv/hspsmanager/eabi/hspsclientu.def Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/hspsmanager/eabi/hspsclientu.def Tue Feb 02 00:23:10 2010 +0200 @@ -52,4 +52,5 @@ _ZThn32_N11ChspsClient21hspsSetPluginSettingsERK8ChspsODTiR16ChspsDomDocumenti @ 51 NONAME _ZThn32_N11ChspsClient24hspsCancelGetListHeadersEv @ 52 NONAME _ZThn32_N11ChspsClient24hspsRestoreActiveAppConfEii @ 53 NONAME + _ZN11ChspsClient25hspsRestoreConfigurationsEii @ 54 NONAME diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/hspsmanager/inc/hspsconfiguration.h --- a/homescreenpluginsrv/hspsmanager/inc/hspsconfiguration.h Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/hspsmanager/inc/hspsconfiguration.h Tue Feb 02 00:23:10 2010 +0200 @@ -37,6 +37,7 @@ _LIT8( KConfigurationAttrDesc, "desc" ); // Localized description _LIT8( KConfigurationAttrDescEntity, "_desc" ); // Logical string id of the Description attr (DTD entity) _LIT8( KConfigurationAttrMaxChild, "max_child" ); // Maximum child count +_LIT8( KConfigurationAttrLocking, "locking_status" ); // Locking status // Configuration element type attribute values @@ -51,6 +52,11 @@ _LIT8( KConfStateConfirmed, "Confirmed" ); // Confirmed state _LIT8( KConfStateError, "Error" ); // Error state +// Options for the KConfigurationAttrLocking +_LIT8( KConfLockingLocked, "locked" ); // Locked state +_LIT8( KConfLockingRemovable, "removable" ); // Removable state +_LIT8( KConfLockingNone, "none" ); // Default + // Control element _LIT8( KControlElement, "control" ); _LIT8( KControlAttrName, "name" ); // Localized name of the configuration diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/hspsmanager/inc/hspsmaintenancehandler.h --- a/homescreenpluginsrv/hspsmanager/inc/hspsmaintenancehandler.h Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/hspsmanager/inc/hspsmaintenancehandler.h Tue Feb 02 00:23:10 2010 +0200 @@ -266,6 +266,13 @@ * @param @param aServerSession Pointer to owning server session */ void SetServerSession( ChspsThemeServerSession* aServerSession ); + + /** + * ServiceRestoreConfigurationsL + * @since S60 5.2 + * @param aMessage contains the data received from the client + */ + void ServiceRestoreConfigurationsL( const RMessage2& aMessage ); public: // Functions from base classes @@ -575,6 +582,17 @@ ); /** + * Checks if the provided plugin configuration is a collection of plugin + * configurations, e.g. view configuration. + * Alternatively, we could check the type from header cache + * @since S60 5.2 + * @param aPluginNode Plugin node + * @return True if it is a view configuration + */ + TBool IsViewConfiguration( + ChspsDomNode& aPluginNode ); + + /** * Removes an plugin instance from the provided application configuration * @since S60 5.0 * @param aAppODT is an instance of the the application configuration @@ -583,7 +601,18 @@ */ TInt RemoveConfigurationL( ChspsODT& aAppODT, - const TInt aPluginId ); + const TInt aPluginId ); + + /** + * Removes an plugin instance from the provided application configuration + * @since S60 5.0 + * @param aAppODT is an instance of the the application configuration + * @param aPluginNode is a node of the plugin instance to be removed + * @return KErrNone if succeeded + */ + TInt RemoveConfigurationL( + ChspsODT& aAppODT, + ChspsDomNode& aPluginNode ); /** * Finds a plugin node with the provided id which is also a children of @@ -796,6 +825,55 @@ ChspsDomNode& aMissingPluginNode, const TInt aPluginUid ); + /** + * Removes all plugins from the plugins node and related + * resources from the resource array. + * @since S60 5.2 + * @param aAppODT Application configuration + * @return error code + */ + TInt RestoreActiveViewL( + ChspsODT& aAppODT ); + + /** + * Finds a plugin node which is the active view configuration. + * @since S60 5.2 + * @param aAppODT Application configuration + * @return Active plugin node or NULL + */ + ChspsDomNode* FindActiveView( + ChspsODT& aAppODT ); + + /** + * Removes all plugin configurations from the provided + * plugin node (view configuration). + * @since S60 5.2 + * @param aAppODT Application configuration + * @param aActivePluginNode Plugin node to be modified + * @return error code + */ + TInt RemovePluginConfigurationsL( + ChspsODT& aAppODT, + ChspsDomNode& aActivePluginNode ); + + /** + * Removes all unlocked views and reset the active view. + * Can leave if DOM is corrupted (objects are not found) or in OOM cases. + * @since S60 5.2 + * @param aAppODT Application configuration + */ + void RemoveUnlockedViewsL( + ChspsODT& aAppODT ); + + /** + * Checks whether the plugin configuration was locked. + * @since S60 5.2 + * @param aConfNode Configuration node + * @return True if it was locked + */ + TBool IsConfigurationLocked( + ChspsDomNode& aConfNode ); + private: // Data RMessagePtr2 iMessagePtr; ChspsResult* iResult; diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/hspsmanager/inc/hspsthemeserversession.h --- a/homescreenpluginsrv/hspsmanager/inc/hspsthemeserversession.h Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/hspsmanager/inc/hspsthemeserversession.h Tue Feb 02 00:23:10 2010 +0200 @@ -214,6 +214,12 @@ * @since S60 5.0 */ void RestoreActiveAppConfL(const RMessage2& aMessage); + + /** + * RestoreConfigurationsL + * @since S60 5.2 + */ + void RestoreConfigurationsL( const RMessage2& aMessage ); /**************************************** * hspsClientRequestService requests diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/hspsmanager/src/hspsmaintenancehandler.cpp --- a/homescreenpluginsrv/hspsmanager/src/hspsmaintenancehandler.cpp Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/hspsmanager/src/hspsmaintenancehandler.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -1851,7 +1851,27 @@ #endif // ----------------------------------------------------------------------------- -// Removes an plugin instance from the provided application configuration +// ChspsMaintenanceHandler::IsViewConfiguration() +// ----------------------------------------------------------------------------- +// +TBool ChspsMaintenanceHandler::IsViewConfiguration( + ChspsDomNode& aPluginNode ) + { + TBool isView = EFalse; + + ChspsDomNode* confNode = + (ChspsDomNode*)aPluginNode.ChildNodes().FindByName( KConfigurationElement ); + if( confNode ) + { + ChspsDomAttribute* typeAttr = + (ChspsDomAttribute*)confNode->AttributeList().FindByName( KConfigurationAttrType ); + isView = ( typeAttr->Value().CompareF( KConfTypeView ) == 0 ); + } + return isView; + } + +// ----------------------------------------------------------------------------- +// ChspsMaintenanceHandler::RemoveConfigurationL() // ----------------------------------------------------------------------------- // TInt ChspsMaintenanceHandler::RemoveConfigurationL( @@ -1861,96 +1881,153 @@ TInt err = KErrNotFound; // Find a plugin node with the provided id - ChspsDomNode *node = hspsServerUtil::FindPluginNodeL( aAppODT, aPluginId ); - if ( node ) - { - // Get parent node - ChspsDomNode *parentNode = node->Parent(); - if ( parentNode ) + ChspsDomNode *pluginNode = hspsServerUtil::FindPluginNodeL( aAppODT, aPluginId ); + if ( pluginNode ) + { + // Remove the node + err = RemoveConfigurationL( aAppODT, *pluginNode ); + } + + return err; + } + +// ----------------------------------------------------------------------------- +// Removes an plugin instance from the provided application configuration +// ----------------------------------------------------------------------------- +// +TInt ChspsMaintenanceHandler::RemoveConfigurationL( + ChspsODT& aAppODT, + ChspsDomNode& aPluginNode ) + { + TInt err = KErrNotFound; + + // Get parent node + ChspsDomNode *parentNode = aPluginNode.Parent(); + if ( parentNode ) + { + ChspsDomList& attrList = aPluginNode.AttributeList(); + + // Get uid attribute from the node + TInt pluginUid = 0; + ChspsDomAttribute* pluginUidAttr = + static_cast ( attrList.FindByName(KPluginAttrUid) ); + if( !pluginUidAttr ) + { +#ifdef HSPS_LOG_ACTIVE + if( iLogBus ) + { + iLogBus->LogText( _L( "ChspsMaintenanceHandler::RemoveConfigurationL(): - Invalid XML" ) ); + } +#endif + + err = KErrGeneral; + } + else + { + // Convert uids from string to numeric format + const TDesC8& pluginUidValue = pluginUidAttr->Value(); + const TUid uid = hspsServerUtil::ConvertDescIntoUid(pluginUidValue); + if ( uid.iUid > 0 ) + { + pluginUid = uid.iUid; + // Override default status + err = KErrNone; + } + } + + // Store activity state for use after deletion. + TBool pluginWasActive = EFalse; + ChspsDomAttribute* pluginActivityAttr = + static_cast( attrList.FindByName( KPluginAttrActive ) ); + if( pluginActivityAttr ) + { + if( pluginActivityAttr->Value().CompareF( KPluginActiveStateActive ) == 0 ) + { + pluginWasActive = ETrue; + } + } + + if ( !err ) { - // Get uid attribute from the node - TInt pluginUid = 0; - ChspsDomList& attrList = node->AttributeList(); - ChspsDomAttribute* pluginUidAttr = - static_cast ( attrList.FindByName(KPluginAttrUid) ); - if( !pluginUidAttr ) + // If user is removing a view plugin + if( IsViewConfiguration( aPluginNode ) ) { -#ifdef HSPS_LOG_ACTIVE - if( iLogBus ) + // first all subplugins need to be removed, so that the application's resource array + // (visible in ODT dump) contains only valid resources + ChspsDomNode* confNode = + (ChspsDomNode*)aPluginNode.ChildNodes().FindByName( KConfigurationElement ); + if( confNode ) { - iLogBus->LogText( _L( "ChspsMaintenanceHandler::RemoveConfigurationL(): - Invalid XML" ) ); - } -#endif + ChspsDomNode* controlNode = + (ChspsDomNode*)confNode->ChildNodes().FindByName( KControlElement ); + if( controlNode ) + { + ChspsDomNode *pluginsNode = + (ChspsDomNode*)controlNode->ChildNodes().FindByName( KPluginsElement ); + if( pluginsNode ) + { + RPointerArray nodeArray; + CleanupClosePushL( nodeArray ); + + // Get plugin nodes + TInt pluginCount = pluginsNode->ChildNodes().Length(); + for( TInt pluginIndex=0; pluginIndex < pluginCount; pluginIndex++ ) + { + nodeArray.Append( (ChspsDomNode*)pluginsNode->ChildNodes().Item( pluginIndex ) ); + } + + // Remove the nodes and related resources + for( TInt pluginIndex=0; pluginIndex < pluginCount; pluginIndex++ ) + { + RemoveConfigurationL( aAppODT, *nodeArray[pluginIndex ] ); + } + + nodeArray.Reset(); + CleanupStack::PopAndDestroy( 1, &nodeArray ); + } + } + } + } + + // Get number of plugin instances with the plugin uid + TInt instanceCount = 0; + GetPluginInstanceCountL( + aAppODT, + pluginUid, + instanceCount ); - err = KErrGeneral; - } - else - { - // Convert uids from string to numeric format - const TDesC8& pluginUidValue = pluginUidAttr->Value(); - const TUid uid = hspsServerUtil::ConvertDescIntoUid(pluginUidValue); - if ( uid.iUid > 0 ) - { - pluginUid = uid.iUid; - // Override default status - err = KErrNone; - } - } - - // Store activity state for use after deletion. - TBool pluginWasActive = EFalse; - ChspsDomAttribute* pluginActivityAttr = - static_cast( attrList.FindByName( KPluginAttrActive ) ); - if( pluginActivityAttr ) - { - if( pluginActivityAttr->Value().CompareF( KPluginActiveStateActive ) == 0 ) - { - pluginWasActive = ETrue; - } - } - + // Remove plugin resources from the application configuration: + // By default remove all plugin's resources from all instances + // - otherwise, after upgrades, there might be various versions of the same resources + err = RemovePluginResourcesL( aAppODT, pluginUid ); if ( !err ) { - // Get number of plugin instances with the plugin uid - TInt instanceCount = 0; - GetPluginInstanceCountL( - aAppODT, - pluginUid, - instanceCount ); - - // Remove plugin resources form the application configuration: - // By default remove all plugin's resources from all instances - // - otherwise, after upgrades, there might be various versions of the same resources - err = RemovePluginResourcesL( aAppODT, pluginUid ); - if ( !err ) + // If the application configuration holds other instances of the same plugin + if ( instanceCount > 1 ) { - // If the application configuration holds other instances of the same plugin - if ( instanceCount > 1 ) - { - // Put back the resources - AddPluginResourcesL( - aAppODT, - pluginUid ); - } - - // Remove the plugin node from parent node - parentNode->DeleteChild( node ); - } - } + // Put back the resources + AddPluginResourcesL( + aAppODT, + pluginUid ); + } + + // Remove the plugin node from the plugins node + parentNode->DeleteChild( &aPluginNode ); + } + } - // If plugin was succesfully deleted and was active -> - // need set another plugin active. - // ( Choose to activate topmost item. ) - // ( Use depth of 1 to affect only one level. ) - if ( !err && pluginWasActive ) - { - const TInt KDepth = 1; - hspsServerUtil::EditPluginNodeActivityL( parentNode, - hspsServerUtil::EActivateFirst, - KDepth ); - } - } - } + // If plugin was succesfully deleted and was active -> + // need set another plugin active. + // ( Choose to activate topmost item. ) + // ( Use depth of 1 to affect only one level. ) + if ( !err && pluginWasActive ) + { + const TInt KDepth = 1; + hspsServerUtil::EditPluginNodeActivityL( parentNode, + hspsServerUtil::EActivateFirst, + KDepth ); + } + } return err; } @@ -4603,4 +4680,335 @@ } +// ----------------------------------------------------------------------------- +// ChspsMaintenanceHandler::ServiceRestoreConfigurationsL +// ----------------------------------------------------------------------------- +// +void ChspsMaintenanceHandler::ServiceRestoreConfigurationsL( const RMessage2& aMessage ) + { + ThspsServiceCompletedMessage ret = EhspsRestoreConfigurationsFailed; + + // using message pointer as a local variable because of synch call + RMessagePtr2 messagePtr = aMessage; + + // IPC slots: + // #0) output: externalized ChspsResult for error handling + // #1) input: ThspsParamRestoreConfigurations struct + ThspsParamRestoreConfigurations params; + TPckg packagedStruct(params); + aMessage.ReadL(1, packagedStruct); + if ( params.appUid < 1 ) + { + User::Leave( KErrArgument ); + } + // Enable modification of owned configurations only + if( messagePtr.SecureId().iId != params.appUid ) + { + User::Leave( KErrAccessDenied ); + } + + TInt err = KErrNone; + if( iDefinitionRepository.Locked() ) + { + // Repository locked + err = KErrAccessDenied; + } + + if( !err ) + { + // Lock the Plugin Repository (a.k.a. Def.rep) + iDefinitionRepository.Lock(); + CleanupStack::PushL( TCleanupItem( UnlockRepository, &iDefinitionRepository ) ); + + // Get active root configuration for the client application + ChspsODT* appODT = ChspsODT::NewL(); + CleanupStack::PushL( appODT ); + iThemeServer.GetActivateAppConfigurationL( + params.appUid, + *appODT ); + +#ifdef HSPS_LOG_ACTIVE + if( iLogBus ) + { + iLogBus->LogText( + _L( "ChspsMaintenanceHandler::ServiceRestoreConfigurationsL(): - Dump before the changes:" ) + ); + ChspsOdtDump::Dump( *appODT, *iLogBus ); + } +#endif + + TInt err = KErrNone; + if ( !params.restoreAll ) + { + // Remove all widgets from the active view + err = RestoreActiveViewL( *appODT ); + } + + // As a backup, if restoration of the active view fails, + // or if all views but the locked view should be removed + if ( err || params.restoreAll ) + { + // Remove all views but the locked one and reset active view + RemoveUnlockedViewsL( *appODT ); + + // Remove all widgets from the active view + err = RestoreActiveViewL( *appODT ); + } + +#ifdef HSPS_LOG_ACTIVE + if( iLogBus ) + { + iLogBus->LogText( + _L( "ChspsMaintenanceHandler::ServiceRestoreConfigurationsL(): - Dump after the changes:" ) + ); + ChspsOdtDump::Dump( *appODT, *iLogBus ); + } +#endif + if( !err ) + { + // Stores the new application configuration into the repository + err = iDefinitionRepository.SetOdtL( *appODT ); + ret = EhspsRestoreConfigurationsSuccess; + } + + CleanupStack::PopAndDestroy( appODT ); + + // Unlock after the changes have been done + iDefinitionRepository.Unlock(); + CleanupStack::Pop(&iDefinitionRepository); + } + + // Error handling + iResult->iXuikonError = err; + + // complete the message + CompleteRequest( ret, messagePtr ); + } + +// ----------------------------------------------------------------------------- +// ChspsMaintenanceHandler::RestoreActiveViewL +// ----------------------------------------------------------------------------- +// +TInt ChspsMaintenanceHandler::RestoreActiveViewL( + ChspsODT& aAppODT ) + { + TInt err = KErrCorrupt; + + // Find active view node + ChspsDomNode* pluginNode = FindActiveView( aAppODT ); + if ( pluginNode ) + { + // Remove all plugins from the view configuration + err = RemovePluginConfigurationsL( + aAppODT, + *pluginNode ); + } + return err; + } + +// ----------------------------------------------------------------------------- +// ChspsMaintenanceHandler::FindActiveView +// ----------------------------------------------------------------------------- +// +ChspsDomNode* ChspsMaintenanceHandler::FindActiveView( + ChspsODT& aAppODT ) + { + ChspsDomNode* pluginNode = NULL; + + // Get 1st configuration element + ChspsDomNode* confNode = aAppODT.DomDocument().RootNode(); + if( confNode && confNode->Name().CompareF( KConfigurationElement ) == 0 ) + { + // Get control element + ChspsDomNode* controlNode = + (ChspsDomNode*)confNode->ChildNodes().FindByName( KControlElement ); + if( controlNode ) + { + // Get plugins element + ChspsDomNode* pluginsNode = + (ChspsDomNode*)controlNode->ChildNodes().FindByName( KPluginsElement ); + if( pluginsNode ) + { + // Find active plugin node under the plugins node + pluginNode = hspsServerUtil::GetActivePluginNode( pluginsNode ); + } + } + } + return pluginNode; + } + +// ----------------------------------------------------------------------------- +// ChspsMaintenanceHandler::RemovePluginConfigurationsL +// ----------------------------------------------------------------------------- +// +TInt ChspsMaintenanceHandler::RemovePluginConfigurationsL( + ChspsODT& aAppODT, + ChspsDomNode& aActivePluginNode ) + { + TInt err = KErrCorrupt; + + // Find a configuration node + ChspsDomNode* confNode = + (ChspsDomNode*)aActivePluginNode.ChildNodes().FindByName( KConfigurationElement ); + if( confNode ) + { + // Get control node + ChspsDomNode* controlNode = + (ChspsDomNode*)confNode->ChildNodes().FindByName( KControlElement ); + if( controlNode ) + { + // Find a plugins node + ChspsDomNode* pluginsNode = + (ChspsDomNode*)controlNode->ChildNodes().FindByName( KPluginsElement ); + if( pluginsNode ) + { + // Loop plugin nodes + err = KErrNone; + ChspsDomList& childNodes = pluginsNode->ChildNodes(); + for( TInt pluginIndex=childNodes.Length()-1; pluginIndex >= 0; pluginIndex-- ) + { + ChspsDomNode* pluginNode = (ChspsDomNode*)childNodes.Item( pluginIndex ); + if( pluginNode ) + { + // Remove the plugin configuration instance + err = RemoveConfigurationL( + aAppODT, + *pluginNode ); + if( err ) + { + break; + } + } + } + } + } + } + + return err; + } + +// ----------------------------------------------------------------------------- +// ChspsMaintenanceHandler::IsConfigurationLocked +// ----------------------------------------------------------------------------- +// +TBool ChspsMaintenanceHandler::IsConfigurationLocked( + ChspsDomNode& aConfNode ) + { + TBool isLocked = EFalse; + + ChspsDomList& attrList = aConfNode.AttributeList(); + ChspsDomAttribute* attr = + static_cast( attrList.FindByName( KConfigurationAttrLocking ) ); + if( attr ) + { + isLocked = ( attr->Value().CompareF( KConfLockingLocked ) == 0 ); + } + + return isLocked; + } + +// ----------------------------------------------------------------------------- +// ChspsMaintenanceHandler::RemoveUnlockedViewsL +// ----------------------------------------------------------------------------- +// +void ChspsMaintenanceHandler::RemoveUnlockedViewsL( + ChspsODT& aAppODT ) + { + // Get 1st configuration element + ChspsDomNode* confNode = aAppODT.DomDocument().RootNode(); + if( !confNode || confNode->Name().CompareF( KConfigurationElement) != 0 ) + { + User::Leave( KErrCorrupt ); + } + + ChspsDomNode* controlNode = + (ChspsDomNode*)confNode->ChildNodes().FindByName( KControlElement ); + if( !controlNode ) + { + User::Leave( KErrCorrupt ); + } + + // Get plugins element + ChspsDomNode* pluginsNode = + (ChspsDomNode*)controlNode->ChildNodes().FindByName( KPluginsElement ); + if( !pluginsNode ) + { + User::Leave( KErrCorrupt ); + } + + // Find plugin nodes which should be removed + const TInt pluginCount = pluginsNode->ChildNodes().Length(); + if( pluginCount > 1 ) + { + // Array for nodes which should removed from the configuration + // (don't touch the appended objects) + RPointerArray nodeArray; + CleanupClosePushL( nodeArray ); + + // Remove all but one view + TBool foundLocked = EFalse; + for( TInt nodeIndex=0; nodeIndex < pluginCount; nodeIndex++ ) + { + ChspsDomNode* pluginNode = + (ChspsDomNode*)pluginsNode->ChildNodes().Item( nodeIndex ); + if( pluginNode ) + { + + ChspsDomNode* confNode = + (ChspsDomNode*)pluginNode->ChildNodes().FindByName( KConfigurationElement ); + if( confNode ) + { + TBool isLocked = IsConfigurationLocked( *confNode ); + + // If the plugin configuration hasn't been locked or + // if there are several locked plugin nodes then remove all the rest + if( !isLocked || foundLocked ) + { + // Mark for removal + nodeArray.Append( pluginNode ); + } + else + { + // If this is the 1st locked node + if( !foundLocked ) + { + foundLocked = ETrue; + } + } + } + } + } + + // If all the nodes were marked for removal + if( nodeArray.Count() > 0 && nodeArray.Count() == pluginCount ) + { + // Unmark the 1st node - remove from the array only + nodeArray.Remove( 0 ); + } + + // Remove rest + TInt err = KErrNone; + for( TInt nodeIndex=0; nodeIndex < nodeArray.Count(); nodeIndex++ ) + { + // Remove the plugin node, related resources and maintain activity information + err = RemoveConfigurationL( + aAppODT, + *nodeArray[nodeIndex] ); + if( err ) + { +#ifdef HSPS_LOG_ACTIVE + if( iLogBus ) + { + iLogBus->LogText( _L( "ChspsMaintenanceHandler::RemoveUnlockedViewsL(): - Restoring failed with %d code" ), err ); + } +#endif + } + + } + + nodeArray.Reset(); + CleanupStack::PopAndDestroy( 1, &nodeArray ); + } + } + // end of file diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/hspsmanager/src/hspssecurityenforcer.cpp --- a/homescreenpluginsrv/hspsmanager/src/hspssecurityenforcer.cpp Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/hspsmanager/src/hspssecurityenforcer.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -309,6 +309,7 @@ case EhspsSetConfState: case EhspsRestoreActiveAppConf: case EhspsUpdatePluginConf: + case EhspsRestoreConfigurations: { if( CheckAccessControlListL( secure_id ) ) { diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/hspsmanager/src/hspsthemeserversession.cpp --- a/homescreenpluginsrv/hspsmanager/src/hspsthemeserversession.cpp Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/hspsmanager/src/hspsthemeserversession.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -359,6 +359,14 @@ RestoreActiveAppConfL( aMessage ); break; } + case EhspsRestoreConfigurations: + { +#ifdef HSPS_LOG_ACTIVE + iLogBus->LogText( _L( "DoServiceL: EhspsRestoreConfigurations" ) ); +#endif + RestoreConfigurationsL( aMessage ); + break; + } default: { #ifdef HSPS_LOG_ACTIVE @@ -698,6 +706,15 @@ } // ----------------------------------------------------------------------------- +// ChspsThemeServerSession::RestoreConfigurationsL +// ----------------------------------------------------------------------------- +void ChspsThemeServerSession::RestoreConfigurationsL( const RMessage2& aMessage ) + { + CreateMaintenanceHandlerL( aMessage.SecureId().iId ); + iMaintenanceHandler->ServiceRestoreConfigurationsL( aMessage ); + } + +// ----------------------------------------------------------------------------- // ChspsThemeServerSession::CancelGetOdtUpdate // (other items were commented in a header). // ----------------------------------------------------------------------------- diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/inc/hspsclient.h --- a/homescreenpluginsrv/inc/hspsclient.h Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/inc/hspsclient.h Tue Feb 02 00:23:10 2010 +0200 @@ -439,6 +439,22 @@ const TInt aPluginId, const TInt aConfUid ); + /** + * Restores plugin configurations by either removing all plugins + * from the active view or by removing all extra views. + * In latter case, the first locked view is emptied. If there are + * no locked views then the first view will remain while others + * are removed. + * @since S60 5.2 + * @param aAppUid Application uid + * @param aReinstall False if only the active view should be fixed, + * True if also all extra views should removed + * @return ThspsServiceCompletedMessage expressing the result of the call. + */ + IMPORT_C ThspsServiceCompletedMessage hspsRestoreConfigurations( + const TInt aAppUid, + const TBool aReinstall ); + protected: // Functions from base classes /** diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/inc/hspsclientsession.h --- a/homescreenpluginsrv/inc/hspsclientsession.h Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/inc/hspsclientsession.h Tue Feb 02 00:23:10 2010 +0200 @@ -349,6 +349,21 @@ TDes8& aResultData, const ThspsParamReplacePlugin& aParams ); + /** + * Restores plugin configurations by either removing all plugins + * from the active view or by removing all extra views. + * In latter case, the first locked view is emptied. If there are + * no locked views then the first view will remain while others + * are removed. + * @since S60 5.2 + * @param aResultData Result data. + * @param aParams Params. + * @return Symbian error code. + */ + IMPORT_C TInt RestoreConfigurations( + TDes8& aResultData, + const ThspsParamRestoreConfigurations& aParams ); + public: friend class ChspsClient; diff -r ff572005ac23 -r 1a2a00e78665 homescreenpluginsrv/inc/hspsthememanagement.h --- a/homescreenpluginsrv/inc/hspsthememanagement.h Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreenpluginsrv/inc/hspsthememanagement.h Tue Feb 02 00:23:10 2010 +0200 @@ -392,6 +392,12 @@ EhspsUpdatePluginConf, + /** + * Restores plugin configurations by either removing all plugins + * from the active view or by reinstalling all the ROM based plugins. + */ + EhspsRestoreConfigurations, + /************************************** * Client Request related requests: @@ -616,6 +622,17 @@ */ EhspsGetPluginOdtFailed, + /** + * EhspsRestoreConfigurationsSuccess. Restoration was successfull. + */ + EhspsRestoreConfigurationsSuccess, + + /** + * EhspsRestoreConfigurationsFailed. Restoration failed. + */ + EhspsRestoreConfigurationsFailed, + + /* Client Requests: */ /** @@ -1011,6 +1028,18 @@ TBool storingStatus; // storing status telling if modified plugin settings are needed to stored its reference. }; +/** + * Input parameter for the RestoreActiveAppConf service + */ +struct ThspsParamRestoreConfigurations + { + TInt appUid; // uid of the application + TBool restoreAll; // false: if all widget plugins should be removed from the active view, + // true: if all widget plugins should be removed from the first locked view + // (or if locked views were not found then from first unlocked view) + // and if all other views should be removed + }; + class ChspsODT; class ChspsResource; diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/group/build_testcases.cmd --- a/homescreensrv_plat/sapi_homescreenplugin/group/build_testcases.cmd Tue Jan 26 12:11:15 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,29 +0,0 @@ -rem -rem Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). -rem All rights reserved. -rem This component and the accompanying materials are made available -rem under the terms of "Eclipse Public License v1.0" -rem which accompanies this distribution, and is available -rem at the URL "http://www.eclipse.org/legal/epl-v10.html". -rem -rem Initial Contributors: -rem Nokia Corporation - initial contribution. -rem -rem Contributors: -rem -rem Description: -rem - -@echo off -rem ************************************ -rem ** Executed from build_testcases.mk -rem ************************************ - -echo Building the test cases... - -cd ..\internal\moduletest\group -call bldmake clean -call bldmake bldfiles -call abld reallyclean -call abld build winscw udeb - diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/group/build_testcases.mk --- a/homescreensrv_plat/sapi_homescreenplugin/group/build_testcases.mk Tue Jan 26 12:11:15 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,22 +0,0 @@ -# -# Copyright (c) 2007 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" -# 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: Builds internal test cases if EUnit has been installed -# - -MAKMAKE BLD CLEAN LIB CLEANLIB RESOURCE FREEZE SAVESPACE RELEASABLES : ; - -FINAL : -ifeq (WINSCW,$(findstring WINSCW, $(PLATFORM))) - if exist %epocroot%epoc32\release\winscw\udeb\EUnit.dll call build_testcases.cmd -endif diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/hspsservice/bwins/hspsserviceu.def --- a/homescreensrv_plat/sapi_homescreenplugin/hspsservice/bwins/hspsserviceu.def Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreensrv_plat/sapi_homescreenplugin/hspsservice/bwins/hspsserviceu.def Tue Feb 02 00:23:10 2010 +0200 @@ -21,4 +21,5 @@ ?GetPluginOdtL@CHspsPersonalisationService@@QAEXHAAVTDesC8@@PAVChspsODT@@@Z @ 20 NONAME ; void CHspsPersonalisationService::GetPluginOdtL(int, class TDesC8 &, class ChspsODT *) ?SetActivePluginL@CHspsPersonalisationService@@QAEXHAAVTDesC8@@@Z @ 21 NONAME ; void CHspsPersonalisationService::SetActivePluginL(int, class TDesC8 &) ?UnRegisterObserverL@CHspsConfigurationService@@QAEXXZ @ 22 NONAME ; void CHspsConfigurationService::UnRegisterObserverL(void) + ?RestoreConfigurationsL@CHspsPersonalisationService@@QAEXHH@Z @ 23 NONAME ; void CHspsPersonalisationService::RestoreConfigurationsL(int, int) diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/hspsservice/eabi/hspsserviceu.def --- a/homescreensrv_plat/sapi_homescreenplugin/hspsservice/eabi/hspsserviceu.def Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreensrv_plat/sapi_homescreenplugin/hspsservice/eabi/hspsserviceu.def Tue Feb 02 00:23:10 2010 +0200 @@ -25,4 +25,5 @@ _ZTI27CHspsPersonalisationService @ 24 NONAME _ZTV25CHspsConfigurationService @ 25 NONAME _ZTV27CHspsPersonalisationService @ 26 NONAME + _ZN27CHspsPersonalisationService22RestoreConfigurationsLEii @ 27 NONAME diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/hspsservice/inc/hspspersonalisationservice.h --- a/homescreensrv_plat/sapi_homescreenplugin/hspsservice/inc/hspspersonalisationservice.h Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreensrv_plat/sapi_homescreenplugin/hspsservice/inc/hspspersonalisationservice.h Tue Feb 02 00:23:10 2010 +0200 @@ -230,6 +230,7 @@ /** * Replaces a plugin in active application configuration + * @since S60 5.1 * @param aAppUid - application uid * @param aPluginId - id of the plugin to be replaced * @param aConfUid - uid of the new plugin configuration @@ -238,6 +239,21 @@ const TInt aAppUid, const TDesC8& aPluginId, const TDesC8& aConfUid ); + + /** + * Restores plugin configurations by either removing all plugins + * from the active view or by removing all extra views. + * In latter case, the first locked view is emptied. If there are + * no locked views then the first view will remain while others + * are removed. + * @since S60 5.2 + * @param aAppUid Application uid + * @param aResetAllViews False if only the active view should be fixed, + * True if also all extra views should removed + */ + IMPORT_C void RestoreConfigurationsL( + const TInt aAppUid, + const TBool aResetAllViews ); private: // Methods diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/hspsservice/src/hspspersonalisationservice.cpp --- a/homescreensrv_plat/sapi_homescreenplugin/hspsservice/src/hspspersonalisationservice.cpp Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreensrv_plat/sapi_homescreenplugin/hspsservice/src/hspspersonalisationservice.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -424,6 +424,35 @@ } } +// ----------------------------------------------------------------------------- +// Repaces a plugin in active application configuration +// ----------------------------------------------------------------------------- +EXPORT_C void CHspsPersonalisationService::RestoreConfigurationsL( + const TInt aAppUid, + const TBool aResetAllViews ) + { + ThspsServiceCompletedMessage ret = + iHspsClient->hspsRestoreConfigurations( aAppUid, aResetAllViews ); + if( ret != EhspsRestoreConfigurationsSuccess ) + { + // Get error code from the server process + ChspsResult* errorDetails = ChspsResult::NewL(); + CleanupStack::PushL( errorDetails ); + iHspsClient->GethspsResult( *errorDetails ); + + // Check if disk full error case. + if( errorDetails->iXuikonError == KErrDiskFull ) + { + User::Leave( KErrDiskFull ); + } + + CleanupStack::PopAndDestroy( errorDetails ); + + // Other error cases. + User::Leave( KErrGeneral ); + } + } + // --------------------------------------------------------------------------- // Hsps client service observer diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/inc/hspsconfigurationif.h --- a/homescreensrv_plat/sapi_homescreenplugin/inc/hspsconfigurationif.h Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreensrv_plat/sapi_homescreenplugin/inc/hspsconfigurationif.h Tue Feb 02 00:23:10 2010 +0200 @@ -254,6 +254,17 @@ CLiwGenericParamList& aOutParamList ); /** + * Restores plugin configurations. + * Either removes all plugins from the active view or + * reinstalls all ROM based configurations. + * @param aInParamList Input param list + * @param aOutParamList Output param list + */ + void RestoreConfigurationsL( + const CLiwGenericParamList& aInParamList, + CLiwGenericParamList& aOutParamList ); + + /** * Sets an error value to output parameter. * @param aOutParamList Output param list * @param aErr an error diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/inc/hspsliwutilities.h --- a/homescreensrv_plat/sapi_homescreenplugin/inc/hspsliwutilities.h Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreensrv_plat/sapi_homescreenplugin/inc/hspsliwutilities.h Tue Feb 02 00:23:10 2010 +0200 @@ -243,6 +243,13 @@ */ static void SetActivePluginOutputL( CLiwGenericParamList& aOutParamList ); + + /** + * Creates RestoreConfigurations method output parameter list + * @param aOutParamList Output parameters + */ + static void RestoreConfigurationsOutputL( + CLiwGenericParamList& aOutParamList ); private: diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/inc/hspsliwvocabulary.hrh --- a/homescreensrv_plat/sapi_homescreenplugin/inc/hspsliwvocabulary.hrh Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreensrv_plat/sapi_homescreenplugin/inc/hspsliwvocabulary.hrh Tue Feb 02 00:23:10 2010 +0200 @@ -56,6 +56,7 @@ _LIT8( KRequestNotification, "RequestNotification" ); _LIT8( KSetConfState, "SetConfState" ); _LIT8( KSetActivePlugin, "SetActivePlugin" ); +_LIT8( KRestoreConfigurations, "RestoreConfigurations" ); //Input words. _LIT8( KPluginId, "pluginId" ); @@ -70,6 +71,10 @@ _LIT8( KHspsLiwStoringParams, "storingParams" ); //optional _LIT8( KHspsLiwStorePluginRefence, "storePluginConf" ); _LIT8( KHspsLiwStoreAppConf, "storeAppConf" ); +_LIT8( KHspsLiwRestore, "restore" ); +_LIT8( KHspsLiwRestoreActive, "active"); +_LIT8( KHspsLiwRestoreAll, "all"); + //Output words. _LIT8( KHspsLiwPluginId, "pluginId" ); _LIT8( KHspsLiwPluginIds, "pluginIds" ); diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/src/hspsconfigurationif.cpp --- a/homescreensrv_plat/sapi_homescreenplugin/src/hspsconfigurationif.cpp Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreensrv_plat/sapi_homescreenplugin/src/hspsconfigurationif.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -243,6 +243,10 @@ { TRAP( err, SetActivePluginL( aInParamList, aOutParamList ) ); } + else if ( aCmdName.CompareF( KRestoreConfigurations ) == 0 ) + { + TRAP( err, RestoreConfigurationsL( aInParamList, aOutParamList ) ); + } //UNKNOWN COMMAND else { @@ -1159,6 +1163,54 @@ } + +// ----------------------------------------------------------------------------- +// Restores plugin configurations when the client has panicked +// ----------------------------------------------------------------------------- +// +void CHSPSConfigurationIf::RestoreConfigurationsL( + const CLiwGenericParamList& aInParamList, + CLiwGenericParamList& aOutParamList ) + { + // Get restore parameter + const TLiwGenericParam* inParam; + TInt pos = 0; + + inParam = aInParamList.FindFirst( + pos, + KHspsLiwRestore ); + if ( !inParam ) + { + // Manadatory parameter missing + User::Leave( KErrArgument ); + } + + TLiwVariant inParamVariant = inParam->Value(); + TPtrC8 restore( inParamVariant.AsData() ); + + TBool restoreAll = EFalse; + if( restore.CompareF( KHspsLiwRestoreAll ) == 0 ) + { + restoreAll = ETrue; + } + else if( restore.CompareF( KHspsLiwRestoreActive ) != 0 ) + { + User::Leave( KErrArgument ); + } + + // Get client application's uid + TInt appUid; + iHspsConfigurationService->GetAppUidL( appUid ); + + iHspsPersonalisationService->RestoreConfigurationsL( appUid, restoreAll ); + + // Invalidate ODT. + iHspsConfigurationService->InvalidateODT(); + + // Create output parameters + CHspsLiwUtilities::RestoreConfigurationsOutputL( aOutParamList ); + } + // ======== GLOBAL FUNCTIONS =================================================== diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/src/hspsliwutilities.cpp --- a/homescreensrv_plat/sapi_homescreenplugin/src/hspsliwutilities.cpp Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreensrv_plat/sapi_homescreenplugin/src/hspsliwutilities.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -1546,3 +1546,13 @@ AppendStatusL( KErrNone, aOutParamList ); } + +// ----------------------------------------------------------------------------- +// Creates output parmater list for RestoreConfigurations method +// ----------------------------------------------------------------------------- +void CHspsLiwUtilities::RestoreConfigurationsOutputL( + CLiwGenericParamList& aOutParamList ) + { + AppendStatusL( KErrNone, aOutParamList ); + } + diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/tsrc/hspsconfigurationif/inc/mt_hsps_restoreconfigurations_1.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/homescreensrv_plat/sapi_homescreenplugin/tsrc/hspsconfigurationif/inc/mt_hsps_restoreconfigurations_1.h Tue Feb 02 00:23:10 2010 +0200 @@ -0,0 +1,2864 @@ +/* +* Copyright (c) 2008 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" +* 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: Test case RestoreConfigurations(1) test data +* +*/ + + +#ifndef C_MT_HSPS_RESTORECONFIGURATIONS_1_H +#define C_MT_HSPS_RESTORECONFIGURATIONS_1_H + +/* +RestoreConfigurations(1) +---------------- + +Test purpose + +Verify that HSPS removes all plugin configurations from the active view +or that all but one view are removed from the application configuration. +Activity should be maintained. First locked view should remain or if not found, +first unlocked view. + +Pre-conditions +• There must be installed test themes for Active Idle application and Typical + configuration must be set as active + +Test steps + +Test step 1: +• Input: + RestoreConfigurations(“active”) +• Expected output: + Restoring succeeded + +Test step 2: +• Input: + GetActiveAppConf +• Expected output: + There are still two views of which the first view remains active + +Test step 3: +• Input: + GetPluginConf(“Typical - View1”) +• Expected output: + There are no plugins (widgets) in the first view + + +Test step 4: +• Input: + RestoreConfigurations(“all”) +• Expected output: + Restoring succeeded + +Test step 5: +• Input: + GetActiveAppConf +• Expected output: + There is now only one view, which was the first view previously, and it's active + +Test step 6: +• Input: + GetPluginConf(“Typical - View1”) +• Expected output: + There are no plugins (widgets) in the remaining view + +*/ + +// Test step 1 method: +const TUint8 restoreconfigurations_1_ts_1_method[] = "RestoreConfigurations"; + +// Test step 1 input: +const TUint8 restoreconfigurations_1_ts_1_input[] = { +// RestoreConfigurations(Input) +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// - RestoreConfigurations(Input)::restore +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +7,0,0,0, +30, +'r','e','s','t','o','r','e', +// - RestoreConfigurations::value +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +6,0,0,0, +26, +'a','c','t','i','v','e' +}; + +// Test step 1 output: +const TUint8 restoreconfigurations_1_ts_1_output[] = { +// RestoreConfigurations(Output) +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// - RestoreConfigurations(Output)::status +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +6,0,0,0, +26, +'s','t','a','t','u','s', +// - AddPlugin(Input)::status +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeTInt32 +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +1, +0,0,0,0 +}; + + + +// Test step 2 method: +const TUint8 restoreconfigurations_1_ts_2_method[] = "GetActiveAppConf"; + + +// Test step 2 input: +const TUint8 restoreconfigurations_1_ts_2_input = 0; + + +// Test step 2 expected output: +const TUint8 restoreconfigurations_1_ts_2_output[] = { +// GetActiveAppConf(Output) +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// GetActiveAppConf(Output)::appConf +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +7,0,0,0, +30, +'a','p','p','C','o','n','f', +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - appConf map +// - Version 1.0 +// - Item count (LE) +10, +12,0,0,0, +// - appConf::id +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +2,0,0,0, +10, +'i','d', +// - appConf::id +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'1', +// - appConf::uid +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +3,0,0,0, +14, +'u','i','d', +// - appConf::uid +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +10,0,0,0, +42, +'0','x','2','0','0','0','B','1','1','0', +// - appConf::type +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'t','y','p','e', +// - appConf::type +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +11,0,0,0, +46, +'a','p','p','l','i','c','a','t','i','o','n', +// - appConf::interface +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'i','n','t','e','r','f','a','c','e', +// - appConf::interface +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +10,0,0,0, +42, +'0','x','2','0','0','0','0','F','B','1', +// - appConf::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - appConf::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +14,0,0,0, +58, +'T','y','p','i','c','a','l',' ','-',' ','R','o','o','t', +// - appConf::multiinstance +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +13,0,0,0, +54, +'m','u','l','t','i','i','n','s','t','a','n','c','e', +// - appConf::multiinstance +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'1', +// - appConf::description +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'d','e','s','c', +// - appConf::description +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +0,0,0,0, +2, +// - appConf::state +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +5,0,0,0, +22, +'s','t','a','t','e', +// - appConf::state +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +12,0,0,0, +50, +'N','o','t','C','o','n','f','i','r','m','e','d', +// - appConf::max_child +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'m','a','x','_','c','h','i','l','d', +// - appConf::max_child +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'6', +// - appConf::plugins +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +7,0,0,0, +30, +'p','l','u','g','i','n','s', +// - appConf::plugins +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - appConf::plugins +// - Version 1.0 +// - Item count (LE) +10, +2,0,0,0, +// - appConf::plugins +// - Version 1.0 +// - List item starts +10, +0,0,0,0, +// - appConf::plugins[0] +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - plugins[0] map +// - Version 1.0 +// - Item count (LE) +10, +4,0,0,0, +// - plugins[0]::id +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +2,0,0,0, +10, +'i','d', +// - plugins[0]::id +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'1', +// - plugins[0]::uid +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +3,0,0,0, +14, +'u','i','d', +// - plugins[0]::uid +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +10,0,0,0, +42, +'0','x','2','0','0','0','B','1','1','1', +// - plugins[0]::activationstate +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +15,0,0,0, +62, +'a','c','t','i','v','a','t','i','o','n','s','t','a','t','e', +// - plugins[0]::activationstate +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'1', +// - plugins[0]::locking_status +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +14,0,0,0, +58, +'l','o','c','k','i','n','g','_','s','t','a','t','u','s', +// - plugins[0]::locking_status +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +4,0,0,0, +18, +'n','o','n','e', +// - appConf::plugins +// - Version 1.0 +// - List item starts +10, +0,0,0,0, +// - appConf::plugins[1] +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - plugins[1] map +// - Version 1.0 +// - Item count (LE) +10, +4,0,0,0, +// - plugins[1]::id +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +2,0,0,0, +10, +'i','d', +// - plugins[1]::id +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'5', +// - plugins[1]::uid +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +3,0,0,0, +14, +'u','i','d', +// - plugins[1]::uid +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +10,0,0,0, +42, +'0','x','2','0','0','0','B','1','1','2', +// - plugins[1]::activationstate +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +15,0,0,0, +62, +'a','c','t','i','v','a','t','i','o','n','s','t','a','t','e', +// - plugins[1]::activationstate +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'0', +// - plugins[1]::locking_status +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +14,0,0,0, +58, +'l','o','c','k','i','n','g','_','s','t','a','t','u','s', +// - plugins[1]::locking_status +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +4,0,0,0, +18, +'n','o','n','e', +// - appConf::settings +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +8,0,0,0, +34, +'s','e','t','t','i','n','g','s', +// - appConf::settings +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - appConf::settings +// - Version 1.0 +// - Item count (LE) +10, +0,0,0,0, +// - appConf::resources +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'r','e','s','o','u','r','c','e','s', +// - appConf::resources +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - appConf::resources +// - Version 1.0 +// - List item count +10, +1,0,0,0, +// - resources[0]::object +// - Version 1.0 +// - List item starts +10, +0,0,0,0, +// - Object[0] +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - Object[0] map +// - Version 1.0 +// - Item count (LE) +10, +4,0,0,0, +// - Object[0]::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - Object[0]::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +8,0,0,0, +34, +'r','o','o','t','.','b','m','p', +// - Object[0]::path +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'p','a','t','h', +// - Object[0]::path +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +42,0,0,0, +170, +'5','3','6','8','7','4','9','2','9','\\','2','7','0','5','1','3','7','5','1','\\','5','3','6','9','1','6','2','4','0','\\','1','.','0','\\','s','o','u','r','c','e','s','\\', +// - Object[0]::mediatype +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'m','e','d','i','a','t','y','p','e', +// - Object[0]::mediatype +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +9,0,0,0, +38, +'m','i','m','e','_','t','y','p','e', +// - Object[0]::tag +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +3,0,0,0, +14, +'t','a','g', +// - Object[0]::tag +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +0,0,0,0, +2 +}; + + + + +// Test step 3 method: +const TUint8 restoreconfigurations_1_ts_3_method[] = "GetPluginConf"; + +// Test step 3 input: +const TUint8 restoreconfigurations_1_ts_3_input[] = { +// GetPluginConf(Input) +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// - GetPluginConf(Input)::pluginId +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +8,0,0,0, +34, +'p','l','u','g','i','n','I','d', +// - GetPluginConf(Input)::pluginId +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'1' +}; + +// Test step 3 output: +const TUint8 restoreconfigurations_1_ts_3_output[] = { +// GetPluginConf(Output) +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// GetPluginConf(Output)::pluginConf +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +10,0,0,0, +42, +'p','l','u','g','i','n','C','o','n','f', +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - pluginConf map +// - Version 1.0 +// - Item count (LE) +10, +12,0,0,0, +// - pluginConf::id +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +2,0,0,0, +10, +'i','d', +// - pluginConf::id +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'2', +// - pluginConf::uid +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +3,0,0,0, +14, +'u','i','d', +// - pluginConf::uid +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +10,0,0,0, +42, +'0','x','2','0','0','0','B','1','1','1', +// - pluginConf::type +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'t','y','p','e', +// - pluginConf::type +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +4,0,0,0, +18, +'v','i','e','w', +// - pluginConf::interface +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'i','n','t','e','r','f','a','c','e', +// - pluginConf::interface +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +5,0,0,0, +22, +'0','x','9','9','8', +// - pluginConf::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - pluginConf::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +15,0,0,0, +62, +'T','y','p','i','c','a','l',' ','-',' ','V','i','e','w','1', +// - pluginConf::multiinstance +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +13,0,0,0, +54, +'m','u','l','t','i','i','n','s','t','a','n','c','e', +// - pluginConf::multiinstance +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'1', +// - pluginConf::description +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'d','e','s','c', +// - pluginConf::description +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +0,0,0,0, +2, +// - pluginConf::state +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +5,0,0,0, +22, +'s','t','a','t','e', +// - pluginConf::state +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +12,0,0,0, +50, +'N','o','t','C','o','n','f','i','r','m','e','d', +// - pluginConf::max_child +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'m','a','x','_','c','h','i','l','d', +// - pluginConf::max_child +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'6', +// - pluginConf::plugins +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +7,0,0,0, +30, +'p','l','u','g','i','n','s', +// - pluginConf::plugins +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - pluginConf::plugins +// - Version 1.0 +// - Item count (LE) +10, +0,0,0,0, +// - pluginConf::settings +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +8,0,0,0, +34, +'s','e','t','t','i','n','g','s', +// - pluginConf::settings +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - pluginConf::settings +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// - pluginConf::settings +// - Version 1.0 +// - List item starts +10, +0,0,0,0, + +// - items[0] +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - items[0] map +// - Version 1.0 +// - Item count (LE) +10, +3,0,0,0, +// - items[0]::itemId +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +6,0,0,0, +26, +'i','t','e','m','I','d', +// - items[0]::itemId +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value (empty) +10, +5, +7,0,0,0, +30, +'b','g','c','o','l','o','r', +// - items[0]::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - items[0]::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value (empty) +10, +5, +16,0,0,0, +66, +'B','a','c','k','g','r','o','u','n','d',' ','c','o','l','o','r', +// - items[0]::properties +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +10,0,0,0, +42, +'p','r','o','p','e','r','t','i','e','s', +// - items[0]::properties +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - items[0]::properties +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// - items[0]::properties +// - Version 1.0 +// - List item starts +10, +0,0,0,0, +// - properties[0] +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - properties[0] map +// - Version 1.0 +// - Item count (LE) +10, +2,0,0,0, +// - prperties[0]::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - properties[0]::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +5,0,0,0, +22, +'v','a','l','u','e', +// - prperties[0]::value +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +5,0,0,0, +22, +'v','a','l','u','e', +// - properties[0]::value +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +9,0,0,0, +38, +'2','0','0',',','1','0','0',',','0', +// - pluginConf::resources +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'r','e','s','o','u','r','c','e','s', +// - pluginConf::resources +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - pluginConf::resources +// - Version 1.0 +// - Item count (LE) +10, +2,0,0,0, +// - pluginConf::resources +// - Version 1.0 +// - List item starts +10, +0,0,0,0, +// - object[0] +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - object[0] map +// - Version 1.0 +// - Item count (LE) +10, +4,0,0,0, +// - object[0]::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - object[0]::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +9,0,0,0, +38, +'v','i','e','w','1','.','b','m','p', +// - object[0]::path +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'p','a','t','h', +// - object[0]::path +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +37,0,0,0, +150, +'2','4','5','6','\\','2','7','0','5','1','3','7','5','1','\\','5','3','6','9','1','6','2','4','1','\\','1','.','0','\\','s','o','u','r','c','e','s','\\', +// - object[0]::mediatype +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'m','e','d','i','a','t','y','p','e', +// - object[0]::mediatype +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +9,0,0,0, +38, +'m','i','m','e','_','t','y','p','e', +// - Object[0]::tag +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +3,0,0,0, +14, +'t','a','g', +// - Object[0]::tag +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +0,0,0,0, +2, +// - pluginConf::resources +// - Version 1.0 +// - List item starts +10, +0,0,0,0, +// - object[0] +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - object[0] map +// - Version 1.0 +// - Item count (LE) +10, +4,0,0,0, +// - object[0]::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - object[0]::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +12,0,0,0, +50, +'h','s','_','l','o','g','o','z','.','j','p','g', +// - object[0]::path +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'p','a','t','h', +// - object[0]::path +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +37,0,0,0, +150, +'2','4','5','6','\\','2','7','0','5','1','3','7','5','1','\\','5','3','6','9','1','6','2','4','1','\\','1','.','0','\\','s','o','u','r','c','e','s','\\', +// - object[0]::mediatype +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'m','e','d','i','a','t','y','p','e', +// - object[0]::mediatype +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +9,0,0,0, +38, +'m','i','m','e','_','t','y','p','e', +// - Object[1]::tag +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +3,0,0,0, +14, +'t','a','g', +// - Object[1]::tag +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +0,0,0,0, +2 +}; + + + +// Test step 4 method: +const TUint8 restoreconfigurations_1_ts_4_method[] = "RestoreConfigurations"; + +// Test step 1 input: +const TUint8 restoreconfigurations_1_ts_4_input[] = { +// RestoreConfigurations(Input) +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// - RestoreConfigurations(Input)::restore +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +7,0,0,0, +30, +'r','e','s','t','o','r','e', +// - RestoreConfigurations::value +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +3,0,0,0, +14, +'a','l','l' +}; + +// Test step 4 output: +const TUint8 restoreconfigurations_1_ts_4_output[] = { +// RestoreConfigurations(Output) +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// - RestoreConfigurations(Output)::status +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +6,0,0,0, +26, +'s','t','a','t','u','s', +// - AddPlugin(Input)::status +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeTInt32 +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +1, +0,0,0,0 +}; + + + + +// Test step 5 method: +const TUint8 restoreconfigurations_1_ts_5_method[] = "GetActiveAppConf"; + + +// Test step 5 input: +const TUint8 restoreconfigurations_1_ts_5_input = 0; + + +// Test step 5 expected output: +const TUint8 restoreconfigurations_1_ts_5_output[] = { +// GetActiveAppConf(Output) +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// GetActiveAppConf(Output)::appConf +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +7,0,0,0, +30, +'a','p','p','C','o','n','f', +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - appConf map +// - Version 1.0 +// - Item count (LE) +10, +12,0,0,0, +// - appConf::id +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +2,0,0,0, +10, +'i','d', +// - appConf::id +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'1', +// - appConf::uid +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +3,0,0,0, +14, +'u','i','d', +// - appConf::uid +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +10,0,0,0, +42, +'0','x','2','0','0','0','B','1','1','0', +// - appConf::type +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'t','y','p','e', +// - appConf::type +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +11,0,0,0, +46, +'a','p','p','l','i','c','a','t','i','o','n', +// - appConf::interface +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'i','n','t','e','r','f','a','c','e', +// - appConf::interface +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +10,0,0,0, +42, +'0','x','2','0','0','0','0','F','B','1', +// - appConf::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - appConf::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +14,0,0,0, +58, +'T','y','p','i','c','a','l',' ','-',' ','R','o','o','t', +// - appConf::multiinstance +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +13,0,0,0, +54, +'m','u','l','t','i','i','n','s','t','a','n','c','e', +// - appConf::multiinstance +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'1', +// - appConf::description +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'d','e','s','c', +// - appConf::description +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +0,0,0,0, +2, +// - appConf::state +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +5,0,0,0, +22, +'s','t','a','t','e', +// - appConf::state +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +12,0,0,0, +50, +'N','o','t','C','o','n','f','i','r','m','e','d', +// - appConf::max_child +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'m','a','x','_','c','h','i','l','d', +// - appConf::max_child +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'6', +// - appConf::plugins +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +7,0,0,0, +30, +'p','l','u','g','i','n','s', +// - appConf::plugins +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - appConf::plugins +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// - appConf::plugins +// - Version 1.0 +// - List item starts +10, +0,0,0,0, +// - appConf::plugins[0] +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - plugins[0] map +// - Version 1.0 +// - Item count (LE) +10, +4,0,0,0, +// - plugins[0]::id +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +2,0,0,0, +10, +'i','d', +// - plugins[0]::id +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'1', +// - plugins[0]::uid +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +3,0,0,0, +14, +'u','i','d', +// - plugins[0]::uid +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +10,0,0,0, +42, +'0','x','2','0','0','0','B','1','1','1', +// - plugins[0]::activationstate +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +15,0,0,0, +62, +'a','c','t','i','v','a','t','i','o','n','s','t','a','t','e', +// - plugins[0]::activationstate +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'1', +// - plugins[0]::locking_status +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +14,0,0,0, +58, +'l','o','c','k','i','n','g','_','s','t','a','t','u','s', +// - plugins[0]::locking_status +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +4,0,0,0, +18, +'n','o','n','e', +// - appConf::settings +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +8,0,0,0, +34, +'s','e','t','t','i','n','g','s', +// - appConf::settings +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - appConf::settings +// - Version 1.0 +// - Item count (LE) +10, +0,0,0,0, +// - appConf::resources +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'r','e','s','o','u','r','c','e','s', +// - appConf::resources +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - appConf::resources +// - Version 1.0 +// - List item count +10, +1,0,0,0, +// - resources[0]::object +// - Version 1.0 +// - List item starts +10, +0,0,0,0, +// - Object[0] +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - Object[0] map +// - Version 1.0 +// - Item count (LE) +10, +4,0,0,0, +// - Object[0]::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - Object[0]::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +8,0,0,0, +34, +'r','o','o','t','.','b','m','p', +// - Object[0]::path +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'p','a','t','h', +// - Object[0]::path +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +42,0,0,0, +170, +'5','3','6','8','7','4','9','2','9','\\','2','7','0','5','1','3','7','5','1','\\','5','3','6','9','1','6','2','4','0','\\','1','.','0','\\','s','o','u','r','c','e','s','\\', +// - Object[0]::mediatype +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'m','e','d','i','a','t','y','p','e', +// - Object[0]::mediatype +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +9,0,0,0, +38, +'m','i','m','e','_','t','y','p','e', +// - Object[0]::tag +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +3,0,0,0, +14, +'t','a','g', +// - Object[0]::tag +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +0,0,0,0, +2 +}; + + + +// Test step 6 method: +const TUint8 restoreconfigurations_1_ts_6_method[] = "GetPluginConf"; + +// Test step 6 input: +const TUint8 restoreconfigurations_1_ts_6_input[] = { +// GetPluginConf(Input) +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// - GetPluginConf(Input)::pluginId +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +8,0,0,0, +34, +'p','l','u','g','i','n','I','d', +// - GetPluginConf(Input)::pluginId +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'1' +}; + +// Test step 6 output: +const TUint8 restoreconfigurations_1_ts_6_output[] = { +// GetPluginConf(Output) +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// GetPluginConf(Output)::pluginConf +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +10,0,0,0, +42, +'p','l','u','g','i','n','C','o','n','f', +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - pluginConf map +// - Version 1.0 +// - Item count (LE) +10, +12,0,0,0, +// - pluginConf::id +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +2,0,0,0, +10, +'i','d', +// - pluginConf::id +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'2', +// - pluginConf::uid +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +3,0,0,0, +14, +'u','i','d', +// - pluginConf::uid +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +10,0,0,0, +42, +'0','x','2','0','0','0','B','1','1','1', +// - pluginConf::type +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'t','y','p','e', +// - pluginConf::type +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +4,0,0,0, +18, +'v','i','e','w', +// - pluginConf::interface +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'i','n','t','e','r','f','a','c','e', +// - pluginConf::interface +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +5,0,0,0, +22, +'0','x','9','9','8', +// - pluginConf::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - pluginConf::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +15,0,0,0, +62, +'T','y','p','i','c','a','l',' ','-',' ','V','i','e','w','1', +// - pluginConf::multiinstance +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +13,0,0,0, +54, +'m','u','l','t','i','i','n','s','t','a','n','c','e', +// - pluginConf::multiinstance +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'1', +// - pluginConf::description +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'d','e','s','c', +// - pluginConf::description +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +0,0,0,0, +2, +// - pluginConf::state +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +5,0,0,0, +22, +'s','t','a','t','e', +// - pluginConf::state +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +12,0,0,0, +50, +'N','o','t','C','o','n','f','i','r','m','e','d', +// - pluginConf::max_child +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'m','a','x','_','c','h','i','l','d', +// - pluginConf::max_child +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +1,0,0,0, +6, +'6', +// - pluginConf::plugins +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +7,0,0,0, +30, +'p','l','u','g','i','n','s', +// - pluginConf::plugins +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - pluginConf::plugins +// - Version 1.0 +// - Item count (LE) +10, +0,0,0,0, +// - pluginConf::settings +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +8,0,0,0, +34, +'s','e','t','t','i','n','g','s', +// - pluginConf::settings +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - pluginConf::settings +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// - pluginConf::settings +// - Version 1.0 +// - List item starts +10, +0,0,0,0, + +// - items[0] +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - items[0] map +// - Version 1.0 +// - Item count (LE) +10, +3,0,0,0, +// - items[0]::itemId +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +6,0,0,0, +26, +'i','t','e','m','I','d', +// - items[0]::itemId +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value (empty) +10, +5, +7,0,0,0, +30, +'b','g','c','o','l','o','r', +// - items[0]::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - items[0]::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value (empty) +10, +5, +16,0,0,0, +66, +'B','a','c','k','g','r','o','u','n','d',' ','c','o','l','o','r', +// - items[0]::properties +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +10,0,0,0, +42, +'p','r','o','p','e','r','t','i','e','s', +// - items[0]::properties +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - items[0]::properties +// - Version 1.0 +// - Item count (LE) +10, +1,0,0,0, +// - items[0]::properties +// - Version 1.0 +// - List item starts +10, +0,0,0,0, +// - properties[0] +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - properties[0] map +// - Version 1.0 +// - Item count (LE) +10, +2,0,0,0, +// - prperties[0]::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - properties[0]::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +5,0,0,0, +22, +'v','a','l','u','e', +// - prperties[0]::value +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +5,0,0,0, +22, +'v','a','l','u','e', +// - properties[0]::value +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +9,0,0,0, +38, +'2','0','0',',','1','0','0',',','0', +// - pluginConf::resources +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'r','e','s','o','u','r','c','e','s', +// - pluginConf::resources +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeList +10, +7, +// - pluginConf::resources +// - Version 1.0 +// - Item count (LE) +10, +2,0,0,0, +// - pluginConf::resources +// - Version 1.0 +// - List item starts +10, +0,0,0,0, +// - object[0] +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - object[0] map +// - Version 1.0 +// - Item count (LE) +10, +4,0,0,0, +// - object[0]::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - object[0]::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +9,0,0,0, +38, +'v','i','e','w','1','.','b','m','p', +// - object[0]::path +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'p','a','t','h', +// - object[0]::path +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +37,0,0,0, +150, +'2','4','5','6','\\','2','7','0','5','1','3','7','5','1','\\','5','3','6','9','1','6','2','4','1','\\','1','.','0','\\','s','o','u','r','c','e','s','\\', +// - object[0]::mediatype +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'m','e','d','i','a','t','y','p','e', +// - object[0]::mediatype +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +9,0,0,0, +38, +'m','i','m','e','_','t','y','p','e', +// - Object[0]::tag +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +3,0,0,0, +14, +'t','a','g', +// - Object[0]::tag +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +0,0,0,0, +2, +// - pluginConf::resources +// - Version 1.0 +// - List item starts +10, +0,0,0,0, +// - object[0] +// - Version 1.0 +// - Variant value type, EVariantTypeMap +10, +8, +// - object[0] map +// - Version 1.0 +// - Item count (LE) +10, +4,0,0,0, +// - object[0]::name +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'n','a','m','e', +// - object[0]::name +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +12,0,0,0, +50, +'h','s','_','l','o','g','o','z','.','j','p','g', +// - object[0]::path +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +4,0,0,0, +18, +'p','a','t','h', +// - object[0]::path +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +37,0,0,0, +150, +'2','4','5','6','\\','2','7','0','5','1','3','7','5','1','\\','5','3','6','9','1','6','2','4','1','\\','1','.','0','\\','s','o','u','r','c','e','s','\\', +// - object[0]::mediatype +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +9,0,0,0, +38, +'m','e','d','i','a','t','y','p','e', +// - object[0]::mediatype +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +9,0,0,0, +38, +'m','i','m','e','_','t','y','p','e', +// - Object[1]::tag +// - Variant name +// - Version 1.0 +// - Semantic ID (LE) +// - Variant name length (LE) +// - Variant name descriptor maximum length ( ( variant name length * 4 ) + 2 ) +// - Variant name +10, +12,0,0,0, +3,0,0,0, +14, +'t','a','g', +// - Object[1]::tag +// - Variant value +// - Version 1.0 +// - Variant value type, EVariantTypeDesC +// - Variant value length (LE) +// - Variant value descriptor maximum length ( ( variant value length * 4 ) + 2 ) +// - Variant value +10, +5, +0,0,0,0, +2 +}; +#endif // C_MT_HSPS_RESTORECONFIGURATIONS_1_H diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/tsrc/hspsconfigurationif/inc/mt_hspsconfigurationif.h --- a/homescreensrv_plat/sapi_homescreenplugin/tsrc/hspsconfigurationif/inc/mt_hspsconfigurationif.h Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreensrv_plat/sapi_homescreenplugin/tsrc/hspsconfigurationif/inc/mt_hspsconfigurationif.h Tue Feb 02 00:23:10 2010 +0200 @@ -443,6 +443,11 @@ * See HSPS module test specification */ void SetActivePlugin_6_L(); + /** + * Test case function for test case RestoreConfigurations(1) + * See HSPS module test specification + */ + void RestoreConfigurations_1_L(); private: // Data diff -r ff572005ac23 -r 1a2a00e78665 homescreensrv_plat/sapi_homescreenplugin/tsrc/hspsconfigurationif/src/mt_hspsconfigurationif.cpp --- a/homescreensrv_plat/sapi_homescreenplugin/tsrc/hspsconfigurationif/src/mt_hspsconfigurationif.cpp Tue Jan 26 12:11:15 2010 +0200 +++ b/homescreensrv_plat/sapi_homescreenplugin/tsrc/hspsconfigurationif/src/mt_hspsconfigurationif.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -114,6 +114,8 @@ #include "mt_hsps_setactiveplugin_4.h" #include "mt_hsps_setactiveplugin_5.h" #include "mt_hsps_setactiveplugin_6.h" +// restore configurations +#include "mt_hsps_restoreconfigurations_1.h" // ======== LOCAL CONSTANTS ==================================================== @@ -2882,6 +2884,68 @@ //------------------------------------------------------------------------------ // Test case table //------------------------------------------------------------------------------ +void MT_CHSPSConfigurationIf::RestoreConfigurations_1_L() + { + // Pre conditions + // Set active configuration to Typical configuration + EUNIT_PRINT( _L8( "Pre conditions: Set Active configuration Typical" ) ); + SetActiveConfigurationL( KHSPSTestAppUid, KHSPSActiveConfTypical ); + // Attach to HSPS + EUNIT_PRINT( _L8( "Pre conditions: Attach to HSPS service IConfiguration interface" ) ); + AttachServiceL( KHSPS, KHSPSConfigurationIf, KHSPSTestAppUid ); + + // Test step 1 + EUNIT_PRINT( _L8( "Test step 1" ) ); + RunTestStepSyncL( + ( TUint8* )restoreconfigurations_1_ts_1_method, + ( TUint8* )restoreconfigurations_1_ts_1_input, + ( TUint8* )restoreconfigurations_1_ts_1_output ); + EUNIT_PRINT( _L8( "Test step passed" ) ); + + // Test step 2 + EUNIT_PRINT( _L8( "Test step 2" ) ); + RunTestStepSyncL( + ( TUint8* )restoreconfigurations_1_ts_2_method, + ( TUint8* )restoreconfigurations_1_ts_2_input, + ( TUint8* )restoreconfigurations_1_ts_2_output ); + EUNIT_PRINT( _L8( "Test step passed" ) ); + + // Test step 3 + EUNIT_PRINT( _L8( "Test step 3" ) ); + RunTestStepSyncL( + ( TUint8* )restoreconfigurations_1_ts_3_method, + ( TUint8* )restoreconfigurations_1_ts_3_input, + ( TUint8* )restoreconfigurations_1_ts_3_output ); + EUNIT_PRINT( _L8( "Test step passed" ) ); + + // Test step 4 + EUNIT_PRINT( _L8( "Test step 4" ) ); + RunTestStepSyncL( + ( TUint8* )restoreconfigurations_1_ts_4_method, + ( TUint8* )restoreconfigurations_1_ts_4_input, + ( TUint8* )restoreconfigurations_1_ts_4_output ); + EUNIT_PRINT( _L8( "Test step passed" ) ); + + // Test step 5 + EUNIT_PRINT( _L8( "Test step 5" ) ); + RunTestStepSyncL( + ( TUint8* )restoreconfigurations_1_ts_5_method, + ( TUint8* )restoreconfigurations_1_ts_5_input, + ( TUint8* )restoreconfigurations_1_ts_5_output ); + EUNIT_PRINT( _L8( "Test step passed" ) ); + + // Test step 6 + EUNIT_PRINT( _L8( "Test step 6" ) ); + RunTestStepSyncL( + ( TUint8* )restoreconfigurations_1_ts_6_method, + ( TUint8* )restoreconfigurations_1_ts_6_input, + ( TUint8* )restoreconfigurations_1_ts_6_output ); + EUNIT_PRINT( _L8( "Test step passed" ) ); + } + +//------------------------------------------------------------------------------ +// Test case table +//------------------------------------------------------------------------------ EUNIT_BEGIN_TEST_TABLE( MT_CHSPSConfigurationIf, "This is a test suite for HSPS configuration interface.", @@ -3400,6 +3464,14 @@ "FUNCTIONALITY", SetupL, SetActivePlugin_6_L, Teardown ) + EUNIT_TEST( + "RestoreConfigurations(1)", + "IConfiguration", + "SetActivePlugin", + "FUNCTIONALITY", + SetupL, RestoreConfigurations_1_L, Teardown ) + + EUNIT_END_TEST_TABLE // END OF FILE diff -r ff572005ac23 -r 1a2a00e78665 idlefw/group/ailaunch.mmp --- a/idlefw/group/ailaunch.mmp Tue Jan 26 12:11:15 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,59 +0,0 @@ -/* -* Copyright (c) 2002-2005 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" -* 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: -* -*/ - -#include -#include -#include - -TARGET ailaunch.exe -TARGETTYPE exe -UID 0x100039CE AI_UID3_AIFW_EXE -SECUREID AI_SID_AIFW_EXE -VENDORID VID_DEFAULT - -CAPABILITY CAP_APPLICATION PowerMgmt NetworkControl TrustedUI - -EPOCSTACKSIZE 0x5000 -EPOCHEAPSIZE 0x300000 0xC00000 - -SOURCEPATH ../src/framework -SOURCE main.cpp - -START RESOURCE ailaunch.rss -HEADER -TARGETPATH APP_RESOURCE_DIR -LANGUAGE_IDS -END - -START RESOURCE ailaunch_reg.rss -DEPENDS ailaunch.rsg -TARGETPATH /private/10003a3f/apps -END - -USERINCLUDE . -USERINCLUDE ../inc/common -USERINCLUDE ../inc/framework - -MW_LAYER_SYSTEMINCLUDE - -LIBRARY euser.lib -LIBRARY apparc.lib -LIBRARY aifw.lib -LIBRARY eikcore.lib -LIBRARY ecom.lib -LIBRARY flogger.lib - diff -r ff572005ac23 -r 1a2a00e78665 idlefw/group/bld.inf --- a/idlefw/group/bld.inf Tue Jan 26 12:11:15 2010 +0200 +++ b/idlefw/group/bld.inf Tue Feb 02 00:23:10 2010 +0200 @@ -39,7 +39,8 @@ aiutils.mmp aiidleint.mmp aifw.mmp -ailaunch.mmp +homescreen.mmp + PRJ_TESTMMPFILES @@ -49,6 +50,9 @@ // Include subprojects // +// hslaunch +#include "../hslaunch/group/bld.inf" + // Plug-ins #include "../plugins/group/bld.inf" diff -r ff572005ac23 -r 1a2a00e78665 idlefw/group/homescreen.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlefw/group/homescreen.mmp Tue Feb 02 00:23:10 2010 +0200 @@ -0,0 +1,58 @@ +/* +* Copyright (c) 2002-2005 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" +* 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: +* +*/ + +#include +#include +#include + +TARGET homescreen.exe +TARGETTYPE exe +UID 0x100039CE AI_UID3_AIFW_EXE +SECUREID AI_SID_AIFW_EXE +VENDORID VID_DEFAULT + +CAPABILITY CAP_APPLICATION PowerMgmt NetworkControl TrustedUI + +EPOCSTACKSIZE 0x5000 +EPOCHEAPSIZE 0x300000 0xC00000 + +SOURCEPATH ../src/framework +SOURCE main.cpp + +START RESOURCE homescreen.rss +HEADER +TARGETPATH APP_RESOURCE_DIR +LANGUAGE_IDS +END + +START RESOURCE homescreen_reg.rss +TARGETPATH /private/10003a3f/apps +END + +USERINCLUDE . +USERINCLUDE ../inc/common +USERINCLUDE ../inc/framework + +MW_LAYER_SYSTEMINCLUDE + +LIBRARY euser.lib +LIBRARY apparc.lib +LIBRARY aifw.lib +LIBRARY eikcore.lib +LIBRARY ecom.lib +LIBRARY flogger.lib + diff -r ff572005ac23 -r 1a2a00e78665 idlefw/hslaunch/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlefw/hslaunch/group/bld.inf Tue Feb 02 00:23:10 2010 +0200 @@ -0,0 +1,28 @@ +/* +* Copyright (c) 2003 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" +* 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: This file provides the information required for building the +* hslaunch component. +* +*/ + +#include + +PRJ_PLATFORMS +ARMV5 WINSCW + +PRJ_EXPORTS + +PRJ_MMPFILES +hslaunch.mmp + diff -r ff572005ac23 -r 1a2a00e78665 idlefw/hslaunch/group/hslaunch.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlefw/hslaunch/group/hslaunch.mmp Tue Feb 02 00:23:10 2010 +0200 @@ -0,0 +1,48 @@ +/* +* Copyright (c) 2008 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" +* 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: Makefile of hslaunch +* +*/ + +#include + +TARGET ailaunch.exe + +targettype exe + +UID 0x1000008d 0x200286E3 +CAPABILITY ReadDeviceData WriteDeviceData +VENDORID VID_DEFAULT +SECUREID 0x200286E3 + +EPOCHEAPSIZE 0x1000 0x100000 // 4KB - 1 MB +EPOCSTACKSIZE 0x5000 + +SOURCEPATH ../src +SOURCE hslaunch.cpp +SOURCE hsprocessmonitor.cpp +SOURCE hsshutdownmonitor.cpp + +USERINCLUDE . +USERINCLUDE ../inc + +MW_LAYER_SYSTEMINCLUDE + +LIBRARY euser.lib // CBase etc +LIBRARY bafl.lib // descriptors +LIBRARY ssmcmn.lib // state manager + +LANG SC + + diff -r ff572005ac23 -r 1a2a00e78665 idlefw/hslaunch/inc/hslaunch.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlefw/hslaunch/inc/hslaunch.h Tue Feb 02 00:23:10 2010 +0200 @@ -0,0 +1,145 @@ +/* +* Copyright (c) 1020 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" +* 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: application class. +*/ + +#ifndef __HS_LAUNCH_ +#define __HS_LAUNCH_ + +#include +#include "hsprocessmonitor.h" +#include "hsshutdownmonitor.h" + +/** + * CHsLaunch + * + * application class. + * + * @since S60 5.2 + */ +class CHsLaunch : public CActive, + MHsProcessMonitorObserver, + MHsShutdownMonitorObserver + { + public: + /** + * Create new launcher + * + * @since S60 5.2 + */ + static CHsLaunch* NewL(); + + /** + * Destructor. + * + * @since S60 5.2 + */ + virtual ~CHsLaunch(); + + /** + * Set active object to be ran + * + * @since S60 5.2 + */ + void Activate(); + + /** + * Get application return value + * + * @return TInt Application return value + * @since S60 5.2 + */ + TInt ApplicationReturnValue(); + + protected: + /** + * C++ constructor. + * + * @since S60 5.2 + */ + CHsLaunch(); + + /** + * Symbian 2nd phase constructor + * + * @since S60 5.2 + */ + void ConstructL(); + + private: // From CActive. + /** + * From CActive + */ + void RunL(); + + /** + * From CActive + * + * @since S60 5.2 + */ + void DoCancel(); + + /** + * From CActive + * + * @since S60 5.2 + */ + TInt RunError( TInt aError ); + + private: // From MHsProcessMonitorObserver + /** + * From MHsProcessMonitorObserver + */ + void ProcessEnded( const TExitType& aExitType, + const TInt aExitReason, + const TExitCategoryName& aExitCategory ); + + /** + * From MHsProcessMonitorObserver + */ + void ProcessMonitoringError( TInt aError ); + + private: // From MHsShutdownMonitorObserver + /** + * From MHsShutdownMonitorObserver + */ + void SystemShutdownEvent(); + + private: + /** + * Initialize process monitor + * + * @param aProcessId Id of process to monitor + */ + void InitProcessMonitorL( const TInt aProcessId ); + + /** + * Shut down application + * + * @param aApplicationReturnValue Application return value. + */ + void ShutdownApp( const TInt aApplicationReturnValue ); + + private: // data. + // Process monitor. Owned. + CHsProcessMonitor* iProcessMonitor; + + // Shutdown monitor. Owned. + CHsShutdownMonitor* iShutdownMonitor; + + // Application return value + TInt iApplicationReturnValue; + }; + +#endif // __HS_LAUNCH_ diff -r ff572005ac23 -r 1a2a00e78665 idlefw/hslaunch/inc/hsprocessmonitor.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlefw/hslaunch/inc/hsprocessmonitor.h Tue Feb 02 00:23:10 2010 +0200 @@ -0,0 +1,155 @@ +/* +* Copyright (c) 1020 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" +* 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: process monitor. +*/ + + +#ifndef __HS_PROCESS_MONITOR__ +#define __HS_PROCESS_MONITOR__ + +#include + +/** + * MHsProcessMonitorObserver + * + * Monitor component observer. + * + * @since S60 5.2 + */ +class MHsProcessMonitorObserver + { + public: + /** + * Called when monitored process is ended. + * + * @param aExitType Exit type + * @param aExitReason Exit reason + * @param aExitCategory Exit category + */ + virtual void ProcessEnded( const TExitType& aExitType, + const TInt aExitReason, + const TExitCategoryName& aExitCategory ) = 0; + + /** + * Called when error occured during monitoring. + * + * @param aError System wide error code. + */ + virtual void ProcessMonitoringError( TInt aError ) = 0; + }; + +/** + * HsProcessMonitor + * + * Component for monitoring process states. + * + * @since S60 5.2 + */ +class CHsProcessMonitor : public CActive + { + public: + /** + * Create new monitor + * + * @param aProcessName process id + * @param aObserver monitor observer + * @since S60 5.2 + */ + static CHsProcessMonitor* NewL( const TInt aProcessId, + MHsProcessMonitorObserver& aObserver ); + + /** + * Destructor + * + * @since S60 5.2 + */ + ~CHsProcessMonitor(); + + /** + * Attach monitor + * + * @return TInt System wide error code. + * @since S60 5.2 + */ + TInt AttachMonitor(); + + /** + * Start monitor + * + * @return TInt System wide error code. + * @since S60 5.2 + */ + TInt StartMonitor(); + + protected: + /** + * C++ constructor + * + * @param aProcessName process id + * @param aObserver watchdog observer. + * @since S60 5.2 + */ + CHsProcessMonitor( const TInt aProcessId, + MHsProcessMonitorObserver& aObserver ); + + /** + * Symbian 2nd phase constructor + * + * @since S60 5.2 + */ + void ConstructL(); + + private: // From CActive + /** + * From CActive + */ + void RunL(); + + /** + * From CActive + * + * @since S60 5.2 + */ + void DoCancel(); + + /** + * From CActive + * + * @since S60 5.2 + */ + TInt RunError( TInt aError ); + + private: // New methods + /** + * Close process handle if open + * + * @since S60 5.2 + */ + void SecureProcessHandleAsClosed(); + + private: + // process id + TInt iProcessId; + + // watchdog observer + MHsProcessMonitorObserver& iObserver; + + // Process handle + RProcess iProcess; + + // boolean to represent whether process handle is open + TBool iProcessHandleOpen; + }; + +#endif // __HS_PROCESS_MONITOR__ diff -r ff572005ac23 -r 1a2a00e78665 idlefw/hslaunch/inc/hsshutdownmonitor.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlefw/hslaunch/inc/hsshutdownmonitor.h Tue Feb 02 00:23:10 2010 +0200 @@ -0,0 +1,117 @@ +/* +* Copyright (c) 1020 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" +* 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: shutdown monitor. +*/ + + +#ifndef __HS_SHUTDOWN_MONITOR__ +#define __HS_SHUTDOWN_MONITOR__ + +#include +#include + +/** + * MHsShutdownMonitorObserver + * + * Monitor component observer. + * + * @since S60 5.2 + */ +class MHsShutdownMonitorObserver + { + public: + /** + * Called when shutdown occurs + */ + virtual void SystemShutdownEvent() = 0; + }; + +/** + * HsShutdownMonitor + * + * Component for monitoring shutdown + * + * @since S60 5.2 + */ +class CHsShutdownMonitor : public CActive + { + public: + /** + * Create new monitor + * + * @param aObserver monitor observer + * @since S60 5.2 + */ + static CHsShutdownMonitor* NewL( + MHsShutdownMonitorObserver& aObserver ); + + /** + * Destructor + * + * @since S60 5.2 + */ + ~CHsShutdownMonitor(); + + /** + * Start monitor + * + * @since S60 5.2 + */ + void StartMonitor(); + + protected: + /** + * C++ constructor + * + * @param aObserver monitor observer. + * @since S60 5.2 + */ + CHsShutdownMonitor( MHsShutdownMonitorObserver& aObserver ); + + /** + * Symbian 2nd phase constructor + * + * @since S60 5.2 + */ + void ConstructL(); + + private: // From CActive + /** + * From CActive + */ + void RunL(); + + /** + * From CActive + * + * @since S60 5.2 + */ + void DoCancel(); + + /** + * From CActive + * + * @since S60 5.2 + */ + TInt RunError( TInt aError ); + + private: + // watchdog observer + MHsShutdownMonitorObserver& iObserver; + + // State aware session. + RSsmStateAwareSession iSAS; + }; + +#endif // __HS_PROCESS_MONITOR__ diff -r ff572005ac23 -r 1a2a00e78665 idlefw/hslaunch/src/hslaunch.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlefw/hslaunch/src/hslaunch.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -0,0 +1,365 @@ +/* + * Copyright (c) 2008 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" + * 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: application class. + * + */ + +#include +#include "hslaunch.h" + +// ========================= DECLARATIONS ================================== +_LIT( KHsExeName, "homescreen.exe" ); +_LIT( KHsProcessName, "Home screen" ); +const TInt KSleepOnRetry = 250000; // 250ms +const TUid KPSCategoryUid = TUid::Uid( 0x200286E3 ); +const TInt KPSCrashCountKey = 1; +_LIT_SECURITY_POLICY_C1( KPSReadPolicy, ECapabilityReadDeviceData ); +_LIT_SECURITY_POLICY_C1( KPSWritePolicy, ECapabilityWriteDeviceData ); + +// ========================= LOCAL FUNCTIONS ================================== + +void RunAppL() + { + // Construct active scheduler. + CActiveScheduler* activeScheduler = new ( ELeave )CActiveScheduler(); + CleanupStack::PushL( activeScheduler ); + CActiveScheduler::Install( activeScheduler ); + + // Construct app. + CHsLaunch* app = CHsLaunch::NewL(); + CleanupStack::PushL( app ); + + app->Activate(); + + // Signal startup. + RProcess::Rendezvous(KErrNone); + + // Start active scheduler. + CActiveScheduler::Start(); + + User::LeaveIfError( app->ApplicationReturnValue() ); + + // Cleanup. + CleanupStack::PopAndDestroy( app ); + CleanupStack::PopAndDestroy( activeScheduler ); + } + +// ----------------------------------------------------------------------------- +// E32Main +// entry-point +// ----------------------------------------------------------------------------- +// +TInt E32Main() + { + TInt error = KErrNone; + + __UHEAP_MARK; + + // Construct cleanup stack. + CTrapCleanup* cleanupstack = CTrapCleanup::New(); + if( !cleanupstack ) + { + error = KErrNoMemory; + } + + // Call next phase of startup. + if( !error ) + { + TRAP( error, RunAppL() ); + } + + // Cleanup. + delete cleanupstack; + cleanupstack = NULL; + + __UHEAP_MARKEND; + + return error; + } + +// ========================= MEMBER FUNCTIONS ================================== + +// ----------------------------------------------------------------------------- +// CHsLaunch::NewL() +// Two-phased constructor. +// ----------------------------------------------------------------------------- +CHsLaunch* CHsLaunch::NewL() + { + CHsLaunch* self = new ( ELeave ) CHsLaunch(); + CleanupStack::PushL( self ); + self->ConstructL(); + CleanupStack::Pop( self ); + return self; + } + +// ----------------------------------------------------------------------------- +// CHsLaunch::ConstructL() +// Symbian 2nd phase constructor can leave. +// ----------------------------------------------------------------------------- +// +void CHsLaunch::ConstructL() + { + iShutdownMonitor = CHsShutdownMonitor::NewL( *this ); + iShutdownMonitor->StartMonitor(); + + // Create property to pub/sub. + TInt error = RProperty::Define( KPSCrashCountKey, + RProperty::EInt, + KPSReadPolicy, + KPSWritePolicy ); + if( error == KErrNone ) + { + // Init it to zero. + error = RProperty::Set( KPSCategoryUid, KPSCrashCountKey, 0 ); + } + else if( error == KErrAlreadyExists ) + { + error = KErrNone; + } + + User::LeaveIfError( error ); + } + +// ----------------------------------------------------------------------------- +// CHsLaunch::CHsLaunch() +// C++ default constructor can NOT contain any code, that might leave. +// ----------------------------------------------------------------------------- +CHsLaunch::CHsLaunch() : + CActive( EPriorityStandard ), + iApplicationReturnValue( KErrNone ) + { + CActiveScheduler::Add( this ); + } + +// ----------------------------------------------------------------------------- +// CHsLaunch::~CHsLaunch() +// Destructor. +// ----------------------------------------------------------------------------- +// +CHsLaunch::~CHsLaunch() + { + Cancel(); + + delete iProcessMonitor; + iProcessMonitor = NULL; + + delete iShutdownMonitor; + iShutdownMonitor = NULL; + } + +// ----------------------------------------------------------------------------- +// CHsLaunch::Activate() +// Set active object to be ran +// ----------------------------------------------------------------------------- +// +void CHsLaunch::Activate() + { + SetActive(); + TRequestStatus* tmp = &iStatus; + User::RequestComplete( tmp, KErrNone ); + } + +// ----------------------------------------------------------------------------- +// CHsLaunch::ApplicationReturnValue() +// Get application return value +// ----------------------------------------------------------------------------- +// +TInt CHsLaunch::ApplicationReturnValue() + { + return iApplicationReturnValue; + } + +// ----------------------------------------------------------------------------- +// CHsLaunch::RunL +// ----------------------------------------------------------------------------- +// +void CHsLaunch::RunL() + { + // Create app or connect to existing. + TInt processExisted = EFalse; + + RProcess process; + TInt processError = process.Create( KHsExeName, KNullDesC ); + if( processError == KErrAlreadyExists ) + { + processError = process.Open( KHsProcessName, EOwnerProcess ); + processExisted = ETrue; + } + + TInt monitorError = KErrNone; + if( processError == KErrNone ) + { + TRAP( monitorError, InitProcessMonitorL( process.Id() ) ); + } + + if( processError == KErrNone && + !processExisted ) + { + // Make sure process is started even if monitor startup + // fails. This will assure that process is not left in + // suspended state. Resume can not be called for + // already running process (will cause KERN-EXEC 46). + process.Resume(); + } + + process.Close(); + + if( processError != KErrNone || + monitorError != KErrNone ) + { + /* Error in this method is critical and it might cause + * endless active scheduler loop if no active objects are + * not triggered. Therefore shutdown. This application + * will be restarted by startup sw. */ + ShutdownApp( KErrGeneral ); + } + } + +// ----------------------------------------------------------------------------- +// CHsLaunch::DoCancel() +// From CActive. +// ----------------------------------------------------------------------------- +// +void CHsLaunch::DoCancel() + { + if( iProcessMonitor ) + { + iProcessMonitor->Cancel(); + } + + if( iShutdownMonitor ) + { + iShutdownMonitor->Cancel(); + } + } + +// ----------------------------------------------------------------------------- +// CHsLaunch::RunError() +// From CActive. +// ----------------------------------------------------------------------------- +// +TInt CHsLaunch::RunError( TInt aError ) + { + return aError; + } + +// ----------------------------------------------------------------------------- +// CHsLaunch::ProcessEndedL() +// From MHsProcessMonitorObserver +// ----------------------------------------------------------------------------- +// +void CHsLaunch::ProcessEnded( const TExitType& aExitType, + const TInt /*aExitReason*/, + const TExitCategoryName& /*aExitCategory*/ ) + { + // Only respond to panic. EExitTerminate and EExitKill are ignored. + if( aExitType != EExitPanic ) + { + return; + } + + TInt crashCount = 0; + TInt error = RProperty::Get( KPSCategoryUid, + KPSCrashCountKey, + crashCount ); + + if( error == KErrNone ) + { + crashCount++; + error = RProperty::Set( KPSCategoryUid, + KPSCrashCountKey, + crashCount ); + } + + if( error == KErrNone ) + { + User::After( KSleepOnRetry ); + Activate(); + } + else + { + ShutdownApp( error ); + } + } + +// ----------------------------------------------------------------------------- +// CHsLaunch::ProcessMonitoringErrorL() +// From MHsProcessMonitorObserver +// ----------------------------------------------------------------------------- +// +void CHsLaunch::ProcessMonitoringError( TInt aError ) + { + /* Error in this method is critical and it might cause + * endless active scheduler loop if no active objects are + * not triggered. Therefore shutdown. This application + * will be restarted by startup sw. */ + ShutdownApp( aError ); + } + +// ----------------------------------------------------------------------------- +// CHsLaunch::SystemShutdownEvent() +// From MHsShutdownMonitorObserver +// ----------------------------------------------------------------------------- +// +void CHsLaunch::SystemShutdownEvent() + { + // Do not shut down app. Startup app would try to restart this app. + // Just deactivate all active objects and wait for power off. + if( IsActive() ) + { + Cancel(); + } + else + { + DoCancel(); + } + } + +// ----------------------------------------------------------------------------- +// CHsLaunch::InitProcessMonitorL() +// Initialize process monitor +// ----------------------------------------------------------------------------- +// +void CHsLaunch::InitProcessMonitorL( const TInt aProcessId ) + { + if( iProcessMonitor ) + { + delete iProcessMonitor; + iProcessMonitor = NULL; + } + iProcessMonitor = CHsProcessMonitor::NewL( aProcessId, *this ); + User::LeaveIfError( iProcessMonitor->StartMonitor() ); + } + +// ----------------------------------------------------------------------------- +// CHsLaunch::ShutdownApp() +// Shut down application +// ----------------------------------------------------------------------------- +// +void CHsLaunch::ShutdownApp( const TInt aApplicationReturnValue ) + { + if( IsActive() ) + { + Cancel(); + } + else + { + DoCancel(); + } + + iApplicationReturnValue = aApplicationReturnValue; + CActiveScheduler::Stop(); + } + +// End of File diff -r ff572005ac23 -r 1a2a00e78665 idlefw/hslaunch/src/hsprocessmonitor.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlefw/hslaunch/src/hsprocessmonitor.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -0,0 +1,184 @@ +/* + * Copyright (c) 2008 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" + * 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: process monitor. + * + */ + +#include "hsprocessmonitor.h" + +// ========================= MEMBER FUNCTIONS ================================== + +// ----------------------------------------------------------------------------- +// CHsProcessMonitor::NewL() +// Two-phased constructor +// ----------------------------------------------------------------------------- +CHsProcessMonitor* CHsProcessMonitor::NewL( const TInt iProcessId, + MHsProcessMonitorObserver& aObserver ) + { + CHsProcessMonitor* self = new ( ELeave ) CHsProcessMonitor( iProcessId, + aObserver ); + CleanupStack::PushL( self ); + self->ConstructL(); + CleanupStack::Pop( self ); + return self; + } + +// ----------------------------------------------------------------------------- +// CHsProcessMonitor::~CHsProcessMonitor() +// Destructor. +// ----------------------------------------------------------------------------- +// +CHsProcessMonitor::~CHsProcessMonitor() + { + Cancel(); + SecureProcessHandleAsClosed(); + iProcessId = KErrNotFound; + } + +// ----------------------------------------------------------------------------- +// CHsProcessMonitor::AttachMonitor() +// Attach monitor +// ----------------------------------------------------------------------------- +// +TInt CHsProcessMonitor::AttachMonitor() + { + SecureProcessHandleAsClosed(); + + TInt error = iProcess.Open( iProcessId, EOwnerProcess ); + + if( error == KErrNone ) + { + iProcessHandleOpen = ETrue; + } + + return error; + } + +// ----------------------------------------------------------------------------- +// CHsProcessMonitor::StartMonitor() +// Start monitor +// ----------------------------------------------------------------------------- +// +TInt CHsProcessMonitor::StartMonitor() + { + TInt error = KErrNone; + + if( !iProcessHandleOpen ) + { + error = AttachMonitor(); + } + + if( error == KErrNone ) + { + iProcess.Logon( iStatus ); + SetActive(); + } + + return error; + } + +// ----------------------------------------------------------------------------- +// CHsProcessMonitor::CHsProcessMonitor() +// C++ default constructor can NOT contain any code, that might leave. +// ----------------------------------------------------------------------------- +CHsProcessMonitor::CHsProcessMonitor( const TInt aProcessId, + MHsProcessMonitorObserver& aObserver ) : + CActive( EPriorityStandard ), + iProcessId( aProcessId ), + iObserver( aObserver ), + iProcessHandleOpen( EFalse ) + { + CActiveScheduler::Add( this ); + } + +// ----------------------------------------------------------------------------- +// CHsProcessMonitor::ConstructL() +// Symbian 2nd phase constructor can leave. +// ----------------------------------------------------------------------------- +// +void CHsProcessMonitor::ConstructL() + { + } + +// ----------------------------------------------------------------------------- +// CHsProcessMonitor::RunL +// ----------------------------------------------------------------------------- +// +void CHsProcessMonitor::RunL() + { + iProcess.LogonCancel( iStatus ); + + const TInt error = iStatus.Int(); + + if( error == KErrCancel ) + { + } + else if( error == KErrNoMemory ) + { + User::Leave( KErrNoMemory ); + } + else + { + const TExitType exitType = iProcess.ExitType(); + if( exitType == EExitPending ) + { + User::LeaveIfError( StartMonitor() ); + } + else + { + iObserver.ProcessEnded( exitType, + iProcess.ExitReason(), + iProcess.ExitCategory() ); + } + } + } + +// ----------------------------------------------------------------------------- +// CHsProcessMonitor::DoCancel() +// From CActive. +// ----------------------------------------------------------------------------- +// +void CHsProcessMonitor::DoCancel() + { + iProcess.LogonCancel( iStatus ); + } + +// ----------------------------------------------------------------------------- +// CHsProcessMonitor::RunError() +// From CActive. +// ----------------------------------------------------------------------------- +// +TInt CHsProcessMonitor::RunError( TInt aError ) + { + iObserver.ProcessMonitoringError( aError ); + + // Observer will handle error. Return green light. + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CHsProcessMonitor::SecureProcessHandleAsClosed() +// Close process handle if open +// ----------------------------------------------------------------------------- +// +void CHsProcessMonitor::SecureProcessHandleAsClosed() + { + if( iProcessHandleOpen ) + { + iProcess.Close(); + iProcessHandleOpen = EFalse; + } + } + +// End of File diff -r ff572005ac23 -r 1a2a00e78665 idlefw/hslaunch/src/hsshutdownmonitor.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlefw/hslaunch/src/hsshutdownmonitor.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -0,0 +1,130 @@ +/* + * Copyright (c) 2008 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" + * 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: shutdown monitor. + * + */ + +#include +#include + +#include "hsshutdownmonitor.h" + +// ========================= MEMBER FUNCTIONS ================================== + +// ----------------------------------------------------------------------------- +// CHsShutdownMonitor::NewL() +// Two-phased constructor +// ----------------------------------------------------------------------------- +CHsShutdownMonitor* CHsShutdownMonitor::NewL( + MHsShutdownMonitorObserver& aObserver ) + { + CHsShutdownMonitor* self = new ( ELeave ) CHsShutdownMonitor( aObserver ); + CleanupStack::PushL( self ); + self->ConstructL(); + CleanupStack::Pop( self ); + return self; + } + +// ----------------------------------------------------------------------------- +// CHsShutdownMonitor::~CHsShutdownMonitor() +// Destructor. +// ----------------------------------------------------------------------------- +// +CHsShutdownMonitor::~CHsShutdownMonitor() + { + Cancel(); + iSAS.Close(); + } + +// ----------------------------------------------------------------------------- +// CHsShutdownMonitor::StartMonitor() +// Start monitor +// ----------------------------------------------------------------------------- +// +void CHsShutdownMonitor::StartMonitor() + { + iSAS.RequestStateNotification( iStatus ); + SetActive(); + } + +// ----------------------------------------------------------------------------- +// CHsShutdownMonitor::CHsShutdownMonitor() +// C++ default constructor can NOT contain any code, that might leave. +// ----------------------------------------------------------------------------- +CHsShutdownMonitor::CHsShutdownMonitor( MHsShutdownMonitorObserver& aObserver ) : + CActive( EPriorityStandard ), + iObserver( aObserver ) + { + CActiveScheduler::Add( this ); + } + +// ----------------------------------------------------------------------------- +// CHsShutdownMonitor::ConstructL() +// Symbian 2nd phase constructor can leave. +// ----------------------------------------------------------------------------- +// +void CHsShutdownMonitor::ConstructL() + { + User::LeaveIfError( iSAS.Connect( KSM2GenMiddlewareDomain3 ) ); + } + +// ----------------------------------------------------------------------------- +// CHsShutdownMonitor::RunL +// ----------------------------------------------------------------------------- +// +void CHsShutdownMonitor::RunL() + { + User::LeaveIfError( iStatus.Int() ); + + TBool registerForMoreEvents = ETrue; + + TSsmState state = iSAS.State(); + if( state.MainState() == ESsmShutdown ) + { + iObserver.SystemShutdownEvent(); + registerForMoreEvents = EFalse; + } + + if( registerForMoreEvents ) + { + iSAS.AcknowledgeAndRequestStateNotification( KErrNone, iStatus ); + SetActive(); + } + else + { + iSAS.AcknowledgeStateNotification( KErrNone ); + } + } + +// ----------------------------------------------------------------------------- +// CHsShutdownMonitor::DoCancel() +// From CActive. +// ----------------------------------------------------------------------------- +// +void CHsShutdownMonitor::DoCancel() + { + iSAS.RequestStateNotificationCancel(); + } + +// ----------------------------------------------------------------------------- +// CHsShutdownMonitor::RunError() +// From CActive. +// ----------------------------------------------------------------------------- +// +TInt CHsShutdownMonitor::RunError( TInt aError ) + { + return aError; + } + +// End of File diff -r ff572005ac23 -r 1a2a00e78665 idlefw/plugins/mcsplugin/data/mcspluginsettingsres.rss --- a/idlefw/plugins/mcsplugin/data/mcspluginsettingsres.rss Tue Jan 26 12:11:15 2010 +0200 +++ b/idlefw/plugins/mcsplugin/data/mcspluginsettingsres.rss Tue Feb 02 00:23:10 2010 +0200 @@ -74,6 +74,7 @@ { command = EAiScutSettingsCmdChange; txt = qtn_options_change; + flags = EEikMenuItemAction; } #ifdef __SERIES60_HELP diff -r ff572005ac23 -r 1a2a00e78665 idlefw/plugins/sapidataplugin/src/sapidata.cpp --- a/idlefw/plugins/sapidataplugin/src/sapidata.cpp Tue Jan 26 12:11:15 2010 +0200 +++ b/idlefw/plugins/sapidataplugin/src/sapidata.cpp Tue Feb 02 00:23:10 2010 +0200 @@ -497,8 +497,17 @@ else if( iItemList[pIndex]->iType->Des() == KImage ) { TInt handle = KErrBadHandle; + TUint uintHandle = 0; + if ( variant.Get( uintHandle ) ) + { + handle = uintHandle; + } + else if ( !variant.Get( handle ) ) + { + handle = KErrBadHandle; + } // read as a image handle - if( ! variant.Get( handle ) ) + if( handle == KErrBadHandle ) { // no handle, so read as image path variant.Get( valPtr ); @@ -507,6 +516,7 @@ else { TInt maskHandle = KErrBadHandle; + TUint uintmaskHandle = 0; //Look for image mask HBufC8* maskKey = HBufC8::NewLC( itemName->Length() + KMask().Length() ); TPtr8 maskKeyPtr = maskKey->Des(); @@ -514,7 +524,14 @@ maskKeyPtr.Append( KMask ); if ( aDataMap->FindL( maskKeyPtr, variant ) ) { - variant.Get( maskHandle ); + if ( variant.Get( uintmaskHandle ) ) + { + maskHandle = uintmaskHandle; + } + else if ( !variant.Get( maskHandle ) ) + { + maskHandle = KErrBadHandle; + } } CleanupStack::PopAndDestroy( maskKey ); iPlugin->PublishImageL(aObserver, iItemList[pIndex]->iId, handle, maskHandle ); diff -r ff572005ac23 -r 1a2a00e78665 idlefw/rom/idlefw.iby --- a/idlefw/rom/idlefw.iby Tue Jan 26 12:11:15 2010 +0200 +++ b/idlefw/rom/idlefw.iby Tue Feb 02 00:23:10 2010 +0200 @@ -19,13 +19,11 @@ #ifndef ACTIVEIDLE3_IBY #define ACTIVEIDLE3_IBY -#ifndef ACTIVEIDLE2_IBY -#define ACTIVEIDLE2_IBY // Active Idle application and registration file S60_APP_EXE( ailaunch ) -S60_APP_AIF_RSC( ailaunch ) -S60_APP_AIF_ICONS( ailaunch ) -//S60_APP_RESOURCE( ailaunch ) +S60_APP_EXE( homescreen ) +S60_APP_AIF_RSC( homescreen ) +S60_APP_AIF_ICONS( homescreen ) file=ABI_DIR\BUILD_DIR\aiutils.dll SHARED_LIB_DIR\aiutils.dll file=ABI_DIR\BUILD_DIR\aiidleint.dll SHARED_LIB_DIR\aiidleint.dll @@ -33,8 +31,5 @@ // Content publishing plug-ins ECOM_PLUGIN( aidevstaplg.dll, aidevstaplg.rsc ) -#endif // ACTIVEIDLE2_IBY - -//data=\epoc32\release\winscw\udeb\z\private\10202be9\2001952b.txt private\10202be9\2001952b.txt #endif // ACTIVEIDLE3_IBY diff -r ff572005ac23 -r 1a2a00e78665 idlefw/rom/idlefw_resources.iby --- a/idlefw/rom/idlefw_resources.iby Tue Jan 26 12:11:15 2010 +0200 +++ b/idlefw/rom/idlefw_resources.iby Tue Feb 02 00:23:10 2010 +0200 @@ -11,7 +11,7 @@ * * Contributors: * -* Description: Image description file for ActiveIdle2 localisable resources. +* Description: Image description file for ActiveIdle3 localisable resources. * */ @@ -21,18 +21,13 @@ #ifdef RD_CUSTOMIZABLE_AI -#ifndef ACTIVEIDLE2_RESOURCES_IBY -#define ACTIVEIDLE2_RESOURCES_IBY - #include -data=DATAZ_\APP_RESOURCE_DIR\ailaunch.rsc APP_RESOURCE_DIR\ailaunch.rsc +data=DATAZ_\APP_RESOURCE_DIR\homescreen.rsc APP_RESOURCE_DIR\homescreen.rsc // Content publishing plug-in resources data=DATAZ_\APP_RESOURCE_DIR\aidevstaplgres.rsc APP_RESOURCE_DIR\aidevstaplgres.rsc -#endif // ACTIVEIDLE2_RESOURCES_IBY - #endif // RD_CUSTOMIZABLE_AI #endif // ACTIVEIDLE3_RESOURCES_IBY diff -r ff572005ac23 -r 1a2a00e78665 idlefw/src/framework/ailaunch.rss --- a/idlefw/src/framework/ailaunch.rss Tue Jan 26 12:11:15 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,62 +0,0 @@ -/* -* Copyright (c) 2006 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" -* 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: Resource definitions for project ailaunch -* -*/ - - -NAME AIFW - -#include -#include -#include - -#include -#include -#include -#include -#include - -#include - -RESOURCE RSS_SIGNATURE { } - -RESOURCE TBUF { buf=""; } - -// --------------------------------------------------------------------------- -// r_ailaunch_localisable_app_info -// It defines localisable app info of Active Idle 2 -// --------------------------------------------------------------------------- -// -RESOURCE LOCALISABLE_APP_INFO r_ailaunch_localisable_app_info - { - short_caption = qtn_apps_idle_grid; - caption_and_icon = - CAPTION_AND_ICON_INFO - { - caption = qtn_apps_idle_grid; - -#ifdef __SCALABLE_ICONS - - number_of_icons = 1; - icon_file = APP_RESOURCE_DIR"\\ailaunch_aif.mif"; - -#else - - number_of_icons = 1; - icon_file = APP_RESOURCE_DIR"\\ailaunch_aif.mbm"; - -#endif // __SCALABLE_ICONS - }; - } diff -r ff572005ac23 -r 1a2a00e78665 idlefw/src/framework/ailaunch_reg.rss --- a/idlefw/src/framework/ailaunch_reg.rss Tue Jan 26 12:11:15 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,50 +0,0 @@ -/* -* Copyright (c) 2002-2005 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" -* 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: -* -*/ - - -// ========== INCLUDE FILES =================================================== - -#include -#include -#include -#include - -// ========== CONSTANTS ======================================================= - -UID2 KUidAppRegistrationResourceFile -UID3 AI_UID3_AIFW_EXE // Define your application UID here - -// ========== RESOURCE DEFINITIONS ============================================ - -// ---------------------------------------------------------------------------- -// -// -// ---------------------------------------------------------------------------- -// -RESOURCE APP_REGISTRATION_INFO - { - app_file = "ailaunch"; - localisable_resource_file = APP_RESOURCE_DIR"\\ailaunch"; - localisable_resource_id = R_AILAUNCH_LOCALISABLE_APP_INFO; - -#ifdef RD_BOOT_CUSTOMIZABLE_AI - // When Active Idle starts in boot, hide the app icon from Application Shell - hidden = KAppIsHidden; -#endif - } - -// End of File. diff -r ff572005ac23 -r 1a2a00e78665 idlefw/src/framework/homescreen.rss --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlefw/src/framework/homescreen.rss Tue Feb 02 00:23:10 2010 +0200 @@ -0,0 +1,62 @@ +/* +* Copyright (c) 2006 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" +* 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: Resource definitions for project homescreen +* +*/ + + +NAME AIFW + +#include +#include +#include + +#include +#include +#include +#include +#include + +#include + +RESOURCE RSS_SIGNATURE { } + +RESOURCE TBUF { buf=""; } + +// --------------------------------------------------------------------------- +// r_homescreen_localisable_app_info +// It defines localisable app info of Active Idle 3 +// --------------------------------------------------------------------------- +// +RESOURCE LOCALISABLE_APP_INFO r_homescreen_localisable_app_info + { + short_caption = qtn_apps_idle_grid; + caption_and_icon = + CAPTION_AND_ICON_INFO + { + caption = qtn_apps_idle_grid; + +#ifdef __SCALABLE_ICONS + + number_of_icons = 1; + icon_file = APP_RESOURCE_DIR"\\homescreen_aif.mif"; + +#else + + number_of_icons = 1; + icon_file = APP_RESOURCE_DIR"\\homescreen_aif.mbm"; + +#endif // __SCALABLE_ICONS + }; + } diff -r ff572005ac23 -r 1a2a00e78665 idlefw/src/framework/homescreen_reg.rss --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlefw/src/framework/homescreen_reg.rss Tue Feb 02 00:23:10 2010 +0200 @@ -0,0 +1,50 @@ +/* +* Copyright (c) 2002-2005 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" +* 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: +* +*/ + + +// ========== INCLUDE FILES =================================================== + +#include +#include +#include +#include + +// ========== CONSTANTS ======================================================= + +UID2 KUidAppRegistrationResourceFile +UID3 AI_UID3_AIFW_EXE // Define your application UID here + +// ========== RESOURCE DEFINITIONS ============================================ + +// ---------------------------------------------------------------------------- +// +// +// ---------------------------------------------------------------------------- +// +RESOURCE APP_REGISTRATION_INFO + { + app_file = "homescreen"; + localisable_resource_file = APP_RESOURCE_DIR"\\homescreen"; + localisable_resource_id = R_HOMESCREEN_LOCALISABLE_APP_INFO; + +#ifdef RD_BOOT_CUSTOMIZABLE_AI + // When Active Idle starts in boot, hide the app icon from Application Shell + hidden = KAppIsHidden; +#endif + } + +// End of File.