--- a/contentcontrolsrv/ccsrv/src/ccsrv.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/contentcontrolsrv/ccsrv/src/ccsrv.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -251,7 +251,7 @@
CCcSrv::TCcProvider provider;
provider.iId = aProvider;
provider.iSession = aSession;
- iProviders.AppendL( provider );
+ iProviders.Append( provider );
// Register possible active observers
for ( TUint32 i = 0; i < iObservers.Count(); i++ )
@@ -283,7 +283,7 @@
CCcSrv::TCcObserver observer;
observer.iProviderId = aProvider;
observer.iObserver = aSession->Id();
- iObservers.AppendL( observer );
+ iObservers.Append( observer );
}
// -----------------------------------------------------------------------------
--- a/contentpublishingsrv/contentpublishingutils/contentpublishingdebug/src/cpdebug.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/contentpublishingsrv/contentpublishingutils/contentpublishingdebug/src/cpdebug.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -167,15 +167,12 @@
RDebug::Printf( "CPS Client::Request %s Parameters: \n", aStringParam );
for ( TInt i = 0; i < aInParamList.Count( ); i++ )
{
- TRAP_IGNORE(
- {
- TLiwGenericParam tempParam;
- tempParam.PushL();
- aInParamList.AtL(i ,tempParam);
- Dump( tempParam.Value() );
- CleanupStack::Pop(&tempParam);
- tempParam.Reset();
- } );
+ TLiwGenericParam tempParam;
+ tempParam.PushL();
+ TRAP_IGNORE( aInParamList.AtL(i ,tempParam) );
+ Dump( tempParam.Value() );
+ CleanupStack::Pop(&tempParam);
+ tempParam.Reset();
}
}
Binary file homescreenpluginsrv/conf/hsps.confml has changed
Binary file homescreenpluginsrv/conf/hsps_200159c9.crml has changed
Binary file homescreenpluginsrv/conf/hsps_qhd.confml has changed
--- a/homescreenpluginsrv/conf/hsps_vga.confml Wed Sep 15 12:32:36 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,44 +0,0 @@
-<?xml version="1.0" encoding="UTF-16"?>
-<configuration xmlns="http://www.s60.com/xml/confml/1" name="hsps">
- <feature ref="KhspsThemeStatusRepositoryUid" name="KhspsThemeStatusRepositoryUid">
- <desc>CenRep keys for Homescreenpluginsrv</desc>
- <setting ref="KhspsAI" name="KhspsAI" type="int" required="true">
- <desc>Holds UID of an active application configuration plugin for AI3 client</desc>
- </setting>
- <setting ref="KhspsAI3TestApp" name="KhspsAI3TestApp" type="int" required="true">
- <desc>Holds UID of an active application configuration plugin for EUnit client</desc>
- </setting>
- <setting ref="KhspsDeviceLanguage" name="KhspsDeviceLanguage" type="int" required="true">
- <desc>Holds device language ID from previous startup</desc>
- </setting>
- <setting ref="KhspsFilesInstalled" name="KhspsFilesInstalled" type="string" required="true">
- <desc>FW version or empty if plugins should be reinstalled in next start up</desc>
- </setting>
- <setting ref="KhspsCheckConfigurations" name="KhspsCheckConfigurations" type="int">
- <desc>Holds information whether configuration states must be checked</desc>
- </setting>
- <setting ref="KhspsSecurityControlAccessList" name="KhspsSecurityControlAccessList" type="string" readOnly="true">
- <desc>Access control for clients which are missing the capablities</desc>
- </setting>
- </feature>
- <data>
- <KhspsThemeStatusRepositoryUid>
- <KhspsAI>536999055</KhspsAI>
- <KhspsAI3TestApp>536916224</KhspsAI3TestApp>
- <KhspsDeviceLanguage>1</KhspsDeviceLanguage>
- <KhspsFilesInstalled></KhspsFilesInstalled>
- <KhspsCheckConfigurations>0</KhspsCheckConfigurations>
- <KhspsSecurityControlAccessList>0x102750F0;0x200159C6;0x20000FB1;0x10005A32;0x100058EC;0x200159c5;0x200255FF;</KhspsSecurityControlAccessList>
- </KhspsThemeStatusRepositoryUid>
- </data>
- <rfs>
- <KhspsThemeStatusRepositoryUid>
- <KhspsAI>true</KhspsAI>
- <KhspsAI3TestApp>true</KhspsAI3TestApp>
- <KhspsDeviceLanguage>true</KhspsDeviceLanguage>
- <KhspsFilesInstalled>true</KhspsFilesInstalled>
- <KhspsCheckConfigurations>true</KhspsCheckConfigurations>
- <KhspsSecurityControlAccessList>false</KhspsSecurityControlAccessList>
- </KhspsThemeStatusRepositoryUid>
- </rfs>
-</configuration>
--- a/homescreenpluginsrv/group/bld.inf Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreenpluginsrv/group/bld.inf Wed Oct 13 14:53:46 2010 +0300
@@ -49,13 +49,9 @@
// Generic configuration interface for component cenrep settings
-#if defined(FF_LAYOUT_480_640_TOUCH_VGA4) || defined(FF_LAYOUT_640_480_TOUCH_VGA4)
-../conf/hsps_vga.confml APP_LAYER_CONFML(hsps.confml)
-#else
-../conf/hsps_qhd.confml APP_LAYER_CONFML(hsps.confml)
-#endif
+../conf/hsps.confml APP_LAYER_CONFML(hsps.confml)
+../conf/hsps_200159c9.crml APP_LAYER_CRML(hsps_200159c9.crml)
-../conf/hsps_200159c9.crml APP_LAYER_CRML(hsps_200159c9.crml)
// Exports for SAPI impl
../inc/hspsdomattribute.h MW_LAYER_PLATFORM_EXPORT_PATH(hspsdomattribute.h)
--- a/homescreenpluginsrv/hspsmanager/inc/hspsconfiguration.h Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreenpluginsrv/hspsmanager/inc/hspsconfiguration.h Wed Oct 13 14:53:46 2010 +0300
@@ -54,7 +54,7 @@
// Options for the KConfigurationAttrLocking
_LIT8( KConfLockingLocked, "locked" ); // Locked state
-_LIT8( KConfLockingPermanent, "permanent" ); // Permanent state (not removable, not movable)
+_LIT8( KConfLockingRemovable, "removable" ); // Removable state
_LIT8( KConfLockingNone, "none" ); // Default
// Control element
--- a/homescreenpluginsrv/hspsmanager/inc/hspsmaintenancehandler.h Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreenpluginsrv/hspsmanager/inc/hspsmaintenancehandler.h Wed Oct 13 14:53:46 2010 +0300
@@ -725,16 +725,6 @@
ChspsODT& aOdt );
/**
- * Activates default configuration defined for the application
- * @since S60 5.2
- * @param aHeader application which default configuration is activated
- * @param aOdt activated application configuration
- */
- void ActivateDefaultAppConfL(
- const ChspsODT& aHeader,
- ChspsODT& aOdt );
-
- /**
* HandleDefinitionRespositoryEventL
*
* @since S60 5.0
@@ -752,28 +742,6 @@
RArray<ThspsRepositoryInfo>& aNotificationParams);
/**
- * RemoveAppConfFromRepositoryL
- * Removes application confguration from definition repository
- * @since S60 5.2
- * @param aOdt application configuration to be removed
- * @param aNotificationParams notifications need to be sent after removal
- */
- void RemoveAppConfFromRepositoryL(
- const ChspsODT& aOdt,
- RArray<ThspsRepositoryInfo>& aNotificationParams );
-
- /**
- * RemovePluginConfFromRepositoryL
- * Removes plugin confguration from definition repository
- * @since S60 5.2
- * @param aOdt plugin configuration to be removed
- * @param aNotificationParams notifications need to be sent after removal
- */
- void RemovePluginConfFromRepositoryL(
- const ChspsODT& aOdt,
- RArray<ThspsRepositoryInfo>& aNotificationParams );
-
- /**
* InvalidateUninstalledPluginInstancesL
* Removes uninstalled plugin instances from an inactive
* application configuration by changing them to error state.
--- a/homescreenpluginsrv/hspsmanager/src/hspsclientrequesthandler.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreenpluginsrv/hspsmanager/src/hspsclientrequesthandler.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -741,13 +741,7 @@
}
else
{
- // Child counts should match, set plugin to Error state
- const TInt pluginUid = hspsServerUtil::GetPluginUid( parentNode ).iUid;
- __ASSERT_DEBUG( pluginUid > 0, User::Leave( KErrCorrupt ) );
- AddErrorConfigurationL(
- appDom,
- *parentNode,
- pluginUid );
+ error = KErrCorrupt;
}
}
else
--- a/homescreenpluginsrv/hspsmanager/src/hspsinstallationhandler.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreenpluginsrv/hspsmanager/src/hspsinstallationhandler.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -395,22 +395,12 @@
TRAPD( err, DoInstallThemeL(aManifestFileName) );
if( !err )
{
- // correct headerdata is in iHeaderData set by CheckHeaderL(), check space
- const TUint bytesRequired = iHeaderData->Des().Length();
- const TUint bytesAllocated = aHeaderData.MaxLength();
- if( bytesRequired <= bytesAllocated )
- {
- aHeaderData = iHeaderData->Des();
-
- // Set next phase
- iInstallationPhase = EhspsPhaseCleanup;
- ret = EhspsInstallThemeSuccess;
- }
- else
- {
- err = KErrOverflow;
- iInstallationPhase = EhspsPhaseIdle;
- }
+ // correct headerdata is in iHeaderData set by CheckHeaderL()
+ aHeaderData = iHeaderData->Des();
+
+ // Set next phase
+ iInstallationPhase = EhspsPhaseCleanup;
+ ret = EhspsInstallThemeSuccess;
}
else
{
@@ -1598,8 +1588,8 @@
KNullDesC(),
(TLanguage)( fullODT->OdtLanguage() ) );
- notifications.AppendL( info );
- }
+ notifications.Append( info );
+ }
CleanupStack::PopAndDestroy(); // pluginIds.
CleanupStack::PopAndDestroy( fullODT );
@@ -2270,11 +2260,11 @@
TInt drive = hspsServerUtil::GetEmmcDrivePath( iFsSession );
if ( drive != KErrNotFound )
{
- driveArray.AppendL( drive );
+ driveArray.Append( drive );
}
- driveArray.AppendL( EDriveC );
- driveArray.AppendL( EDriveZ );
+ driveArray.Append( EDriveC );
+ driveArray.Append( EDriveZ );
FindResourceFilesL( aPath, ETrue, driveArray, systemEpocLanguageCodes );
--- a/homescreenpluginsrv/hspsmanager/src/hspsmaintenancehandler.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreenpluginsrv/hspsmanager/src/hspsmaintenancehandler.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -319,7 +319,6 @@
CleanupStack::PopAndDestroy(headerdata);
ThspsRepositoryInfo info( EhspsODTActivated );
- info.iAppUid = odt->RootUid();
iDefinitionRepository.RegisterNotification( info );
}
}
@@ -1866,7 +1865,7 @@
TInt pluginCount = pluginsNode->ChildNodes().Length();
for( TInt pluginIndex=0; pluginIndex < pluginCount; pluginIndex++ )
{
- nodeArray.AppendL( (ChspsDomNode*)pluginsNode->ChildNodes().Item( pluginIndex ) );
+ nodeArray.Append( (ChspsDomNode*)pluginsNode->ChildNodes().Item( pluginIndex ) );
}
// Remove the nodes and related resources
@@ -3210,8 +3209,7 @@
if( !( aSetMask.Flags() & EhspsThemeStatusLicenceeDefault ) )
{
RArray<ThspsRepositoryInfo> notifParams;
- CleanupClosePushL( notifParams );
-
+
if( !iDefinitionRepository.Locked() )
{
iDefinitionRepository.Lock();
@@ -3223,11 +3221,14 @@
TInt error( KErrNone );
if ( aSetMask.ConfigurationType() != EhspsAppConfiguration )
{
- TRAP( error, RemovePluginConfFromRepositoryL( aSetMask, notifParams ) );
+ // Fix plugin instances and get notifications from valid cases
+ TRAP( error, RemovePluginFromAppConfsL( aSetMask, notifParams ) );
}
- else
+
+ if( !error )
{
- TRAP( error, RemoveAppConfFromRepositoryL( aSetMask, notifParams ) );
+ // Remove the actual plugin from file system
+ TRAP( error, RemoveThemeL( aSetMask ) );
}
if( !error )
@@ -3256,7 +3257,7 @@
}
}
- CleanupStack::PopAndDestroy( ¬ifParams );
+ notifParams.Close();
}
return ret;
@@ -3271,7 +3272,7 @@
RArray<ThspsRepositoryInfo>& aNotificationParams )
{
__ASSERT_DEBUG( aOdt.ThemeUid(), User::Leave( KErrArgument ) );
-
+
// Loop application configurations
const TInt count = iHeaderListCache.Count();
for ( TInt i = 0; i < count; i++ )
@@ -3359,7 +3360,7 @@
lastNotification,
aOdt.ThemeFullName(),
(TLanguage)( aOdt.OdtLanguage() ) );
- aNotificationParams.AppendL(info);
+ aNotificationParams.Append(info);
}
#ifdef HSPS_LOG_ACTIVE
if( iLogBus )
@@ -3389,59 +3390,18 @@
ETrue,
aOdt.ThemeFullName(),
(TLanguage)( aOdt.OdtLanguage() ) );
- aNotificationParams.AppendL(info);
+ aNotificationParams.Append(info);
}
}
+ pluginIds.Close();
CleanupStack::PopAndDestroy( 2, appOdt ); // appOdt, pluginIds
appOdt = NULL;
} // app configuration
} // header loop
- }
-
-// -----------------------------------------------------------------------------
-// RemoveAppConfFromRepositoryL
-// -----------------------------------------------------------------------------
-//
-void ChspsMaintenanceHandler::RemoveAppConfFromRepositoryL(
- const ChspsODT& aOdt,
- RArray<ThspsRepositoryInfo>& /* aNotificationParams */ )
- {
- __ASSERT_DEBUG( aOdt.ThemeUid(), User::Leave( KErrArgument ) );
-
- ChspsODT* activeAppConf = ChspsODT::NewL();
- CleanupStack::PushL( activeAppConf );
- iThemeServer.GetActivateAppConfigurationL( aOdt.RootUid(), *activeAppConf );
- if ( aOdt.ThemeUid() == activeAppConf->ThemeUid() )
- {
- // Active application configuration removed
- ActivateDefaultAppConfL( aOdt, *activeAppConf );
- }
-
- CleanupStack::PopAndDestroy( activeAppConf );
-
- // Remove the actual application configuration from file system
- RemoveThemeL( aOdt );
-
- }
-
-// -----------------------------------------------------------------------------
-// RemovePluginConfFromRepositoryL
-// -----------------------------------------------------------------------------
-//
-void ChspsMaintenanceHandler::RemovePluginConfFromRepositoryL(
- const ChspsODT& aOdt,
- RArray<ThspsRepositoryInfo>& aNotificationParams )
- {
- __ASSERT_DEBUG( aOdt.ThemeUid(), User::Leave( KErrArgument ) );
-
- // Fix plugin instances and get notifications from valid cases
- RemovePluginFromAppConfsL( aOdt, aNotificationParams );
-
- // Remove the actual plugin configuration from file system
- RemoveThemeL( aOdt );
+
}
// -----------------------------------------------------------------------------
@@ -3555,8 +3515,7 @@
User::LeaveIfError( iDefinitionRepository.GetOdtL( *odt ) );
RArray<ThspsRepositoryInfo> notifParams;
- CleanupClosePushL( notifParams );
-
+
TRAP( errorCode, UpdatePluginFromAppConfsL( *odt, notifParams ));
if( errorCode )
@@ -3581,8 +3540,8 @@
}
}
+ notifParams.Close();
- CleanupStack::PopAndDestroy( ¬ifParams );
CleanupStack::PopAndDestroy( odt );
}
@@ -3658,7 +3617,7 @@
status,
aOdt.ThemeFullName(),
(TLanguage)( aOdt.OdtLanguage() ) );
- aNotificationParams.AppendL(info);
+ aNotificationParams.Append(info);
}
}
@@ -3666,6 +3625,7 @@
CleanupStack::PopAndDestroy( odt );
}
}
+
}
}
// -----------------------------------------------------------------------------
@@ -4547,8 +4507,28 @@
// If active application configuration is not "LicenceeRestorable"
if ( !(aHeader->Flags() & EhspsThemeStatusLicenceeRestorable) )
{
- // Try to activate default configuation
- ActivateDefaultAppConfL( *aHeader, aOdt );
+ // Try to activate a configuation with the LicenceeRestorable status
+ ChspsODT* searchMask = ChspsODT::NewL();
+ CleanupStack::PushL( searchMask );
+ searchMask->SetRootUid( aHeader->RootUid() );
+ searchMask->SetFamily( aHeader->Family() );
+ searchMask->SetFlags( EhspsThemeStatusLicenceeRestorable );
+ TInt pos( 0 );
+ iThemeServer.GetConfigurationHeader( *searchMask, aHeader, pos );
+ if ( aHeader )
+ {
+ // Activate licensee restorable configuration
+ iThemeServer.ActivateThemeL( *aHeader, aOdt );
+ ThspsRepositoryInfo info( EhspsODTActivated );
+ iDefinitionRepository.RegisterNotification( info );
+ }
+ else
+ {
+ // Licensee restorable configuration not found. There must be
+ // at least one licensee restorable configuration per application
+ User::Leave( KErrNotFound );
+ }
+ CleanupStack::PopAndDestroy( searchMask );
}
else
{
@@ -4558,39 +4538,6 @@
}
// -----------------------------------------------------------------------------
-// ChspsMaintenanceHandler::ActivateDefaultAppConfL
-// (other items were commented in a header).
-// -----------------------------------------------------------------------------
-//
-void ChspsMaintenanceHandler::ActivateDefaultAppConfL(
- const ChspsODT& aHeader,
- ChspsODT& aOdt )
- {
- ChspsODT* searchMask = ChspsODT::NewL();
- CleanupStack::PushL( searchMask );
- searchMask->SetRootUid( aHeader.RootUid() );
- searchMask->SetFamily( aHeader.Family() );
- searchMask->SetFlags( EhspsThemeStatusLicenceeRestorable );
-
- ChspsODT* defaultAppConf( NULL );
- TInt pos( 0 );
- iThemeServer.GetConfigurationHeader( *searchMask, defaultAppConf, pos );
- if ( defaultAppConf )
- {
- // Activate licensee restorable configuration
- iThemeServer.ActivateThemeL( *defaultAppConf, aOdt );
- }
- else
- {
- // Licensee restorable configuration not found. There must be
- // at least one licensee restorable configuration per application
- User::Leave( KErrNotFound );
- }
-
- CleanupStack::PopAndDestroy( searchMask );
- }
-
-// -----------------------------------------------------------------------------
// ChspsMaintenanceHandler::AddErrorConfigurationL()
// -----------------------------------------------------------------------------
//
@@ -4894,12 +4841,8 @@
ChspsDomAttribute* attr =
static_cast<ChspsDomAttribute*>( attrList.FindByName( KConfigurationAttrLocking ) );
if( attr )
- {
- if( attr->Value().CompareF( KConfLockingLocked ) == 0 ||
- attr->Value().CompareF( KConfLockingPermanent ) == 0 )
- {
- isLocked = ETrue;
- }
+ {
+ isLocked = ( attr->Value().CompareF( KConfLockingLocked ) == 0 );
}
return isLocked;
@@ -4963,7 +4906,7 @@
if( !isLocked || foundLocked )
{
// Mark for removal
- nodeArray.AppendL( pluginNode );
+ nodeArray.Append( pluginNode );
}
else
{
--- a/homescreenpluginsrv/hspsmanager/src/hspsserverutil.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreenpluginsrv/hspsmanager/src/hspsserverutil.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -951,10 +951,8 @@
void hspsServerUtil::FindUniquePluginsL(
ChspsODT& aOdt,
RArray<TInt>& aPluginArray )
- {
- aPluginArray.Reset();
- CleanupClosePushL( aPluginArray );
-
+ {
+ aPluginArray.Reset();
ChspsDomDocument& dom = aOdt.DomDocument();
ChspsDomDepthIterator* iter = ChspsDomDepthIterator::NewL( *dom.RootNode() );
CleanupStack::PushL( iter );
@@ -962,32 +960,32 @@
ChspsDomNode* node = iter->First();
ChspsDomNode* prevNode = NULL;
while( node && prevNode != node )
- {
- const TDesC8& name = node->Name();
+ {
+ const TDesC8& name = node->Name();
- // Plugin element was found
- if ( name == KPluginElement )
- {
- ChspsDomList& attrList = node->AttributeList();
- ChspsDomAttribute* uidAttr = static_cast<ChspsDomAttribute*>( attrList.FindByName(KPluginAttrUid) );
- if ( uidAttr )
- {
- // Convert from hex to int
- const TUid pluginUid = ConvertDescIntoUid( uidAttr->Value() );
- if ( pluginUid.iUid > 0 )
- {
- TBool isUnique = ETrue;
- for( TInt i=0; isUnique && i<aPluginArray.Count();i++ )
- {
- if ( aPluginArray[i] == pluginUid.iUid )
- {
- isUnique=EFalse;
- }
- }
- if ( isUnique )
- {
- aPluginArray.AppendL( pluginUid.iUid );
- }
+ // Plugin element was found
+ if ( name == KPluginElement )
+ {
+ ChspsDomList& attrList = node->AttributeList();
+ ChspsDomAttribute* uidAttr = static_cast<ChspsDomAttribute*>( attrList.FindByName(KPluginAttrUid) );
+ if ( uidAttr )
+ {
+ // Convert from hex to int
+ const TUid pluginUid = ConvertDescIntoUid( uidAttr->Value() );
+ if ( pluginUid.iUid > 0 )
+ {
+ TBool isUnique = ETrue;
+ for( TInt i=0; isUnique && i<aPluginArray.Count();i++ )
+ {
+ if ( aPluginArray[i] == pluginUid.iUid )
+ {
+ isUnique=EFalse;
+ }
+ }
+ if ( isUnique )
+ {
+ aPluginArray.Append( pluginUid.iUid );
+ }
}
}
}
@@ -995,10 +993,8 @@
prevNode = node;
node = iter->NextL();
}
-
- CleanupStack::PopAndDestroy( iter );
- CleanupStack::Pop( &aPluginArray );
- }
+ CleanupStack::PopAndDestroy( iter );
+}
//----------------------------------------------------------------------------
// CHspsServiceUtilities::HexString2Uint
@@ -1280,9 +1276,10 @@
TFileName file;
file.Append( aDirName );
file.Append( fileEntry.iName );
- aFiles.AppendL( file );
+ aFiles.Append( file );
}
CleanupStack::PopAndDestroy( fileList );
+
CleanupStack::PopAndDestroy(); // fs
}
@@ -2048,13 +2045,6 @@
{
aFs.SetSessionToPrivate( drive );
}
-// When Emmc drive is not present in emulator it is replaced by D drive
-#ifdef __WINSCW__
- else
- {
- aFs.SetSessionToPrivate( EDriveD );
- }
-#endif
}
else
{
@@ -2216,7 +2206,7 @@
// Find files from the subdirectory and the drive
RArray<TInt> driveArray;
CleanupClosePushL( driveArray );
- driveArray.AppendL( aDriveArray[driveIndex] );
+ driveArray.Append( aDriveArray[driveIndex] );
FindResourcesL( aFs, driveArray, file, aFileArray, NULL );
CleanupStack::PopAndDestroy( &driveArray );
}
--- a/homescreenpluginsrv/hspsmanager/src/hspsthemeserver.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreenpluginsrv/hspsmanager/src/hspsthemeserver.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -624,8 +624,7 @@
if( aRepositoryInfo.iEventType & EhspsODTUpdated ||
aRepositoryInfo.iEventType & EhspsODTModified ||
- aRepositoryInfo.iEventType & EhspsPluginReplaced ||
- aRepositoryInfo.iEventType == EhspsODTActivated )
+ aRepositoryInfo.iEventType & EhspsPluginReplaced )
{
SetResourceFileCopyRequired( aRepositoryInfo.iAppUid );
}
@@ -3643,7 +3642,7 @@
}
if ( !alreadyIncluded )
{
- notificationTargets.AppendL( header );
+ notificationTargets.Append( header );
// Check if active configuration supports the current family
TBool updateRequired = ETrue;
--- a/homescreenpluginsrv/hspsmanager/src/hspsthemeserversession.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreenpluginsrv/hspsmanager/src/hspsthemeserversession.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -781,7 +781,7 @@
ChspsODT& aAppODT,
RArray<TInt>& aUidArray )
{
- aUidArray.Reset();
+ aUidArray.Reset();
const TInt resourceCount = aAppODT.ResourceCount();
for( TInt resourceIndex = 0; resourceIndex < resourceCount; resourceIndex++ )
{
@@ -790,9 +790,9 @@
if ( uid > 0 &&
aUidArray.Find( uid ) == KErrNotFound )
{
- aUidArray.AppendL( uid );
+ aUidArray.Append( uid );
}
- }
+ }
}
// -----------------------------------------------------------------------------
--- a/homescreensrv_plat/ai_variation_api/inc/activeidle2domaincrkeys.h Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreensrv_plat/ai_variation_api/inc/activeidle2domaincrkeys.h Wed Oct 13 14:53:46 2010 +0300
@@ -128,9 +128,4 @@
*/
const TUint32 KAIActiveViewPluginId = 0x00000852;
-/**
- * Key id for finger follow view switching support
- */
-const TUint32 KAIFingerFollowSupport = 0x00000853;
-
#endif // __AI2INTERNALCRKEYS_H__
--- a/homescreensrv_plat/hs_widget_publisher_api/src/hswidgetitem.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreensrv_plat/hs_widget_publisher_api/src/hswidgetitem.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -27,6 +27,7 @@
HsWidgetItem::HsWidgetItem(std::string& aItemName, std::string& aValue):
mItemName(aItemName), mItemString(aValue), mItemInt(0),
mIsString(true),mTrigger(false)
+
{
}
@@ -35,8 +36,7 @@
// ---------------------------------------------------------------------------
//
HsWidgetItem::HsWidgetItem( std::string& aItemName, int aValue ):
- mItemName(aItemName), mItemString(), mItemInt(aValue),
- mIsString(false), mTrigger(false)
+ mItemName(aItemName), mItemString(), mItemInt(aValue), mIsString(false)
{
}
--- a/homescreensrv_plat/hs_widget_publisher_api/tsrc/src/TestHspApiBlocks.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreensrv_plat/hs_widget_publisher_api/tsrc/src/TestHspApiBlocks.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -630,7 +630,7 @@
delete mHSPApi;
- if ( count != 4 )
+ if ( count != 1 )
{
err = KErrGeneral;
}
@@ -724,7 +724,7 @@
CLiwGenericParamList* res = GetListL( contentType, identifier, widgetName );
TInt count = ExtractItemCountL( *res );
- if ( count != 4 )
+ if ( count != 1 )
{
err = KErrGeneral;
}
@@ -770,7 +770,7 @@
CLiwGenericParamList* res = GetListL( contentType, identifier, widgetName );
TInt count = ExtractItemCountL( *res );
- if ( count != 4 )
+ if ( count != 1 )
{
err = KErrGeneral;
}
@@ -816,7 +816,7 @@
CLiwGenericParamList* res = GetListL( contentType, identifier, widgetName );
TInt count = ExtractItemCountL( *res );
- if ( count != 4 )
+ if ( count != 1 )
{
err = KErrGeneral;
}
--- a/homescreensrv_plat/sapi_homescreenplugin/hspsservice/src/hspsconfigurationservice.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreensrv_plat/sapi_homescreenplugin/hspsservice/src/hspsconfigurationservice.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -422,7 +422,7 @@
for(TInt i=0; i < iNotifyParams->iCount; i++ )
{
- iPluginIds.AppendL( aParams.iPluginIds[i] );
+ iPluginIds.Append( aParams.iPluginIds[i] );
}
iNotifyParams->SetNameL(aParams.Name());
--- a/homescreensrv_plat/sapi_homescreenplugin/src/hspsliwutilities.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreensrv_plat/sapi_homescreenplugin/src/hspsliwutilities.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -1057,7 +1057,7 @@
}
if ( aItemMask & CHspsLiwUtilities::EPluginMapLocked )
{
- //Add plugin locked status - locked/permanent/none(default)
+ //Add plugin locked status - locked/removable/none(default)
AppendAttributeToMapL( aMap,
attrList,
KConfigurationAttrLockingStatus,
--- a/homescreensrv_plat/sapi_homescreenplugin/tsrc/hspsconfigurationif/group/mt_hspsconfigurationif.mmp Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreensrv_plat/sapi_homescreenplugin/tsrc/hspsconfigurationif/group/mt_hspsconfigurationif.mmp Wed Oct 13 14:53:46 2010 +0300
@@ -61,6 +61,5 @@
LIBRARY hspsclient.lib
LIBRARY hspsodt.lib
LIBRARY hspsresult.lib
-LIBRARY PlatformEnv.lib // for DriveInfo
// End of file
--- a/homescreensrv_plat/sapi_homescreenplugin/tsrc/hspsconfigurationif/src/mt_hspsconfigurationif.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/homescreensrv_plat/sapi_homescreenplugin/tsrc/hspsconfigurationif/src/mt_hspsconfigurationif.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -23,7 +23,6 @@
#include <eikenv.h>
#include <centralrepository.h>
#include <bautils.h>
-#include <driveinfo.h>
#include "mt_hspsconfigurationif.h"
#include "mt_hspsliwlistprinter.h"
#include "mt_hspsinstallationservice.h"
@@ -133,38 +132,8 @@
_LIT( KMinimalResourceFile4, "c:\\private\\20000fb1\\2456\\270513751\\536916225\\1.0\\sources\\picture.jpeg" );
_LIT( KFinnishMifLogo, "c:\\private\\20000fb1\\2456\\270513751\\536916274\\1.0\\sources\\dummy.mif" );
-const TInt16 KletterA = 'a'; // ASCII code for 'a'
-
// ======== LOCAL FUNCTIONS ====================================================
-//------------------------------------------------------------------------------
-// EMMC drive finder - from hspsServerUtil
-//------------------------------------------------------------------------------
-TInt GetEmmcDrivePath( )
- {
- RFs fs;
- if ( fs.Connect() != KErrNone )
- {
- return KErrNotFound;
- }
- TInt drive = KErrNotFound;
- if ( DriveInfo::GetDefaultDrive(
- DriveInfo::EDefaultMassStorage, drive ) == KErrNone )
- {
- TUint status;
- if ( DriveInfo::GetDriveStatus( fs, drive, status ) == KErrNone )
- {
- if ( status & DriveInfo::EDriveInternal )
- {
- fs.Close();
- return drive;
- }
- }
- }
- fs.Close();
- return KErrNotFound;
- }
-
// ======== MEMBER FUNCTIONS ===================================================
//------------------------------------------------------------------------------
@@ -3240,15 +3209,6 @@
void MT_CHSPSConfigurationIf::Customization_1_L()
{
// Pre conditions
- // There is minimal configuration and a D drive present in emulator
- // Outcome:
- // The original configuration file is bypassed by a new one placed on the D
- // drive
- // Possible problems:
- // There is no E drive (EMMC) in emulator. The data are copied to the D
- // drive. In case there is the E drive,please check all possible references
- // to the D drive and change, if needed. This is important for HW testing.
- // Remark: hspsServerUtil::FindFile() determines which drives are searched.
EUNIT_PRINT( _L8( "Pre conditions: Set Active configuration Minimal" ) );
SetActiveConfigurationL( KHSPSTestAppUid, KHSPSActiveConfMinimal );
@@ -3259,24 +3219,13 @@
// Simulate customization by copying configuration files to D drive ("ROM" stuff is on C)
CFileMan* fileManager = CFileMan::NewL( iFileserver );
CleanupStack::PushL( fileManager );
-
- // Find MMC drive, if not found copy it to the D drive
- TInt drive = GetEmmcDrivePath();
- if ( drive == KErrNotFound )
- {
- drive = EDriveD; // Set D drive
- }
- _LIT( Kconfigdir, "d:\\data\\mt_hsps\\installed_widget\\widgetconfiguration.xml" );
- TBuf<200> confdir;
- confdir.Append( Kconfigdir );
- confdir[0] = ( TInt16 )drive + KletterA; // see ACII table
User::LeaveIfError(
fileManager->Copy(
- _L( "c:\\data\\mt_hsps\\installed_widget\\widgetconfiguration_customized.xml" ),
- confdir,
- CFileMan::ERecurse|CFileMan::EOverWrite )
+ _L( "c:\\data\\mt_hsps\\installed_widget\\widgetconfiguration_customized.xml" ),
+ _L( "d:\\data\\mt_hsps\\installed_widget\\widgetconfiguration.xml" ),
+ CFileMan::ERecurse|CFileMan::EOverWrite
+ )
);
-
CleanupStack::PopAndDestroy( fileManager );
MT_CHspsInstallationService* installationService = MT_CHspsInstallationService::NewL();
Binary file idlefw/conf/activeidle2.confml has changed
Binary file idlefw/conf/activeidle2_10275102.crml has changed
--- a/idlefw/hslaunch/src/hslaunch.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/hslaunch/src/hslaunch.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -21,6 +21,7 @@
// ========================= DECLARATIONS ==================================
_LIT( KHsExeName, "homescreen.exe" );
+_LIT( KHsProcessName, "Home screen" );
const TInt KSleepOnRetry = 250000; // 250ms
const TUid KPSCategoryUid = TUid::Uid( 0x200286E3 );
const TInt KPSCrashCountKey = 1;
@@ -185,11 +186,17 @@
// -----------------------------------------------------------------------------
//
void CHsLaunch::RunL()
- {
- // Create process
+ {
+ // Create app or connect to existing.
+ TInt processExisted = EFalse;
+
RProcess process;
- TInt processError = KErrNone;
- processError = process.Create( KHsExeName, KNullDesC );
+ TInt processError = process.Create( KHsExeName, KNullDesC );
+ if( processError == KErrAlreadyExists )
+ {
+ processError = process.Open( KHsProcessName, EOwnerProcess );
+ processExisted = ETrue;
+ }
TInt monitorError = KErrNone;
if( processError == KErrNone )
@@ -197,7 +204,8 @@
TRAP( monitorError, InitProcessMonitorL( process.Id() ) );
}
- if( processError == KErrNone )
+ if( processError == KErrNone &&
+ !processExisted )
{
// Make sure process is started even if monitor startup
// fails. This will assure that process is not left in
--- a/idlefw/plugins/devicestatus/inc/aimcnpublisher.h Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/devicestatus/inc/aimcnpublisher.h Wed Oct 13 14:53:46 2010 +0300
@@ -98,11 +98,6 @@
* Own.
*/
CAiNetworkInfoListener* iListener;
-
- /**
- * MCN info to show
- */
- TNWMCNName iMCNName;
};
--- a/idlefw/plugins/devicestatus/src/aicontentobserveroptimizer.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/devicestatus/src/aicontentobserveroptimizer.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -194,24 +194,7 @@
TInt aContent,
TInt aIndex )
{
- if ( IsInBlackList( aContent, aIndex ) )
- {
- return KErrNotFound;
- }
- TInt err = iObserver.Clean( aPlugin, aContent, aIndex );
- // Publish went through OK, we need to commit the transaction
- if ( err == KErrNone && iTransactionStarted )
- {
- iCommitNeeded = ETrue;
- }
- // publish failed because the ui declaration doesn't
- // include this content => add to black list and
- // don't try to publish again
- else if ( err == KErrNotFound || err == KErrNotSupported )
- {
- AddToBlackList( aContent, aIndex );
- }
- return err;
+ return iObserver.Clean( aPlugin, aContent, aIndex );
}
MAiContentObserver& CAiContentObserverOptimizer::Observer() const
--- a/idlefw/plugins/devicestatus/src/aimcnpublisher.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/devicestatus/src/aimcnpublisher.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -71,10 +71,7 @@
void CAiMCNPublisher::RefreshL( TBool /*aClean*/ )
{
- iContentObserver->Publish( *iExtension,
- EAiDeviceStatusContentMCNIndicator,
- iMCNName,
- 0 );
+ //cannot be refreshed
}
@@ -88,15 +85,14 @@
{
if ( aInfo.iMCNIndicatorType == ENWMCNIndicatorTypeActive )
{
- iMCNName.Copy( aInfo.iMCNName );
+ TPtrC msg = aInfo.iMCNName;
iContentObserver->Publish( *iExtension,
EAiDeviceStatusContentMCNIndicator,
- iMCNName,
+ msg,
0 );
}
else if ( aInfo.iMCNIndicatorType == ENWMCNIndicatorTypeNone )
{
- iMCNName.Copy( KNullDesC );
iContentObserver->Clean( *iExtension,
EAiDeviceStatusContentMCNIndicator,
0 );
--- a/idlefw/plugins/mcsplugin/group/bld.inf Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/group/bld.inf Wed Oct 13 14:53:46 2010 +0300
@@ -35,7 +35,6 @@
../handler/inc/mcspluginparamval.h MW_LAYER_PLATFORM_EXPORT_PATH(mcspluginparamval.h)
-qgn_mcsplugin_log_out.svg /epoc32/s60/icons/qgn_mcsplugin_log_out.svg
PRJ_EXTENSIONS
@@ -46,7 +45,7 @@
OPTION SOURCES -c8,8 qgn_prop_ai_shortcut -c8,8 qgn_menu_url \
-c8,8 qgn_menu_mce_sel_mes -c8,8 qgn_menu_mce_syncmail \
-c8,8 qgn_menu_am -c8,8 qgn_prop_cp_conn_shortcut \
- -c8,8 qgn_prop_psln_ai_sub -c8,8 qgn_mcsplugin_log_out \
+ -c8,8 qgn_prop_psln_ai_sub -c8,8 qgn_prop_log_calls_sub \
-c8,8 qgn_menu_mce_postcard -c8,8 qgn_menu_mce_email \
-c8,8 qgn_menu_mce_audio -c8,8 qgn_menu_mce_gene
END
--- a/idlefw/plugins/mcsplugin/group/qgn_mcsplugin_log_out.svg Wed Sep 15 12:32:36 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,127 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1 Tiny//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11-tiny.dtd">
-<svg baseProfile="tiny" height="96px" version="1.1" viewBox="0 0 96 96" width="96px" x="0px" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" y="0px">
-<path d="M87.141,59.508L74.324,37.93c-0.414-0.701-1.355-0.605-1.716-0.009L62.199,55.123V39.157 c0-1.741-1.417-3.157-3.158-3.157H48.979c-1.74,0-3.156,1.416-3.156,3.157v19.106H41c-0.654,0-1.319,0.754-0.855,1.518L53.202,81.36 c0.391,0.647,1.332,0.642,1.715-0.008l10.312-17.359v16.13c0,1.741,1.416,3.157,3.156,3.157h10.063c1.741,0,3.158-1.416,3.158-3.157 V61.018h4.676C87.031,61.018,87.546,60.19,87.141,59.508z" fill-opacity="0.15" stroke-opacity="0.15"/>
-<path d="M86.711,59.763L73.894,38.184c-0.145-0.246-0.617-0.399-0.857-0.004L61.699,56.915V39.157 c0-1.465-1.192-2.657-2.658-2.657H48.979c-1.465,0-2.656,1.192-2.656,2.657v19.606H41c-0.389,0-0.63,0.426-0.428,0.759L53.63,81.102 c0.195,0.32,0.665,0.324,0.857-0.004l11.241-18.926v17.951c0,1.465,1.191,2.657,2.656,2.657h10.063c1.466,0,2.658-1.192,2.658-2.657 V60.518h5.176C86.691,60.518,86.896,60.073,86.711,59.763z" fill-opacity="0.15" stroke-opacity="0.15"/>
-<path d="M73.464,38.438L61.199,58.707L41,59.264l13.058,21.579l12.171-20.492v19.772c0,1.192,0.967,2.157,2.156,2.157 h10.063c1.191,0,2.158-0.965,2.158-2.157V60.018h5.676L73.464,38.438z" fill-opacity="0.4" stroke-opacity="0.4"/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_1_" x1="53.9375" x2="53.9375" y1="36.4458" y2="88.6872">
-<stop offset="0" style="stop-color:#96D63A"/>
-<stop offset="1" style="stop-color:#0F581C"/>
-</linearGradient>
-<path d="M61.199,58.264V38.157c0-1.19-0.967-2.157-2.158-2.157H48.979c-1.19,0-2.156,0.967-2.156,2.157 v20.106H41l13.058,21.579l12.817-21.579H61.199z" fill="url(#SVGID_1_)"/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_2_" x1="54.0107" x2="54.0107" y1="36.7773" y2="50.6849">
-<stop offset="0" style="stop-color:#FFFFFF;stop-opacity:0.6"/>
-<stop offset="1" style="stop-color:#FFFFFF;stop-opacity:0"/>
-</linearGradient>
-<path d="M61.199,45.871v-7.714c0-1.19-0.967-2.157-2.158-2.157H48.979c-1.19,0-2.156,0.967-2.156,2.157 v15.767c1.117-1.051,2.334-2.052,3.645-2.984C53.93,48.472,57.622,46.784,61.199,45.871z" fill="url(#SVGID_2_)"/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_3_" x1="53.9336" x2="53.9336" y1="22.3457" y2="72.8956">
-<stop offset="0" style="stop-color:#96D63A"/>
-<stop offset="1" style="stop-color:#0F581C"/>
-</linearGradient>
-<polyline fill="url(#SVGID_3_)" points="41,58.264 54.058,79.843 66.867,58.275 65.117,59.264 54.05,77.898 42.773,59.264 41.021,58.264 "/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_4_" x1="63.6768" x2="63.6768" y1="50.9502" y2="70.8604">
-<stop offset="0" style="stop-color:#79CD19"/>
-<stop offset="1" style="stop-color:#1B6332"/>
-</linearGradient>
-<polygon fill="url(#SVGID_4_)" points="60.479,58.982 61.199,58.982 65.611,58.982 65.599,59.003 66.867,58.275 66.875,58.264 61.199,58.264 61.199,58.261 60.479,58.979 "/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_5_" x1="44.4111" x2="44.4111" y1="48.4136" y2="75.24">
-<stop offset="0" style="stop-color:#96D63A"/>
-<stop offset="1" style="stop-color:#0F581C"/>
-</linearGradient>
-<polygon fill="url(#SVGID_5_)" points="42.773,59.264 47.822,59.264 46.818,58.264 41,58.264 "/>
-<path d="M59.123,58.241c-0.28,0.463-0.289,1.042-0.025,1.512c0.266,0.472,0.767,0.765,1.309,0.765h4.322v1.358 l2.146-3.612h-5.676v-3.453L59.123,58.241z" fill-opacity="0.1" stroke-opacity="0.1"/>
-<path d="M59.551,58.5c-0.188,0.309-0.193,0.695-0.017,1.008c0.177,0.314,0.511,0.51,0.872,0.51h4.822v1.017 l1.646-2.771h-5.676v-2.488L59.551,58.5z" fill-opacity="0.1" stroke-opacity="0.1"/>
-<path d="M59.979,58.759c-0.094,0.154-0.098,0.347-0.008,0.504c0.088,0.157,0.254,0.255,0.436,0.255h5.322v0.675 l1.146-1.929h-5.676v-1.522L59.979,58.759z" fill-opacity="0.3" stroke-opacity="0.3"/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_6_" x1="73.3438" x2="73.3438" y1="26.1245" y2="90.2377">
-<stop offset="0" style="stop-color:#009AFF"/>
-<stop offset="1" style="stop-color:#051F7D"/>
-</linearGradient>
-<path d="M86.281,59.018L73.464,37.438L60.406,59.018h5.822v20.105c0,1.192,0.967,2.157,2.156,2.157h10.063 c1.191,0,2.158-0.965,2.158-2.157V59.018H86.281z" fill="url(#SVGID_6_)"/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_7_" x1="70.4414" x2="70.4414" y1="39.8643" y2="57.3841">
-<stop offset="0" style="stop-color:#FFFFFF;stop-opacity:0.6"/>
-<stop offset="1" style="stop-color:#FFFFFF;stop-opacity:0"/>
-</linearGradient>
-<path d="M73.469,53.096c2.271-1.617,4.639-2.9,7.008-3.85l-7.013-11.808L60.406,59.018h5.822v1.063 C68.139,57.55,70.572,55.159,73.469,53.096z" fill="url(#SVGID_7_)"/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_8_" x1="73.3398" x2="73.3398" y1="46.8115" y2="82.3889">
-<stop offset="0" style="stop-color:#009AFF"/>
-<stop offset="1" style="stop-color:#051F7D"/>
-</linearGradient>
-<polygon fill="url(#SVGID_8_)" points="84.52,57.998 73.457,39.384 62.191,57.998 60.406,59.018 73.464,37.438 86.273,59.006 "/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_9_" x1="82.9434" x2="82.9434" y1="26.3955" y2="67.8789">
-<stop offset="0" style="stop-color:#009AFF"/>
-<stop offset="1" style="stop-color:#051F7D"/>
-</linearGradient>
-<polygon fill="url(#SVGID_9_)" points="84.52,57.998 86.281,59.018 80.605,59.018 79.605,58.021 "/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_10_" x1="63.8271" x2="63.8271" y1="25.7705" y2="68.054">
-<stop offset="0" style="stop-color:#009AFF"/>
-<stop offset="1" style="stop-color:#051F7D"/>
-</linearGradient>
-<polygon fill="url(#SVGID_10_)" points="62.191,57.998 67.248,57.998 66.225,59.018 60.406,59.018 "/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_11_" x1="54.0088" x2="54.0088" y1="33.3389" y2="68.1402">
-<stop offset="0" style="stop-color:#96D63A"/>
-<stop offset="1" style="stop-color:#0F581C"/>
-</linearGradient>
-<path d="M47.822,38.157c0-0.638,0.52-1.157,1.156-1.157h10.063c0.639,0,1.158,0.52,1.158,1.157v21.106 l1-1.266V38.157c0-1.19-0.967-2.157-2.158-2.157H48.979c-1.19,0-2.156,0.967-2.156,2.157v20.106h-0.004l1.004,1V38.157z" fill="url(#SVGID_11_)"/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_12_" x1="73.415" x2="73.415" y1="24.9624" y2="75.6372">
-<stop offset="0" style="stop-color:#009AFF"/>
-<stop offset="1" style="stop-color:#051F7D"/>
-</linearGradient>
-<path d="M79.605,79.123c0,0.638-0.52,1.157-1.158,1.157H68.385c-0.637,0-1.156-0.52-1.156-1.157V58.018l0,0 l-1.004,1h0.004v20.105c0,1.192,0.967,2.157,2.156,2.157h10.063c1.191,0,2.158-0.965,2.158-2.157V59.021l-1-1V79.123z" fill="url(#SVGID_12_)"/>
-<path d="M29.249,51.904c-0.025-1.024,1.39-6.07,8.97-13.688c6.15-6.124,11.745-8.977,13.59-8.977 c0.027,0,0.054,0.001,0.079,0.003c1.002,0.438,1.713,0.745,2.303,0.999c2.084,0.898,2.644,1.141,9.219,4.241 c0.135,0.064,0.278,0.097,0.429,0.097c0.121,0,0.24-0.021,0.352-0.064c3.961-1.483,10.477-5.185,15.419-9.802 c0.241-0.224,0.356-0.551,0.309-0.879c-0.303-2.076-1.227-8.392-5.288-11.934l-0.097-0.11c-0.081-0.095-0.164-0.188-0.251-0.274 c-2.271-2.276-5.437-3.431-9.407-3.431c-7.128,0-16.449,3.885-26.249,10.939c-4.834,3.503-8.48,6.521-10.828,8.964 c-3.177,3.155-5.712,6.41-8.773,10.64C7.879,54.107,5.002,67.769,11.516,74.28c0.144,0.144,0.294,0.275,0.457,0.411 c2.435,2.627,6.288,4.361,11.541,5.17c0.102,0.015,0.174,0.025,0.186,0.027c0.092,0.026,0.187,0.04,0.281,0.04 c0.293,0,0.57-0.128,0.762-0.352c3.852-4.524,7.017-8.528,9.764-15.366c0.102-0.253,0.095-0.54-0.018-0.786 C32.811,59.738,29.729,52.963,29.249,51.904z" fill-opacity="0.15" stroke-opacity="0.15"/>
-<path d="M51.809,28.739c0.076,0,0.146,0.005,0.209,0.014c1.038,0.454,1.768,0.77,2.371,1.029 c2.09,0.901,2.651,1.144,9.236,4.249c0.067,0.032,0.14,0.048,0.213,0.048c0.06,0,0.119-0.011,0.176-0.032 c3.916-1.467,10.36-5.128,15.255-9.701c0.12-0.111,0.178-0.275,0.154-0.438c-0.297-2.03-1.199-8.21-5.169-11.678l-0.101-0.114 c-0.073-0.085-0.147-0.169-0.226-0.247c-2.174-2.179-5.22-3.284-9.054-3.284c-7.024,0-16.242,3.852-25.956,10.845 c-4.811,3.485-8.436,6.486-10.769,8.913c-3.152,3.131-5.673,6.367-8.72,10.577C8.438,54.187,5.541,67.601,11.869,73.927 c0.137,0.137,0.28,0.263,0.425,0.39l0.045,0.035c2.355,2.541,6.112,4.225,11.165,5.002c0.165,0.025,0.28,0.042,0.335,0.055 c0.047,0.014,0.095,0.021,0.142,0.021c0.144,0,0.284-0.063,0.381-0.176c3.821-4.488,6.961-8.459,9.681-15.228 c0.051-0.127,0.048-0.27-0.009-0.394c-1.729-3.801-4.951-10.884-5.276-11.603c-0.111-0.981,1.106-6.125,9.109-14.168 C44.186,31.569,49.823,28.739,51.809,28.739z" fill-opacity="0.15" stroke-opacity="0.15"/>
-<path d="M52.164,28.271c4.692,2.054,3.145,1.285,11.674,5.308c4.09-1.532,10.424-5.24,15.09-9.599 c-0.48-3.29-1.562-8.368-5.044-11.414c-0.104-0.114-50.946,22.359-54.048,26.646C9.289,53.86,5.992,67.345,12.223,73.573 c0.154,0.154,0.319,0.295,0.482,0.438c3.894,4.2,10.887,4.792,11.275,4.917c3.771-4.428,6.915-8.413,9.598-15.09 c0,0-5.254-11.549-5.305-11.666c-0.223-1.165,1.184-6.569,9.24-14.666C44.379,30.671,50.361,27.904,52.164,28.271z" fill-opacity="0.4" stroke-opacity="0.4"/>
-<path d="M73.033,10.892C52.262,16.63,17.804,47.755,11.3,71.076c3.253,5.97,12.239,6.711,12.681,6.853 c3.771-4.428,6.915-8.413,9.598-15.09c0,0-5.254-11.549-5.305-11.666c-0.223-1.165,1.184-6.569,9.24-14.666 c6.865-6.836,12.848-9.603,14.65-9.235c4.692,2.054,3.145,1.285,11.674,5.308c4.09-1.532,10.424-5.24,15.09-9.599 C78.41,19.436,77.199,13.81,73.033,10.892z" fill="#283175"/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_13_" x1="43.6226" x2="43.6226" y1="23.3003" y2="128.0071">
-<stop offset="0" style="stop-color:#009AFF"/>
-<stop offset="1" style="stop-color:#051F7D"/>
-</linearGradient>
-<path d="M73.574,11.223c-5.807-5.821-18.67-3.687-34.363,7.612c-3.396,2.461-7.807,5.844-10.709,8.862 c-3.084,3.063-5.564,6.229-8.666,10.515C9.289,52.86,5.992,66.345,12.223,72.573c3.818,3.818,10.385,4.413,10.994,4.592 c4.497-4.987,7.803-10.404,9.598-15.09c-3.006-6.435-5.254-11.548-5.305-11.665c-0.283-1.743,2.064-7.453,9.24-14.667 c6.807-6.775,12.846-9.602,14.65-9.235c3.697,1.576,5.551,2.441,11.674,5.307c3.545-1.296,9.406-4.539,15.09-9.597 C78.164,22.218,77.273,14.918,73.574,11.223z" fill="url(#SVGID_13_)"/>
-<radialGradient cx="43.5562" cy="42.0718" gradientTransform="matrix(0.717 -0.6971 0.3681 0.3786 -3.1589 56.5061)" gradientUnits="userSpaceOnUse" id="SVGID_14_" r="22.0964">
-<stop offset="0" style="stop-color:#231F20;stop-opacity:0.3"/>
-<stop offset="0.753" style="stop-color:#231F20;stop-opacity:0.3"/>
-<stop offset="1" style="stop-color:#000000;stop-opacity:0"/>
-</radialGradient>
-<path d="M49.607,19.678c-1.505-1.193-9.787,5.495-17.231,12.648c-7.032,6.757-13.316,13.928-12.438,15.261 c3.18,4.833,11.333,14.573,12.877,14.488c1.786,4.025-3.473-7.438-5.305-11.665c-0.23-1.42,1.521-6.905,9.24-14.667 c6.695-6.663,12.752-9.621,14.65-9.235c0.119,0.051,7.91,3.49,11.674,5.307C63.945,29.955,53.846,23.039,49.607,19.678z" fill="url(#SVGID_14_)"/>
-<radialGradient cx="41.5591" cy="39.8374" fx="35.2914" fy="39.924" gradientTransform="matrix(-0.701 -0.7131 1.8436 -1.8123 -2.7515 141.6727)" gradientUnits="userSpaceOnUse" id="SVGID_15_" r="17.6458">
-<stop offset="0" style="stop-color:#000000;stop-opacity:0"/>
-<stop offset="0.9217" style="stop-color:#000000;stop-opacity:0"/>
-<stop offset="1" style="stop-color:#231F20;stop-opacity:0.3"/>
-</radialGradient>
-<path d="M68.869,8.576c-1.25-0.34-2.579-0.507-3.951-0.503c-13.027,0.08-29.163,12.766-34.965,18.216 C20.688,35.556,9.15,51.427,9.074,63.917c-0.004,1.18,0.118,2.329,0.367,3.425C28.054,36.005,40.387,26.255,68.869,8.576z" fill="url(#SVGID_15_)"/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_16_" x1="66.4609" x2="66.4609" y1="6.2998" y2="50.4396">
-<stop offset="0" style="stop-color:#009AFF"/>
-<stop offset="1" style="stop-color:#051F7D"/>
-</linearGradient>
-<path d="M63.281,31.535c3.168-1.302,8.643-4.069,14.758-9.383c-0.486-2.793-1.273-5.24-2.322-7.191 L54.883,27.663C57.611,28.872,60.445,30.173,63.281,31.535z" fill="url(#SVGID_16_)"/>
-<linearGradient gradientTransform="matrix(0.7071 -0.7071 0.7071 0.7071 -236.5468 -85.5474)" gradientUnits="userSpaceOnUse" id="SVGID_17_" x1="157.8945" x2="143.6744" y1="279.627" y2="285.387">
-<stop offset="0" style="stop-color:#FFFFFF"/>
-<stop offset="1" style="stop-color:#FFFFFF;stop-opacity:0"/>
-</linearGradient>
-<path d="M58.721,13.574l10.25,5.197l6.355-3.892C72.03,9.786,64.626,9.209,58.721,13.574z" fill="url(#SVGID_17_)"/>
-<linearGradient gradientTransform="matrix(0.7071 -0.7071 0.7071 0.7071 -236.5468 -85.5474)" gradientUnits="userSpaceOnUse" id="SVGID_18_" x1="118.0596" x2="132.8288" y1="272.0107" y2="283.7179">
-<stop offset="0" style="stop-color:#FFFFFF"/>
-<stop offset="1" style="stop-color:#FFFFFF;stop-opacity:0"/>
-</linearGradient>
-<path d="M55.307,17.018c-2.447,3.188-3.613,6.659-3.227,8.976l2.979,1.27l9.41-5.786 C66.867,17.575,58.682,12.629,55.307,17.018z" fill="url(#SVGID_18_)"/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_19_" x1="24.2266" x2="24.2266" y1="32.5884" y2="95.3979">
-<stop offset="0" style="stop-color:#009AFF"/>
-<stop offset="1" style="stop-color:#051F7D"/>
-</linearGradient>
-<path d="M32.666,62.194c-1.328,3.224-4.145,8.8-9.557,15.029c-2.844-0.499-5.334-1.299-7.322-2.366 l12.934-21.216C29.955,56.421,31.277,59.305,32.666,62.194z" fill="url(#SVGID_19_)"/>
-<linearGradient gradientTransform="matrix(-0.7071 0.7071 0.7071 0.7071 -1710.7705 1388.6769)" gradientUnits="userSpaceOnUse" id="SVGID_20_" x1="-2182.1489" x2="-2167.1106" y1="271.624" y2="283.5445">
-<stop offset="0" style="stop-color:#FFFFFF"/>
-<stop offset="1" style="stop-color:#FFFFFF;stop-opacity:0"/>
-</linearGradient>
-<path d="M17.885,54.072c3.246-2.493,6.781-3.683,9.139-3.285l1.293,3.03l-5.891,9.582 C18.451,65.843,13.414,57.507,17.885,54.072z" fill="url(#SVGID_20_)"/>
-<linearGradient gradientTransform="matrix(-0.7071 0.7071 0.7071 0.7071 -1710.7705 1388.6769)" gradientUnits="userSpaceOnUse" id="SVGID_21_" x1="-2141.5947" x2="-2156.0691" y1="279.3809" y2="285.2439">
-<stop offset="0" style="stop-color:#FFFFFF"/>
-<stop offset="1" style="stop-color:#FFFFFF;stop-opacity:0"/>
-</linearGradient>
-<path d="M14.379,57.548l5.291,10.438l-3.965,6.471C10.576,71.127,9.883,63.628,14.379,57.548z" fill="url(#SVGID_21_)"/>
-<linearGradient gradientUnits="userSpaceOnUse" id="SVGID_22_" x1="47.3364" x2="47.3364" y1="-17.5747" y2="26.6288">
-<stop offset="0" style="stop-color:#FFFFFF;stop-opacity:0.5"/>
-<stop offset="1" style="stop-color:#FFFFFF;stop-opacity:0"/>
-</linearGradient>
-<path d="M76.711,20.254C75.91,16.429,73.963,9.139,64.967,9.133h-0.043 c-11.243,0.039-33.76,12.211-46.961,33.729C24.75,37.082,33,31.93,42.367,27.934C54.129,22.918,65.988,20.428,76.711,20.254z" fill="url(#SVGID_22_)"/>
-<rect fill="none" height="96" width="96"/>
-</svg>
--- a/idlefw/plugins/mcsplugin/handler/src/mcspluginhandler.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/handler/src/mcspluginhandler.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -30,7 +30,6 @@
#include <mcsmenuitem.h>
#include <mcspluginparamval.h>
#include <LogsUiCmdStarter.h>
-#include <apgcli.h>
// User includes
#include "mcsplugincompletedoperation.h"
@@ -40,13 +39,10 @@
// Constants
_LIT( KMenuTypeShortcut, "menu:shortcut" ); ///< Menu folder type.
_LIT( KMenuAttrParamLogs, "logs:dialed" );
-_LIT( KMenuAttrProfiles, "profiles" );
/** Argument value for parameter*/
_LIT( KMenuAttrParam, "param" );
-const TUid KProfilesAppUid = { 0x100058F8 };
-
#define KMCSCmailUidValue 0x2001E277
#define KMCSCmailMailboxDefaultViewIdValue 0x1
#define KMCSCmailMailboxViewIdValue 0x2
@@ -252,27 +248,6 @@
{
LogsUiCmdStarter::CmdStartL( LogsUiCmdStarterConsts::KDialledView() );
}
- else if ( param.Find( KMenuAttrProfiles ) != KErrNotFound )
- {
- RApaLsSession apaLsSession;
- User::LeaveIfError( apaLsSession.Connect() );
- CleanupClosePushL( apaLsSession );
-
- TApaAppInfo appInfo;
- TInt retVal = apaLsSession.GetAppInfo( appInfo, KProfilesAppUid );
-
- if ( retVal == KErrNone )
- {
- CApaCommandLine* cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL( appInfo.iFullName );
- cmdLine->SetCommandL( EApaCommandRun );
- User::LeaveIfError( apaLsSession.StartApp( *cmdLine ) );
-
- CleanupStack::PopAndDestroy( cmdLine );
- }
-
- CleanupStack::PopAndDestroy( &apaLsSession );
- }
CleanupStack::PopAndDestroy( sendUi );
}
--- a/idlefw/plugins/mcsplugin/publisher/inc/mcsplugindata.h Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/publisher/inc/mcsplugindata.h Wed Oct 13 14:53:46 2010 +0300
@@ -62,7 +62,7 @@
/**
* Name of the item.
*/
- const TDesC* Name();
+ TDesC& Name();
/**
* Set name of the item,
@@ -72,7 +72,7 @@
/**
* Value of the item. Used for bookmark url.
*/
- const TDesC* Value();
+ TDesC& Value();
/*
* Set value of the item.
--- a/idlefw/plugins/mcsplugin/publisher/inc/mcspluginengine.h Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/publisher/inc/mcspluginengine.h Wed Oct 13 14:53:46 2010 +0300
@@ -147,12 +147,9 @@
void SetBackupRestore( TBool aBackupRestore );
/**
- * Shows shortcut settings
- *
- * @param aEditIdx Change specified shortcut
- * @return void
- */
- void ShowSettingsL( const TInt aEditIdx );
+ * ShowSettingsL
+ */
+ void ShowSettingsL();
private:
// from MMCSPluginWatcherObserver
--- a/idlefw/plugins/mcsplugin/publisher/src/mcsplugin.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/publisher/src/mcsplugin.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -40,7 +40,6 @@
_LIT( KEventNameShowSettings, "ShowSettings" );
_LIT( KContentItemTypeText, "text" );
_LIT( KContentItemTypeImage, "image" );
-const TInt KUndefinedIndex = -1;
const TImplementationProxy KImplementationTable[] =
{
@@ -376,7 +375,7 @@
}
else if( aEventName == KEventNameShowSettings )
{
- TRAP_IGNORE( iEngine->ShowSettingsL( KUndefinedIndex ) );
+ TRAP_IGNORE( iEngine->ShowSettingsL() );
}
}
--- a/idlefw/plugins/mcsplugin/publisher/src/mcsplugindata.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/publisher/src/mcsplugindata.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -111,9 +111,9 @@
//
// ---------------------------------------------------------------------------
//
-const TDesC* CMCSData::Name()
+TDesC& CMCSData::Name()
{
- return iName;
+ return *iName;
}
// ---------------------------------------------------------------------------
@@ -131,9 +131,9 @@
//
// ---------------------------------------------------------------------------
//
-const TDesC* CMCSData::Value()
+TDesC& CMCSData::Value()
{
- return iValue;
+ return *iValue;
}
// ---------------------------------------------------------------------------
@@ -265,20 +265,20 @@
// id of all bookmarks is zero so name has to be check
// in case of bookmark has changed
- if( data->MenuItem().Id() != id ||
- ( id == 0 && data->Name() != NULL && iData[i]->Name() != NULL &&
- data->Name()->CompareF( *iData[i]->Name() ) != 0 ) )
+ if ( id >= 0 && ( data->MenuItem().Id() != id ||
+ ( id == 0 && data->Name().CompareF(
+ iData[ i ]->Name() ) != 0 ) ) )
{
data->SetDirty( ETrue );
CMCSData* oldData = iData[i];
iData.Remove( i );
delete oldData;
+
iData.InsertL( data, i );
- CleanupStack::Pop( data );
+ CleanupStack::Pop( data );
}
else
{
- // keep old data
CleanupStack::PopAndDestroy( data );
}
}
@@ -572,8 +572,8 @@
}
}
}
- // EFalse tells that modified settings are not stored to plugin reference
- iPluginSettings->SetSettingsL( iInstanceUid, settingItems, EFalse );
+ // ETrue tells that modified settings are stored also to plugin reference
+ iPluginSettings->SetSettingsL( iInstanceUid, settingItems, ETrue );
CleanupStack::PopAndDestroy(); // settingItems
}
--- a/idlefw/plugins/mcsplugin/publisher/src/mcspluginengine.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/publisher/src/mcspluginengine.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -50,7 +50,9 @@
_LIT( KResourceFile, "mcspluginres.rsc" );
_LIT( KResPath, "\\resource\\" );
_LIT( KMMApplication, "mm://" );
-_LIT( KSetOpenItemString, "!openitem?id=" );
+_LIT( KHideExit2, "&exit=hide" );
+_LIT( KSetFocusString, "!setfocus?applicationgroup_name=" );
+_LIT( KApplicationGroupName, "applicationgroup_name" );
_LIT( KIcon, "icon" );
_LIT( KMenuAttrUndefUid, "0x99999991" );
_LIT( KMenuIconFile, "aimcsplugin.mif" );
@@ -60,7 +62,6 @@
_LIT( KMenuMailboxMaskId, "16389" );
_LIT( KMenuTypeMailbox, "menu:mailbox" );
_LIT( KPrefix, "0x" );
-_LIT( KMenuAttrInvokeSettingsUid, "0x99999990" );
const TUid KHomescreenUid = { AI_UID3_AIFW_COMMON };
const TUid KMMUid = { 0x101F4CD2 };
@@ -68,13 +69,6 @@
const TUid KMCSCmailMailboxViewIdValue = { 0x2 };
const TUid KBrowserUid = { 0x10008D39 };
-// maximum custom message length
-const TInt KMaxCustomMsg = 256;
-const TInt KUndefinedIndex = -1;
-
-// maximun integer character length
-const TInt KMaxLength = 12;
-
// ======== LOCAL FUNCTIONS ========
// ----------------------------------------------------------------------------
// NextIdToken
@@ -361,7 +355,7 @@
{
item = CMenuItem::CreateL( iMenu, KMenuTypeUrl, 0, 0 );
CleanupStack::PushL( item );
- item->SetAttributeL( KMenuAttrLongName, *aData.Name() );
+ item->SetAttributeL( KMenuAttrLongName, aData.Name() );
item->SetAttributeL( KMenuAttrIconFile, KMenuIconFile );
item->SetAttributeL( KMenuAttrIconId, KMenuBookmarkIconId );
item->SetAttributeL( KMenuAttrMaskId, KMenuBookmarkMaskId );
@@ -381,7 +375,7 @@
{
item = CMenuItem::CreateL( iMenu, KMenuTypeMailbox, 0, 0 );
CleanupStack::PushL( item );
- item->SetAttributeL( KMenuAttrLongName, *aData.Name() );
+ item->SetAttributeL( KMenuAttrLongName, aData.Name() );
item->SetAttributeL( KMenuAttrIconFile, KMenuIconFile );
item->SetAttributeL( KMenuAttrIconId, KMenuMailboxIconId );
item->SetAttributeL( KMenuAttrMaskId, KMenuMailboxMaskId );
@@ -409,14 +403,7 @@
TUint32 isHidden = flags & TMenuItem::EHidden;
TUint32 isMissing = flags & TMenuItem::EMissing;
- TBool attrExists = ETrue;
- TPtrC uid = aMenuItem->GetAttributeL(KMenuAttrUid, attrExists);
-
- // if item is hidden or missing (mmc card removed)
- // use "Undefined" icon instead
- // for empty item it's own icon is shown
- if ( iUndefinedItem && uid.Compare(KMenuAttrInvokeSettingsUid) != 0 &&
- ( isHidden || isMissing ) )
+ if ( iUndefinedItem && ( isHidden || isMissing ) )
{
menuItem = iUndefinedItem;
}
@@ -484,14 +471,9 @@
TUint32 isHidden = flags & TMenuItem::EHidden;
TUint32 isMissing = flags & TMenuItem::EMissing;
- TBool attrExists = ETrue;
- TPtrC uid = aMenuItem->GetAttributeL(KMenuAttrUid, attrExists);
-
// if item is hidden or missing (mmc card removed)
// use "Undefined" text instead
- // for empty item it's own icon is shown
- if ( iUndefinedItem && uid.Compare(KMenuAttrInvokeSettingsUid) != 0 &&
- ( isHidden || isMissing ) )
+ if ( iUndefinedItem && ( isHidden || isMissing ) )
{
menuItem = iUndefinedItem;
}
@@ -550,23 +532,7 @@
}
else
{
- CMenuItem* item(CMenuItem::OpenL(iMenu, dataItem.MenuItem().Id()));
- CleanupStack::PushL(item);
-
- TBool attrExists = ETrue;
-
- TPtrC uid = item->GetAttributeL(KMenuAttrUid, attrExists);
-
- // Show selected shortcut settings
- if (uid.Compare(KMenuAttrInvokeSettingsUid) == 0)
- {
- TRAP_IGNORE( ShowSettingsL(aIndex + 1) );
- }
- else
- {
- LaunchMCSItemL(dataItem);
- }
- CleanupStack::PopAndDestroy(item);
+ LaunchMCSItemL( dataItem );
}
}
@@ -594,15 +560,25 @@
HBufC8* message;
// prepare message for launching folder
- TBuf<KMaxLength> itemId;
- itemId.Num( item->Id() );
+ TBool hasApplicationGroupName( EFalse );
+
+ TPtrC applicationGroupName( item->GetAttributeL(
+ KApplicationGroupName, hasApplicationGroupName ) );
+
+ if ( !hasApplicationGroupName )
+ {
+ return;
+ }
- message = HBufC8::NewLC( KMMApplication().Length()
- + KSetOpenItemString().Length()
- + itemId.Length() );
+ message = HBufC8::NewLC( KMMApplication().Length() +
+ KSetFocusString().Length() +
+ applicationGroupName.Length() +
+ KHideExit2().Length() );
+
message->Des().Copy( KMMApplication );
- message->Des().Append( KSetOpenItemString );
- message->Des().Append( itemId );
+ message->Des().Append( KSetFocusString );
+ message->Des().Append( applicationGroupName );
+ message->Des().Append( KHideExit2 );
// find MM application
TApaTaskList taskList( CCoeEnv::Static()->WsSession() );
@@ -648,7 +624,7 @@
{
StartEffect( KBrowserUid );
- CSchemeHandler* urlHandler = CSchemeHandler::NewL( *aData.Value());
+ CSchemeHandler* urlHandler = CSchemeHandler::NewL( aData.Value());
CleanupStack::PushL( urlHandler );
urlHandler->HandleUrlStandaloneL();
CleanupStack::PopAndDestroy( urlHandler );
@@ -740,6 +716,7 @@
CMCSData& data( iPluginData->DataItemL( i ) );
data.SetDirty( ETrue );
}
+ iPluginData->UpdateDataL();
iPlugin.PublishL();
@@ -792,22 +769,12 @@
// Launch General Settings plugin
// ---------------------------------------------------------------------------
//
-void CMCSPluginEngine::ShowSettingsL( const TInt aEditIdx )
+void CMCSPluginEngine::ShowSettingsL()
{
TUid uid = {AI_UID_ECOM_IMPLEMENTATION_SETTINGS_MCSPLUGIN};
- // format the custom message
- // iInstanceUid/aEditIdx is the format
- TBuf8<KMaxCustomMsg> msg;
- msg.Append(iInstanceUid);
- if( aEditIdx != KUndefinedIndex )
- {
- msg.Append('//');
- msg.AppendFormat(_L8("%d"), aEditIdx);
- }
-
CGSLauncher* launcher = CGSLauncher::NewLC();
- launcher->LaunchGSViewL ( uid, KHomescreenUid, msg );
+ launcher->LaunchGSViewL ( uid, KHomescreenUid, iInstanceUid );
CleanupStack::PopAndDestroy( launcher );
}
--- a/idlefw/plugins/mcsplugin/settings/inc/mcspluginsettings.h Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/settings/inc/mcspluginsettings.h Wed Oct 13 14:53:46 2010 +0300
@@ -159,11 +159,6 @@
*/
void HandleListBoxSelectionL();
- /**
- * Callback function to be used with CPeriodic.
- */
- static TInt TimerCallbackL( TAny *aPtr );
-
private: // data
/**
@@ -171,12 +166,6 @@
* Own.
*/
CMCSPluginSettingsModel* iModel;
-
- /**
- * Timer to change specified shortcut when view is activated.
- * Own.
- */
- CPeriodic* iTimer;
};
#endif // MCSPLUGINSETTINGS_H
--- a/idlefw/plugins/mcsplugin/settings/inc/mcspluginsettingsapplist.h Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/settings/inc/mcspluginsettingsapplist.h Wed Oct 13 14:53:46 2010 +0300
@@ -130,11 +130,6 @@
*/
TPtrC UndefinedText() { return *iUndefinedText; };
- /**
- * Returns title for empty item
- */
- TPtrC EmptyText() { return *iEmptyText; };
-
private:
/**
* Constructor
@@ -174,14 +169,6 @@
*/
void AddMailboxL( const TDesC& aMailbox, const TDesC& aMailboxId );
- /**
- * Returns title for requested item
- *
- * @param aUid Shortcut items uid
- * @return HBufC title
- */
- HBufC* MenuItemTextL( const TDesC& aUid );
-
private: // data
/**
@@ -205,11 +192,10 @@
*/
HBufC* iUndefinedText;
- /**
- * Name of "Empty" application, own
+ /*
+ * Undefined MCS item, own
*/
- HBufC* iEmptyText;
-
+ CMenuItem* iUndefinedItem;
};
#endif // CMCSPLUGINSETTINGSAPPLIST_H
--- a/idlefw/plugins/mcsplugin/settings/inc/mcspluginsettingsbkmlist.h Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/settings/inc/mcspluginsettingsbkmlist.h Wed Oct 13 14:53:46 2010 +0300
@@ -109,13 +109,6 @@
TSettingItem FindItemL(
RPointerArray<HSPluginSettingsIf::CPropertyMap>& aProperties );
- /**
- * Checks with a given index if bookmark has been hidden from menulist
- *
- * @param aIndex Index of the bookmark in the list
- * @return ETrue if the bookmark is hidden, EFalse otherwise
- */
- TBool ItemHidden( TInt aIndex );
protected:
@@ -243,11 +236,6 @@
* Target bookmark parameters
*/
HBufC* iUrl;
-
- /**
- * Target bookmark hidden
- */
- TBool iHidden;
private:
--- a/idlefw/plugins/mcsplugin/settings/inc/mcspluginsettingscontainer.h Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/settings/inc/mcspluginsettingscontainer.h Wed Oct 13 14:53:46 2010 +0300
@@ -117,12 +117,7 @@
* Hanle notify
*/
void HandleNotifyL();
-
- /**
- * Sets currently selected index
- */
- void SetCurrentItemIndex(TInt aIdx);
-
+
private:
/*
--- a/idlefw/plugins/mcsplugin/settings/inc/mcspluginsettingsmodel.h Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/settings/inc/mcspluginsettingsmodel.h Wed Oct 13 14:53:46 2010 +0300
@@ -52,7 +52,6 @@
TInt id;
TSettingType type;
TBool locked;
- TBool empty;
};
/**
@@ -223,14 +222,6 @@
TBool SettingLockedL(
RPointerArray<HSPluginSettingsIf::CPropertyMap>& aProperties );
- /**
- * Empty setting
- *
- * @param aProperties
- * @return TBool
- */
- TBool SettingEmptyL(
- RPointerArray<HSPluginSettingsIf::CPropertyMap>& aProperties );
/**
--- a/idlefw/plugins/mcsplugin/settings/src/mcspluginsettings.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/settings/src/mcspluginsettings.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -75,8 +75,6 @@
//
void CMCSPluginSettings::ConstructL()
{
- iTimer = CPeriodic::NewL( CActive::EPriorityUserInput );
-
FeatureManager::InitializeLibL();
TParsePtrC driveParse(PathInfo::RomRootPath());
@@ -115,12 +113,6 @@
FeatureManager::UnInitializeLib();
iResourceLoader.Close();
delete iModel;
-
- if (iTimer->IsActive())
- {
- iTimer->Cancel();
- }
- delete iTimer;
}
// ---------------------------------------------------------------------------
@@ -168,49 +160,11 @@
//
void CMCSPluginSettings::DoActivateL(const TVwsViewId& aPrevViewId, TUid aCustomMessageId, const TDesC8& aCustomMessage)
{
- // Parse the custom message
- TInt locate = aCustomMessage.Locate('/');
- TInt editIdx = -1;
-
+ iModel->SetPluginIdL( aCustomMessage );
iModel->UpdateAppListL( EFalse );
iModel->UpdateBkmListL( EFalse );
-
- if (locate > 0)
- {
- // if / is located in the custom mesage
- // upto / is the plugin id
- iModel->SetPluginIdL(aCustomMessage.Left(locate));
-
- // right most character is the edit index
- TLex8 lex(aCustomMessage.Right(1));
- lex.Val(editIdx);
-
- iModel->UpdateSettingsL();
- CGSBaseView::DoActivateL(aPrevViewId, aCustomMessageId,
- aCustomMessage.Left(locate));
-
- if (editIdx > 0)
- {
- // set the current edit item
- Container()->SetCurrentItemIndex(editIdx - 1);
-
- // Set timer for handle the change of shortcut item
- // Otherwise status bar is not shown correctly
- if (iTimer->IsActive())
- {
- iTimer->Cancel();
- }
- iTimer->Start( 0, 0, TCallBack( TimerCallbackL, this ) );
- }
- }
- else
- {
- // if '/' is not located, custommessage has only the plugin id
- iModel->SetPluginIdL(aCustomMessage);
- iModel->UpdateSettingsL();
- CGSBaseView::DoActivateL(aPrevViewId, aCustomMessageId,
- aCustomMessage);
- }
+ iModel->UpdateSettingsL();
+ CGSBaseView::DoActivateL( aPrevViewId, aCustomMessageId, aCustomMessage );
}
// ----------------------------------------------------------------------------
@@ -304,18 +258,4 @@
Container()->HandleChangeCommandL();
}
-// ---------------------------------------------------------------------------
-// Callback for direct settings change
-// ---------------------------------------------------------------------------
-//
-TInt CMCSPluginSettings::TimerCallbackL( TAny *aPtr )
- {
- CMCSPluginSettings* self = reinterpret_cast< CMCSPluginSettings* >( aPtr );
- self->iTimer->Cancel();
- // Handle the change
- self->HandleListBoxSelectionL();
-
- return 0;
- }
-
// End of File.
--- a/idlefw/plugins/mcsplugin/settings/src/mcspluginsettingsapplist.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/settings/src/mcspluginsettingsapplist.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -30,7 +30,6 @@
_LIT8( KItemLocked, "locked");
_LIT8( KProperValueFolder, "folder" );
_LIT( KMenuAttrUndefUid, "0x99999991" );
-_LIT( KMenuAttrInvokeSettingsUid, "0x99999990" );
_LIT( KMenuItemLongName, "long_name" );
#define KMCSCmailMtmUidValue 0x2001F406
@@ -55,11 +54,45 @@
iMenu.OpenL( KMyMenuData );
- iUndefinedText = MenuItemTextL( KMenuAttrUndefUid );
- iEmptyText = MenuItemTextL( KMenuAttrInvokeSettingsUid );
+ // Get "Undefined" icon and text
+ CMenuFilter* filter = CMenuFilter::NewL();
+ CleanupStack::PushL( filter );
+
+ // 'Undefined' item
+ filter->HaveAttributeL( KMenuAttrUid, KMenuAttrUndefUid );
+
+ TMenuItem item;
+ const TInt root = iMenu.RootFolderL();
+ RArray<TMenuItem> items;
+ CleanupClosePushL( items );
+ iMenu.GetItemsL( items, root, filter, ETrue );
+
+ if ( items.Count() > 0 )
+ {
+ iUndefinedItem = CMenuItem::OpenL( iMenu, items[ 0 ] );
+ iUndefinedText = NULL;
+
+ if ( iUndefinedItem )
+ {
+ TBool exists( KErrNotFound );//CleanupStack::PushL( undefinedItem );
+ TPtrC undefined = iUndefinedItem->GetAttributeL( KMenuItemLongName, exists );
+
+ if ( exists )
+ {
+ iUndefinedText = HBufC::NewMaxL( undefined.Length() );
+ iUndefinedText->Des().Copy( undefined );
+ }
+ else
+ {
+ iUndefinedText = KNullDesC().Alloc();
+ }
+ }
+ }
+
+ CleanupStack::PopAndDestroy( &items );
+ CleanupStack::PopAndDestroy( filter );
}
-
// ---------------------------------------------------------------------------
// Two-phased constructor
// ---------------------------------------------------------------------------
@@ -85,7 +118,7 @@
iMenu.Close();
delete iUndefinedText;
- delete iEmptyText;
+ delete iUndefinedItem;
}
// ---------------------------------------------------------------------------
@@ -155,7 +188,7 @@
RPointerArray<HSPluginSettingsIf::CPropertyMap>& aProperties )
{
TBool attrExists( EFalse );
- TSettingItem settingItem = { KErrNotFound, EApplication, EFalse, EFalse };
+ TSettingItem settingItem = { KErrNotFound, EApplication, EFalse };
TBool isFolder = EFalse;
// check if the item is folder
@@ -215,7 +248,7 @@
// otherwise, compare attributes from HSPS and from menuitem
// if there is no match, move to the next item in the list
- if ( attr.CompareF( *attrValue ) != 0 )
+ if ( attr != *attrValue )
{
match = EFalse;
}
@@ -381,56 +414,4 @@
CleanupStack::Pop( newItem );
}
-// ---------------------------------------------------------------------------
-// Gets specified menu item text
-// ---------------------------------------------------------------------------
-//
-HBufC* CMCSPluginSettingsAppList::MenuItemTextL( const TDesC& aUid )
- {
- HBufC* text = NULL;
-
- // Get specified icon and text
- CMenuFilter* filter = CMenuFilter::NewL();
- CleanupStack::PushL( filter );
-
- // Filter specified item
- filter->HaveAttributeL( KMenuAttrUid, aUid );
-
- const TInt root = iMenu.RootFolderL();
- RArray<TMenuItem> items;
- CleanupClosePushL( items );
- iMenu.GetItemsL( items, root, filter, ETrue );
-
- CMenuItem* item = NULL;
-
- if ( items.Count() > 0 )
- {
- item = CMenuItem::OpenL( iMenu, items[ 0 ] );
-
- if ( item )
- {
- TBool exists( KErrNotFound );
- TPtrC itemName = item->GetAttributeL( KMenuItemLongName, exists );
-
- if ( exists )
- {
- text = HBufC::NewMaxL( itemName.Length() );
- text->Des().Copy( itemName );
- }
- delete item;
- }
- }
-
- if( !text )
- {
- text = KNullDesC().Alloc();
- }
-
- CleanupStack::PopAndDestroy( &items );
- CleanupStack::PopAndDestroy( filter );
-
- return text;
- }
-
-
// End of File.
--- a/idlefw/plugins/mcsplugin/settings/src/mcspluginsettingsbkmlist.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/settings/src/mcspluginsettingsbkmlist.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -28,7 +28,6 @@
_LIT( KUrl, "url" );
_LIT8( KUid, "uid" );
_LIT( KMenuAttrParameter, "param" );
-_LIT8( KMenuAttrParameter8, "param" );
// ======== MEMBER FUNCTIONS ========
@@ -86,13 +85,7 @@
//
TInt CMCSPluginSettingsBkmList::MdcaCount() const
{
- TInt listItemsCount( 0 );
- for( TInt i = 0; i< iListItems.Count(); i++ )
- {
- if( !iListItems[i]->iHidden )
- listItemsCount++;
- }
- return listItemsCount;
+ return iListItems.Count();
}
// ---------------------------------------------------------------------------
@@ -111,79 +104,38 @@
}
// ---------------------------------------------------------------------------
-// Checks with a given index if bookmark has been hidden from menulist.
-// ---------------------------------------------------------------------------
-//
-TBool CMCSPluginSettingsBkmList::ItemHidden( TInt aIndex )
- {
- if ( aIndex < 0 || aIndex >= iListItems.Count( ))
- {
- return EFalse;
- }
- return iListItems[aIndex]->iHidden;
- }
-
-// ---------------------------------------------------------------------------
// Iterates thru the bookmark list and tries to find a menuitem which
// matches given property map from HSPS
// ---------------------------------------------------------------------------
//
-TSettingItem CMCSPluginSettingsBkmList::FindItemL(
- RPointerArray<HSPluginSettingsIf::CPropertyMap>& aProperties )
+TSettingItem CMCSPluginSettingsBkmList::FindItemL( RPointerArray<HSPluginSettingsIf::CPropertyMap>& aProperties )
{
- HBufC* uid( NULL );
- HBufC* param( NULL );
TInt index( KErrNotFound );
- TSettingItem settingItem = { KErrNotFound, EBookmark, EFalse, EFalse };
-
- // read property values
+ TSettingItem settingItem = { KErrNotFound, EBookmark, EFalse };
for( TInt i= 0; i < aProperties.Count(); i++ )
{
if( aProperties[i]->Name() == KUid )
{
- uid = AiUtility::CopyToBufferL(
- uid, aProperties[i]->Value() );
- CleanupStack::PushL( uid );
- }
- else if( aProperties[i]->Name() == KMenuAttrParameter8 )
- {
- param = AiUtility::CopyToBufferL(
- param, aProperties[i]->Value() );
- CleanupStack::PushL( param );
+ HBufC* value( NULL );
+ value = AiUtility::CopyToBufferL( value, aProperties[i]->Value());
+ for( TInt j = 0; j < iListItems.Count(); j++ )
+ {
+ TPtrC uid = *iListItems[j]->iUid;
+ if( uid.Compare( *value ) == 0 )
+ {
+ index = j;
+ break;
+ }
+ }
+ delete value;
}
- }
-
- // try to find a match
- for( TInt j = 0; j < iListItems.Count(); j++ )
- {
- TPtrC value = *iListItems[j]->iUid;
- if( value.Compare( *uid ) == 0 )
+ if( index != KErrNotFound )
{
- index = j;
+ settingItem.id = index;
+ settingItem.type = EBookmark;
break;
}
}
-
- // menuitem not found, add a new one
- if( index == KErrNotFound && uid && param )
- {
- CBkmListItem* listItem = CBkmListItem::NewLC( *uid, *param );
- listItem->iType = EFavBookmark;
- listItem->iUrl = KNullDesC().AllocL();
- listItem->iHidden = ETrue;
- iListItems.Append( listItem );
- CleanupStack::Pop( listItem );
-
- TInt listItemsCount = iListItems.Count();
- TPtrC value = *iListItems[--listItemsCount]->iUid;
- if( value.Compare( *uid ) == 0 )
- index = listItemsCount;
- }
-
- if( param ) CleanupStack::PopAndDestroy( param );
- if( uid ) CleanupStack::PopAndDestroy( uid );
-
- settingItem.id = index;
return settingItem;
}
@@ -367,7 +319,7 @@
//Nested class to store individual bookmark list items
// ---------------------------------------------------------------------------
//
-CMCSPluginSettingsBkmList::CBkmListItem::CBkmListItem() : iHidden( EFalse )
+CMCSPluginSettingsBkmList::CBkmListItem::CBkmListItem()
{
}
--- a/idlefw/plugins/mcsplugin/settings/src/mcspluginsettingscontainer.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/settings/src/mcspluginsettingscontainer.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -186,14 +186,7 @@
{
appListIndex = -1;
}
-
- // if the selected item is hidden, set selected item to -1
- TBool itemHidden = iModel->BkmList()->ItemHidden( appListIndex );
- if ( itemHidden )
- {
- appListIndex = -1;
- }
-
+
changed = HandleBookmarkChangeCommandL( appListIndex, current );
}
@@ -479,16 +472,4 @@
iNotifyWatcher->WatchNotify( this );
}
-// ---------------------------------------------------------------------------
-// Sets the currently selected item
-// ---------------------------------------------------------------------------
-//
-void CMCSPluginSettingsContainer::SetCurrentItemIndex( TInt aIdx )
- {
- if( iListBox )
- {
- iListBox->SetCurrentItemIndex( aIdx );
- }
- }
-
// End of File.
--- a/idlefw/plugins/mcsplugin/settings/src/mcspluginsettingsmodel.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/mcsplugin/settings/src/mcspluginsettingsmodel.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -49,7 +49,6 @@
_LIT8( KProperValueAppl, "application" );
_LIT8( KProperValueMailbox, "mailbox" );
_LIT( KMenuTypeMailbox, "menu:mailbox" );
-_LIT8( KMenuAttrInvokeSettingsUid, "0x99999990" );
using namespace HSPluginSettingsIf;
@@ -231,7 +230,7 @@
TSettingItem CMCSPluginSettingsModel::ItemL(
RPointerArray<HSPluginSettingsIf::CPropertyMap>& aProperties )
{
- TSettingItem setting = { KErrNotFound, EApplication , EFalse, EFalse };
+ TSettingItem setting = { KErrNotFound, EApplication , EFalse };
TSettingType type = SettingTypeL( aProperties );
if ( type == EApplication || type == EMailbox )
@@ -244,8 +243,7 @@
}
setting.locked = SettingLockedL( aProperties );
- setting.empty = SettingEmptyL( aProperties );
-
+
return setting;
}
@@ -303,30 +301,6 @@
}
// ---------------------------------------------------------------------------
-// Gets empty status of given HSPS entry
-// ---------------------------------------------------------------------------
-//
-TBool CMCSPluginSettingsModel::SettingEmptyL(
- RPointerArray<HSPluginSettingsIf::CPropertyMap>& aProperties )
- {
-
- for( TInt i = 0; i <aProperties.Count(); i++ )
- {
- TPtrC8 name = aProperties[i]->Name();
- if( name == KProperNameUid )
- {
- TPtrC8 value = aProperties[i]->Value();
- if( value.Compare(KMenuAttrInvokeSettingsUid) == 0 )
- {
- return ETrue;
- }
- }
- }
-
- return EFalse;
- }
-
-// ---------------------------------------------------------------------------
// Saves menuitem to HSPS to the given shortcut index
// ---------------------------------------------------------------------------
//
@@ -507,8 +481,8 @@
}
}
- // EFalse tells that modified settings are not stored to plugin reference
- User::LeaveIfError( iPluginSettings->SetSettingsL( *iPluginId, settingItems, EFalse ) );
+ // ETrue tells that modified settings are stored also to plugin reference
+ User::LeaveIfError( iPluginSettings->SetSettingsL( *iPluginId, settingItems, ETrue ) );
CleanupStack::PopAndDestroy(); // settingItems
}
@@ -552,19 +526,10 @@
// first, we need to check if the item is missing
// (application uninstalled or mmc card removed)
// If it is, we return "Undefined" application name instead
- // In case of empty item, it's own name is returned
if ( iSettings[ aIndex ].id == KErrNotFound )
{
- if ( iSettings[ aIndex ].empty )
- {
- const TDesC& caption = iAppList->EmptyText();
- TRAP_IGNORE( line.Set( ListBoxLineL( caption, aIndex ) ) )
- }
- else
- {
- const TDesC& caption = iAppList->UndefinedText();
- TRAP_IGNORE( line.Set( ListBoxLineL( caption, aIndex ) ) )
- }
+ const TDesC& caption = iAppList->UndefinedText();
+ TRAP_IGNORE( line.Set( ListBoxLineL( caption, aIndex ) ) )
}
else
{
@@ -601,7 +566,7 @@
//
const TSettingItem CMCSPluginSettingsModel::Item( TInt aIndex ) const
{
- TSettingItem setting = { KErrNotFound, EApplication, EFalse, EFalse };
+ TSettingItem setting = { KErrNotFound, EApplication, EFalse };
if ( aIndex >= 0 && aIndex < iSettings.Count() )
{
--- a/idlefw/plugins/profileplugin/src/caiprofileplugin.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/profileplugin/src/caiprofileplugin.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -263,6 +263,18 @@
}
}
+ // in case of Offline profile profile indicator is not shown
+ if ( observer->CanPublish( *this, EAiProfileContentActiveProfileName, EAiProfileContentActiveProfileName ) &&
+ iEngine->IsOffline() )
+ {
+ observer->Clean( *this, EAiProfileActiveProfileSilentChar, EAiProfileActiveProfileSilentChar );
+ observer->Clean( *this, EAiProfileActiveProfileIcon, 1 );
+ observer->Clean( *this, EAiProfileActiveProfileIcon, 2 );
+
+ // uncomment also this and respective policy lines in profiles.xml if whole widget needs to be hidden in AI3
+ //observer->Clean( *this, EAiProfileContentActiveProfileName, EAiProfileContentActiveProfileName );
+ }
+
if ( err == KErrNone )
{
err = observer->Commit( transactionId );
--- a/idlefw/plugins/sapidataplugin/src/sapidataplugin.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/sapidataplugin/src/sapidataplugin.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -241,9 +241,7 @@
if ( icon != NULL ) // Syntax correct but icon not found
{
aObserver->PublishPtr( *this, aContentId, icon , aContentId );
- CleanupStack::PushL( icon );
- iIconArray.AppendL( icon );
- CleanupStack::Pop( icon );
+ iIconArray.Append(icon);
}
else
{
@@ -287,7 +285,6 @@
{
// Take the ownership
CGulIcon* icon = CGulIcon::NewL(bitmap);
- CleanupStack::PushL( icon );
if( aMaskHandle != KErrBadHandle )
{
CFbsBitmap* mask = new (ELeave) CFbsBitmap();
@@ -297,8 +294,7 @@
}
}
aObserver->PublishPtr( *this, aContentId, icon , aContentId );
- iIconArray.AppendL( icon );
- CleanupStack::Pop( icon );
+ iIconArray.Append(icon);
}
else
{
--- a/idlefw/plugins/wrtdataplugin/src/wrtdataplugin.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/wrtdataplugin/src/wrtdataplugin.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -582,9 +582,7 @@
if ( icon != NULL ) // Syntax correct but icon not found
{
aObserver->PublishPtr( *this, aContentId, icon , aContentId );
- CleanupStack::PushL( icon );
- iIconArray.AppendL( icon );
- CleanupStack::Pop( icon );
+ iIconArray.Append(icon);
}
else
{
@@ -628,7 +626,6 @@
{
// Take the ownership
CGulIcon* icon = CGulIcon::NewL(bitmap);
- CleanupStack::PushL( icon );
if( aMaskHandle != KErrBadHandle )
{
CFbsBitmap* mask = new (ELeave) CFbsBitmap();
@@ -638,8 +635,7 @@
}
}
aObserver->PublishPtr( *this, aContentId, icon , aContentId );
- iIconArray.AppendL( icon );
- CleanupStack::Pop( icon );
+ iIconArray.Append(icon);
}
else
{
--- a/idlefw/plugins/wsplugin/src/numerickeyhandler.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/plugins/wsplugin/src/numerickeyhandler.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -196,10 +196,11 @@
}
// Homescreen should open dialer also with alpha characters, if dialer is in
- // mode that accepts alpha characters into number entry (ou1cimx1#299396)
+ // mode that accepts alpha characters into number entry.
+ // ou1cimx1#299396 & ou1cimx1#552069
const TInt KPhoneKeyStart = 33;
- const TInt KPhoneKeyEnd = 127;
+ const TInt KPhoneKeyEnd = 129;
return ( ( AllowAlphaNumericMode() ) && ( ( scanCode >= KPhoneKeyStart &&
scanCode <= KPhoneKeyEnd ) || modifiers & EModifierSpecial ) );
--- a/idlefw/src/framework/aicpsexecuteparam.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/src/framework/aicpsexecuteparam.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -201,7 +201,7 @@
//
void CAiCpsExecuteParam::AddActionL(const TDesC8& aAction)
{
- iActions.AppendL(aAction.AllocL());
+ iActions.Append(aAction.AllocL());
}
// End of file
--- a/idlefw/src/framework/aifw.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/src/framework/aifw.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -256,7 +256,9 @@
__TICK( "CAiFw::HandleUiReadyEventL" );
if ( iUiControllerManager->IsMainUiController( aUiController ) )
- {
+ {
+ iUiControllerManager->LoadUIDefinition();
+
TInt value( EIdlePhase1Ok );
RProperty::Get( KPSUidStartup, KPSIdlePhase1Ok, value );
@@ -300,8 +302,6 @@
__PRINTS( "*** CAiFw::HandleActivateUI" );
__TIME_MARK( time );
- iUiControllerManager->LoadUIDefinition();
-
iUiControllerManager->ActivateUI();
__TIME_ENDMARK( "CAiFw::HandleActivateUI, done", time );
--- a/idlefw/src/framework/aipluginfactory.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/src/framework/aipluginfactory.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -512,7 +512,7 @@
ConfigurePluginL( *plugin, info ) );
// Take plugin's ownership
- iPublishers.AppendL( plugin );
+ iPublishers.Append( plugin );
CleanupStack::Pop( plugin );
}
--- a/idlefw/src/framework/aiuicontrollermanager.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/src/framework/aiuicontrollermanager.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -55,9 +55,9 @@
User::LeaveIfError( aRepository.Get( KAiMainUIController, value ) );
CAiUiController* controller = CAiUiController::NewL( TUid::Uid( value ) );
+
+ iCreatedUICList.Append( value );
CleanupStack::PushL( controller );
-
- iCreatedUICList.AppendL( value );
iMainUiController = controller->MainInterface();
@@ -98,7 +98,7 @@
continue;
}
- iCreatedUICList.AppendL( value );
+ iCreatedUICList.Append( value );
CAiUiController* controller =
CAiUiController::NewL( TUid::Uid( value ) );
--- a/idlefw/src/idleint/aistate.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/src/idleint/aistate.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -96,17 +96,24 @@
//
void CActiveIdleState::UpdateActiveIdleState()
{
- const EPSActiveIdleState state =
- iIsIdleForeground ? EPSAiForeground : EPSAiBackground;
-
- TInt setResult =
- RProperty::Set(
+ TInt state( 0 );
+ TInt err( RProperty::Get( KPSUidAiInformation, KActiveIdleState, state ) );
+ if ( !iIsIdleForeground && KErrNone == err &&
+ EPSAiNumberEntry == (EPSActiveIdleState)state )
+ {
+ __PRINTS( "*** CActiveIdleState::UpdateActiveIdleState - Background & EPSAiNumberEntry, skip state update" );
+ }
+ else
+ {
+ state = iIsIdleForeground ? EPSAiForeground : EPSAiBackground;
+ err = RProperty::Set(
KPSUidAiInformation,
KActiveIdleState,
- state );
+ (EPSActiveIdleState)state );
- __PRINT( __DBG_FORMAT( "XAI: Set CActiveIdleState::UpdateActiveIdleState: KTelephonyIdleStatus=%d, P&S result=%d" ),
- TInt(state), setResult );
+ __PRINT( __DBG_FORMAT( "XAI: Set CActiveIdleState::UpdateActiveIdleState: KTelephonyIdleStatus=%d, P&S result=%d" ),
+ TInt(state), err );
+ }
}
// -----------------------------------------------------------------------------
--- a/idlefw/tsrc/devicestatusplugin/group/MT_DevStaPlg.mmp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/tsrc/devicestatusplugin/group/MT_DevStaPlg.mmp Wed Oct 13 14:53:46 2010 +0300
@@ -36,12 +36,15 @@
USERINCLUDE ../mt_devstaplg
USERINCLUDE ../stub/src
-USERINCLUDE ../../../plugins/devicestatus/inc
-USERINCLUDE ../../../../../homescreen/idlehomescreen/inc
-USERINCLUDE ../../../../../homescreen/idlehomescreen/nativeuicontroller/inc
-USERINCLUDE ../../../../idlefw/plugins/profileplugin/inc
-USERINCLUDE ../../../../../../app/homescreen/idlehomescreen/inc
-USERINCLUDE ../../../../../../app/homescreen/idlehomescreen/nativeuicontroller/inc
+USERINCLUDE ../../../../inc/common
+USERINCLUDE ../../../../inc/framework
+USERINCLUDE ../../../../group
+USERINCLUDE ../../../../plugins/devicestatus/inc
+USERINCLUDE ../../../../../../homescreen/idlehomescreen/inc
+USERINCLUDE ../../../../../../homescreen/idlehomescreen/nativeuicontroller/inc
+USERINCLUDE ../../../../../idlefw/plugins/profileplugin/inc
+USERINCLUDE ../../../../../../../app/homescreen/idlehomescreen/inc
+USERINCLUDE ../../../../../../../app/homescreen/idlehomescreen/nativeuicontroller/inc
APP_LAYER_SYSTEMINCLUDE
--- a/idlefw/tsrc/devicestatusplugin/mt_devstaplg/MT_DevStaPlg.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/tsrc/devicestatusplugin/mt_devstaplg/MT_DevStaPlg.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -559,7 +559,7 @@
{
User::Leave( KErrNoMemory );
}
-
+ /*
MAiPropertyExtension* ext = static_cast<MAiPropertyExtension*>( iPublisher->Extension( KExtensionUidProperty ) );
MAiContentRequest* request = static_cast<MAiContentRequest*>( ext->GetPropertyL( EAiContentRequest ) );
@@ -657,7 +657,7 @@
CStubDataHolder::Instance()->SetCurrentProfileL( KProfGeneral, EProfileGeneralId );
-
+ /*
MAiPropertyExtension* ext = static_cast<MAiPropertyExtension*>( iPublisher->Extension( KExtensionUidProperty ) );
MAiContentRequest* request = static_cast<MAiContentRequest*>( ext->GetPropertyL( EAiContentRequest ) );
--- a/idlefw/tsrc/devicestatusplugin/mt_devstaplg/contentobserver.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/tsrc/devicestatusplugin/mt_devstaplg/contentobserver.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -96,19 +96,19 @@
}
-TInt CContentObserver::StartTransaction(TInt /*aTxId*/)
+TInt CContentObserver::StartTransaction(TInt aTxId)
{
return 0;
}
-TInt CContentObserver::Commit(TInt /*aTxId*/)
+TInt CContentObserver::Commit(TInt aTxId)
{
return 0;
}
-TInt CContentObserver::CancelTransaction(TInt /*aTxId*/)
+TInt CContentObserver::CancelTransaction(TInt aTxId)
{
return 0;
}
@@ -120,7 +120,7 @@
}
-TInt CContentObserver::Publish(CHsContentPublisher& /*aPlugin*/, TInt aContent, TInt aResource, TInt aIndex )
+TInt CContentObserver::Publish(CHsContentPublisher& aPlugin, TInt aContent, TInt aResource, TInt aIndex )
{
RDebug::Print( _L("Publish(%d, %d, %d)"), aContent, aResource, aIndex );
CContentCache* cache = new( ELeave )CContentCache;
@@ -133,7 +133,7 @@
return 0;
}
-TInt CContentObserver::Publish(CHsContentPublisher& /*aPlugin*/, TInt aContent, const TDesC16& aText, TInt aIndex )
+TInt CContentObserver::Publish(CHsContentPublisher& aPlugin, TInt aContent, const TDesC16& aText, TInt aIndex )
{
RDebug::Print( _L("Publish(%d, \"%S\", %d)"), aContent, &aText, aIndex );
CContentCache* cache = new( ELeave )CContentCache;
@@ -147,7 +147,7 @@
}
-TInt CContentObserver::Publish(CHsContentPublisher& /*aPlugin*/, TInt aContent, const TDesC8& aBuf, TInt aIndex )
+TInt CContentObserver::Publish(CHsContentPublisher& aPlugin, TInt aContent, const TDesC8& aBuf, TInt aIndex )
{
RDebug::Print( _L("Publish(%d, Buf.Len=%d, %d)"), aContent, aBuf.Length(), aIndex );
CContentCache* cache = new( ELeave )CContentCache;
@@ -161,7 +161,7 @@
}
-TInt CContentObserver::Publish(CHsContentPublisher& /*aPlugin*/, TInt aContent, RFile& /*aFile*/, TInt aIndex )
+TInt CContentObserver::Publish(CHsContentPublisher& aPlugin, TInt aContent, RFile& aFile, TInt aIndex )
{
CContentCache* cache = new( ELeave )CContentCache;
CleanupStack::PushL( cache );
@@ -173,7 +173,7 @@
}
-TInt CContentObserver::Clean(CHsContentPublisher& /*aPlugin*/, TInt aContent, TInt aIndex)
+TInt CContentObserver::Clean(CHsContentPublisher& aPlugin, TInt aContent, TInt aIndex)
{
RDebug::Print( _L("Clean(%d, %d)"), aContent, aIndex );
CContentCache* cache = new( ELeave )CContentCache;
@@ -187,12 +187,12 @@
}
-TAny* CContentObserver::Extension(TUid /*aUid*/)
+TAny* CContentObserver::Extension(TUid aUid)
{
return NULL;
}
-TBool CContentObserver::RequiresSubscription( const THsPublisherInfo& /*aPublisherInfo*/ ) const
+TBool CContentObserver::RequiresSubscription( const THsPublisherInfo& aPublisherInfo ) const
{
return EFalse;
}
--- a/idlefw/tsrc/devicestatusplugin/stub/group/devstaplg.mmp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/tsrc/devicestatusplugin/stub/group/devstaplg.mmp Wed Oct 13 14:53:46 2010 +0300
@@ -29,12 +29,11 @@
#include <data_caging_paths.hrh>
#include <eunitcaps.h>
-//#include <platform/mw/aisystemuids.hrh>
+#include <platform/mw/aisystemuids.hrh>
TARGET aidevstaplg.dll
TARGETTYPE PLUGIN
-UID 0x10009D8D 0x102750F7 //AI_UID_ECOM_DLL_CONTENTPUBLISHER_DEVSTAPLUGIN
-
+UID 0x10009D8D AI_UID_ECOM_DLL_CONTENTPUBLISHER_DEVSTAPLUGIN
CAPABILITY EUNIT_CAPS
--- a/idlefw/tsrc/devicestatusplugin/stub/src/profileengine.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/tsrc/devicestatusplugin/stub/src/profileengine.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -200,9 +200,7 @@
TProfileRingingVolume CProfileEngine::TempRingingVolumeL() const
- {
- TProfileRingingVolume vol = EProfileRingingVolumeLevel1;
- return vol;
+ {
}
@@ -212,9 +210,7 @@
TProfileRingingVolume CProfileEngine::TempMediaVolumeL() const
- {
- TProfileRingingVolume vol = EProfileRingingVolumeLevel1;
- return vol;
+ {
}
--- a/idlefw/tsrc/framework/ut_aifw/ut_aipluginfactory/src/ut_aipluginfactory.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/tsrc/framework/ut_aifw/ut_aipluginfactory/src/ut_aipluginfactory.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -177,29 +177,32 @@
THsPublisherInfo unknown(
TUid::Uid( KUnknownUid ), KUnknown, KNs1 );
- // create 2 same without waiting first to finnish.
- // Second won't be appended to load queue.
+ // create 2 same without waiting first to finnish. Second should return
+ // KErrAlreadyExists
TAiFwPublisherInfo info( data, TAiFwCallback( CallBack, this ), EAiFwSystemStartup );
iFactory->LoadPlugin( info );
iFactory->LoadPlugin( info );
iWait->Start();
+ EUNIT_ASSERT_EQUALS( iResult, KErrAlreadyExists );
EUNIT_ASSERT_EQUALS( iFactory->PluginByInfo( data ) != NULL, ETrue );
-
+
// wait for destroy to finnish
iFactory->DestroyPlugin( info );
iPeriodic->Start( KDestroyDelay, KDestroyDelay, TCallBack( TimerCallBack, this ) );
iWait->Start();
EUNIT_ASSERT_EQUALS( iFactory->PluginByInfo( data ) == NULL, ETrue );
EUNIT_ASSERT_EQUALS( iFactory->Publishers().Count(), 0 );
-
- // create 2 same and wait first to finnish.
- // Second won't be appended to load queue.
+
+ // create 2 same and wait first to finnish. Second should return
+ // KErrAlreadyExists
iFactory->LoadPlugin( info );
iWait->Start();
EUNIT_ASSERT_EQUALS( iResult, KErrNone );
EUNIT_ASSERT_EQUALS( iFactory->PluginByInfo( data ) != NULL, ETrue );
iFactory->LoadPlugin( info );
+ iWait->Start();
+ EUNIT_ASSERT_EQUALS( iResult, KErrAlreadyExists );
EUNIT_ASSERT_EQUALS( iFactory->PluginByInfo( data ) != NULL, ETrue );
// Test missing namespace
--- a/idlefw/tsrc/mcsplugin/ut_mcsplugin/ut_mcspluginpublisher.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/idlefw/tsrc/mcsplugin/ut_mcsplugin/ut_mcspluginpublisher.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -47,13 +47,19 @@
_LIT( KMenuMailboxIconId, "16388" );
_LIT( KMenuMailboxMaskId, "16389" );
_LIT( KMenuTypeMailbox, "menu:mailbox" );
+_LIT( KIcon, "icon" );
_LIT8( KProperNameType, "type" );
+_LIT8( KProperNameParam, "param" );
_LIT8( KProperNameUid, "uid" );
+_LIT8( KProperNameView, "view" );
+_LIT8( KProperNameLocked, "locked" );
_LIT8( KProperValueBookmark, "bookmark" );
_LIT8( KProperValueFolder, "folder" );
_LIT8( KProperValueMailbox, "mailbox" );
_LIT8( KMenuAttrUndefUid, "0x99999991" );
+_LIT8( KMenuAttrViewTest, "view:test" );
+_LIT8( KMenuAttrParamTest, "param:test" );
_LIT( KTestName, "test:name" );
_LIT( KTestIconAttr, "icon_attributes" );
@@ -197,7 +203,7 @@
void UT_MCSPluginPublisher::Teardown()
{
User::LeaveIfError( iPluginSettings->SetSettingsL( KNameSpace,
- iSettings, EFalse ));
+ iSettings, ETrue ));
iSettings.ResetAndDestroy();
@@ -225,8 +231,8 @@
data->SetNameL( KTestName );
data->SetValueL( KTestValue );
- EUNIT_ASSERT_EQUALS( *data->Name(), KTestName );
- EUNIT_ASSERT_EQUALS( *data->Value(), KTestValue );
+ EUNIT_ASSERT_EQUALS( data->Name(), KTestName );
+ EUNIT_ASSERT_EQUALS( data->Value(), KTestValue );
CleanupStack::PopAndDestroy( data );
}
@@ -272,7 +278,7 @@
}
User::LeaveIfError( iPluginSettings->SetSettingsL( KNameSpace, settings,
- EFalse ));
+ ETrue) );
iMCSPlugin->iEngine->iPluginData->UpdateDataL();
CMCSData& itemData = iMCSPlugin->iEngine->iPluginData->DataItemL( 0 );
@@ -303,7 +309,7 @@
}
User::LeaveIfError( iPluginSettings->SetSettingsL( KNameSpace, settings,
- EFalse ));
+ ETrue ));
iMCSPlugin->iEngine->iPluginData->UpdateDataL();
CMCSData& itemData = iMCSPlugin->iEngine->iPluginData->DataItemL( 0 );
@@ -334,7 +340,7 @@
}
User::LeaveIfError( iPluginSettings->SetSettingsL( KNameSpace, settings,
- EFalse ));
+ ETrue));
iMCSPlugin->iEngine->iPluginData->UpdateDataL();
CMCSData& itemData = iMCSPlugin->iEngine->iPluginData->DataItemL(0);
--- a/layers.sysdef.xml Wed Sep 15 12:32:36 2010 +0300
+++ b/layers.sysdef.xml Wed Oct 13 14:53:46 2010 +0300
@@ -23,7 +23,7 @@
<layer name="unit_test_layer">
<module name="homescreensrv_unit_tests">
- <unit unitID="hsdo.idlefw.test" name="idlefw.test" bldFile="&layer_real_source_path;/idlefw/tsrc/group" mrp="" />
+ <unit unitID="hsdo.idlefw.test" name="idlefw.test" bldFile="&layer_real_source_path;/idlefw/Internal/tsrc/group" mrp="" />
</module>
</layer>
--- a/menucontentsrv/group/mcsmenu.mmp Wed Sep 15 12:32:36 2010 +0300
+++ b/menucontentsrv/group/mcsmenu.mmp Wed Oct 13 14:53:46 2010 +0300
@@ -12,7 +12,7 @@
* Contributors:
*
* Description:
-* Version : %version: sa1spcx1#11.1.7.1.9 % << Don't touch! Updated by Synergy at check-out.
+* Version : %version: sa1spcx1#11.1.7.1.8 % << Don't touch! Updated by Synergy at check-out.
*
*/
@@ -80,7 +80,6 @@
SOURCE mcsmmcobserver.cpp
SOURCE mcsfreespaceobserver.cpp
SOURCE mcsinstallnotifier.cpp
-SOURCE mcsinstallstrategy.cpp
SOURCE mcsgetlistcreatorinterface.cpp
SOURCE mcsgetlisthandler.cpp
--- a/menucontentsrv/group/mcsmenusrv.mmp Wed Sep 15 12:32:36 2010 +0300
+++ b/menucontentsrv/group/mcsmenusrv.mmp Wed Oct 13 14:53:46 2010 +0300
@@ -12,7 +12,7 @@
* Contributors:
*
* Description:
-* Version : %version: sa1spcx1#5.1.10 % << Don't touch! Updated by Synergy at check-out.
+* Version : %version: sa1spcx1#5.1.9 % << Don't touch! Updated by Synergy at check-out.
*
*/
@@ -27,7 +27,7 @@
TARGET mcsmenuserver.exe
TARGETTYPE exe
UID 0x1000008c MENU_SRV_UID3
-CAPABILITY AllFiles ProtServ ReadDeviceData ReadUserData
+CAPABILITY AllFiles ProtServ ReadDeviceData
VENDORID VID_DEFAULT
EPOCSTACKSIZE 0x5000
--- a/menucontentsrv/srvinc/mcsdrmhandler.h Wed Sep 15 12:32:36 2010 +0300
+++ b/menucontentsrv/srvinc/mcsdrmhandler.h Wed Oct 13 14:53:46 2010 +0300
@@ -32,24 +32,24 @@
* @lib mcsmenu.lib
* @since S60 v5.0
*/
-NONSHARABLE_CLASS( CMcsDrmHandler ):
+NONSHARABLE_CLASS( CMcsDrmHandler ):
public CBase,
public MMcsInstallListener,
public MMcsDrmObserver,
public MMcsDrmAppScanner
{
public:
-
+
/**
* Two-phased constructor. Leaves on failure.
* @return The constructed object.
*/
-
- static CMcsDrmHandler* NewL(
+
+ static CMcsDrmHandler* NewL(
CMenuSrvEng& aSrvEng,
CMenuSrvEngUtils& aUtils,
CMcsCacheHandler& aCacheHandler );
-
+
/**
* Destructor.
* @since S60 v5.0
@@ -58,25 +58,24 @@
* @panic None.
*/
virtual ~CMcsDrmHandler();
-
+
void HandleDrmEvent( TUid aUid );
-
+
void HandleDrmAppEvent();
-
+
void EngineEvents( TInt aFolder, TInt aEvents );
/**
* Handle Install Event
*/
- void HandleInstallNotifyL( TUid aPackageUid,
- CMcsInstallNotifier::TNotificationType aNotificationType );
-
+ void HandleInstallNotifyL(TInt aPackageUid);
+
private:
/**
* Constructor.
*/
- CMcsDrmHandler(
+ CMcsDrmHandler(
CMenuSrvEng& aSrvEng,
CMenuSrvEngUtils& aUtils,
CMcsCacheHandler& aCacheHandler );
@@ -85,27 +84,27 @@
* 2nd phase constructor.
*/
void ConstructL();
-
- void AddRemoveObserversL(
+
+ void AddRemoveObserversL(
const RArray<TUid>& aDrmProtectedArray );
-
+
TInt AppFolderIdL( TUid aUid );
-
+
private: // data
-
+
RMcsDrmObserverManager iObserversManager;
-
-
+
+
CMenuSrvEng& iSrvEng; ///< Menu Engine. Not own.
-
+
CMenuSrvEngUtils& iUtils;
-
+
CMcsCacheHandler& iCacheHandler;
-
+
CMcsDrmScanner* iScanner;
-
+
CMcsInstallNotifier* iInstallNotifier;
-
+
};
#endif // __MCSDRMHANDLER_H__
--- a/menucontentsrv/srvinc/mcsinstallnotifier.h Wed Sep 15 12:32:36 2010 +0300
+++ b/menucontentsrv/srvinc/mcsinstallnotifier.h Wed Oct 13 14:53:46 2010 +0300
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies).
+* 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"
@@ -11,8 +11,8 @@
*
* Contributors:
*
-* Description: This class implements MMcsGetListCreatorInterface. It builds tree
-* output list for getlist operation
+* Description: This class implements MMcsGetListCreatorInterface. It builds tree
+* output list for getlist operation
*
*
*/
@@ -20,92 +20,9 @@
#ifndef MCSINSTALLNOTIFIER_H_
#define MCSINSTALLNOTIFIER_H_
-#include <sacls.h>
#include <e32base.h>
#include <e32property.h>
-class CMcsNotifierStrategy;
-class MMcsInstallListener;
-
-/**
- * MCS Install notifier.
- *
- * @since S60 v5.0
- */
-NONSHARABLE_CLASS( CMcsInstallNotifier ) : public CActive
- {
-public:
-
- /**
- * Enum defining notification type.
- */
- enum TNotificationType
- {
- ENoNotification, ///< No notification.
- ESisInstallNotification, ///< System installation notification.
- EJavaInstallNotification, ///< Java instalation and uninstallation notification.
- };
-
- /**
- * Creates an instance of CCaInstallNotifier.
- * @param aNotifier Reference to notifier interface.
- * @param aNotificationType Notification type.
- */
- static CMcsInstallNotifier* NewL( MMcsInstallListener& aListener,
- TNotificationType aNotificationType );
-
- /**
- * Destructor.
- */
- virtual ~CMcsInstallNotifier();
-
-private:
-
- /**
- * Constructor.
- * @param aListener Reference to listener interface.
- */
- CMcsInstallNotifier( MMcsInstallListener& aListener );
-
- /**
- * Symbian 2nd phase constructor.
- * @param aNotificationType Notification type.
- */
- void ConstructL( TNotificationType aNotificationType );
-
- /**
- * From CActive.
- */
- void DoCancel();
-
- /**
- * From CActive.
- */
- void RunL();
-
- /**
- * From CActive.
- */
- TInt RunError( TInt aError );
-
-private:
-
- /**
- * RProperty - own.
- */
- RProperty iProperty;
-
- /**
- * MMcsInstallListener - own.
- */
- MMcsInstallListener& iListener;
-
- /*
- * Notification strategy - own.
- */
- CMcsNotifierStrategy* iNotifierStrategy;
-
- };
/**
* Interface for updating after installer events.
@@ -114,16 +31,109 @@
*/
class MMcsInstallListener
{
-public:
-
+protected:
/**
- * Pure virtual method.
- * @param aUid uid of installed application.
- * @param aOperation operation type, see TSASwisOperation.
+ * Enum defining the purpouse of the installation event.
*/
- virtual void HandleInstallNotifyL( TUid aUid,
- CMcsInstallNotifier::TNotificationType aNotificationType ) = 0;
+ enum TInstOp
+ {
+ EInstOpNone = 0x00000000,
+ EInstOpInstall = 0x00000001,
+ EInstOpUninstall = 0x00000002,
+ EInstOpRestore = 0x00000004
+ };
+public:
+ virtual void HandleInstallNotifyL(TInt aEvent) = 0;
};
+/**
+ * MCS Install notifier.
+ *
+ * @since S60 v5.0
+ */
+NONSHARABLE_CLASS( CMcsInstallNotifier ) :
+ public CActive
+ {
+ /**
+ * Enum defining the purpouse of the installation event.
+ */
+ enum TInstOp
+ {
+ EInstOpNone = 0x00000000,
+ EInstOpInstall = 0x00000001,
+ EInstOpUninstall = 0x00000002,
+ EInstOpRestore = 0x00000004
+ };
+
+ enum TInstOpStatus
+ {
+ EInstOpStatusNone = 0x00000000,
+ EInstOpStatusSuccess = 0x00000100,
+ EInstOpStatusAborted = 0x00000200
+ };
+public:
+
+ /**
+ * Creates an instance of CMCSInstallNotifier implementation.
+ * @param aNotifier Reference to notifier interface.
+ * @param aCategory Package uid.
+ * @param aKey Key for central repository.
+ */
+ static CMcsInstallNotifier* NewL(MMcsInstallListener& aListener, TInt aKey );
+
+ /**
+ * Destructor.
+ */
+ virtual ~CMcsInstallNotifier();
+
+private:
+
+ /**
+ * Constructor.
+ * @param aNotifier Reference to notifier interface.
+ * @param aCategory Package uid.
+ * @param aKey Key for central repository.
+ */
+ CMcsInstallNotifier( MMcsInstallListener& aListener, TInt aKey );
+
+ /**
+ * Symbian 2nd phase constructor.
+ */
+ void ConstructL();
+
+ /**
+ * From CActive.
+ */
+ void DoCancel();
+
+ /**
+ * From CActive.
+ */
+ void RunL();
+
+ /**
+ * From CActive.
+ */
+ TInt RunError( TInt aError );
+
+private:
+ /**.
+ * Own.
+ */
+ RProperty iProperty;
+
+ /**
+ * Interface for notifying changes in folder.
+ * Not Own.
+ */
+ MMcsInstallListener& iListener;
+
+ /*
+ *
+ */
+ TInt iKey;
+ };
+
+
#endif /* MCSINSTALLNOTIFIER_H_ */
--- a/menucontentsrv/srvinc/mcsinstallstrategy.h Wed Sep 15 12:32:36 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,169 +0,0 @@
-/*
- * 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: ?Description
- *
- */
-
-#ifndef MCSINSTALLSTRATEGY_H
-#define MCSINSTALLSTRATEGY_H
-
-#include "mcsinstallnotifier.h"
-#include <e32base.h>
-
-namespace Swi
- {
- class RSisRegistryEntry;
- }
-
-/**
- * Strategy interface.
- *
- * @since S60 v5.0
- */
-class CMcsNotifierStrategy: public CBase
- {
-public:
-
- /**
- * Notifies listener with changes in property.
- */
- virtual void NotifyListenerL() = 0;
-
-protected:
-
- /**
- * Constructor.
- * @param aProperty to read values from.
- * @param aListener listener to notify.
- */
- CMcsNotifierStrategy(
- RProperty& aProperty,
- MMcsInstallListener& aListener );
-
-protected:
-
- /**
- * Property. Not own.
- */
- RProperty& iProperty;
-
- /**
- * Listener. Not own.
- */
- MMcsInstallListener& iListener;
-
- };
-
-/**
- * Swi Install strategy.
- *
- * @since S60 v5.0
- */
-NONSHARABLE_CLASS( CMcsSwiInstallStrategy ): public CMcsNotifierStrategy
- {
-public:
-
- /**
- * Creates an instance of CCaInstallStrategy.
- * @param aProperty to read values from.
- * @param aListener listener to notify.
- */
- static CMcsSwiInstallStrategy* NewL(
- RProperty& aProperty,
- MMcsInstallListener& aListener );
-
- /**
- * Notifies listener with changes in property.
- */
- void NotifyListenerL();
-
-private:
-
- /**
- * Constructor.
- * @param aProperty to read values from.
- * @param aListener listener to notify.
- */
- CMcsSwiInstallStrategy(
- RProperty& aProperty,
- MMcsInstallListener& aListener );
-
- /**
- * Symbian 2nd phase constructor.
- */
- void ConstructL();
-
- /**
- * Handle Install Event.
- * @param aUid installed/uninstalled app uid.
- */
- void HandleInstallNotifyL( TInt aUid );
-
- /**
- * Notifies storage abaut change for aPackageEntry related app.
- * @param aPackageEntry application package entry.
- */
- void NotifyL( Swi::RSisRegistryEntry & aPackageEntry );
-
- };
-
-/**
- * Mcs Java install strategy.
- *
- * @since S60 v5.0
- */
-NONSHARABLE_CLASS( CMcsJavaInstallStrategy ): public CMcsNotifierStrategy
- {
-public:
-
- /**
- * Creates an instance of CCaInstallStrategy.
- * @param aProperty to read values from.
- * @param aListener listener to notify.
- */
- static CMcsJavaInstallStrategy* NewL(
- RProperty& aProperty,
- MMcsInstallListener& aListener );
-
- /**
- * Notifies listener with changes in property.
- */
- void NotifyListenerL();
-
-private:
-
- /**
- * Constructor.
- * @param aProperty to read values from.
- * @param aListener listener to notify.
- */
- CMcsJavaInstallStrategy(
- RProperty& aProperty,
- MMcsInstallListener& aListener );
-
- /**
- * Symbian 2nd phase constructor.
- */
- void ConstructL();
-
- /**
- * Handle Install Event.
- * @param aUid installed/uninstalled app uid.
- */
- void HandleInstallNotifyL( TUid aPackageUid );
-
- };
-
-#endif /* MCSINSTALLSTRATEGY_H */
-// End of File
--- a/menucontentsrv/srvinc/menusrvappscanner.h Wed Sep 15 12:32:36 2010 +0300
+++ b/menucontentsrv/srvinc/menusrvappscanner.h Wed Oct 13 14:53:46 2010 +0300
@@ -21,7 +21,6 @@
#include <e32base.h>
#include <apgcli.h>
#include <apgnotif.h>
-#include <driveinfo.h>
#include <cenrepnotifyhandler.h>
#include "menuengoperation.h"
#include "mcssatnotifier.h"
@@ -29,8 +28,7 @@
#include "mcsfreespaceobserver.h"
#include "mcsmenuitem.h"
#include "mcsmenunotifier.h"
-#include "mcsinstallnotifier.h"
-
+#include <driveinfo.h>
// FORWARD DECLARATION
@@ -66,7 +64,7 @@
NONSHARABLE_CLASS( CMenuSrvAppScanner )
: public CActive, public MMenuEngOperation, public MApaAppListServObserver,
public MCenRepNotifyHandlerCallback, public MMcsSATNotifierCallback,
- MMcsFreeSpaceObserver, MMcsInstallListener
+ MMcsFreeSpaceObserver
{
public: // Constructor
@@ -84,13 +82,6 @@
CMenuEng& aEng,
CMenuSrvEngUtils& aSrvEngUtils );
-public:
- /**
- * Schedule appscanner run.
- * Self complete active object.
- */
- void ScheduleScan();
-
private: // Constructors and destructor
/**
@@ -144,18 +135,14 @@
private: // from MApaAppListServObserver
- /**
- * Application list event.
- * @param aEvent only one type event exists.
- */
void HandleAppListEvent( TInt aEvent );
private: // from MCenRepNotifyHandlerCallback
/**
* Called if one of CR keys has changed
- * @param aKey Id of the key that has changed.
- * @param aNewValue The new value of the key.
+ * @param aId Id of the key that has changed.
+ * @param aNewValue The new value of the key.
*/
void HandleNotifyString( TUint32 aKey, const TDesC16& aNewValue );
@@ -169,15 +156,12 @@
*/
void SATChangeL();
-private: // from MMcsInstallListener
-
- /**
- * Called application is installed.
- * @param aUid uid of an application.
- * @param aOperation operation type.
- */
- void HandleInstallNotifyL( TUid aUid,
- CMcsInstallNotifier::TNotificationType aNotificationType );
+public:
+ /**
+ * Schedule appscanner run.
+ * Self complete active object.
+ */
+ void ScheduleScan();
private: // new methods
@@ -191,28 +175,7 @@
* Add new menu item referring to this application.
* @param aItem menu item.
*/
- void HandleMissingFlagUpdateL(
- const TMenuItem& aItem, const CMenuSrvAppAttributes& aApaItem );
-
- /**
- * Notifies engine abaut application installation.
- */
- void InstallationNotifyL();
-
- /**
- * Removes uid from installed packages array.
- * @param aUid application uid.
- */
- void RemoveFromInstalledPackages( TUid aUid );
-
- /**
- * Removes uid from installed packages array.
- * @param aUid application uid.
- * @param aId Item ID.
- * @param aEvent event for engine to append.
- */
- CMenuEngObject& ModifiableObjectL( TUid aUid, TInt aId,
- TInt aEvent = RMenuNotifier::EItemAttributeChanged );
+ void HandleMissingFlagUpdateL( const TMenuItem& aItem );
/**
* Updates hidden flag.
@@ -255,7 +218,7 @@
/**
*/
- void SetHiddenL( const TDesC& aHiddenAppUid,
+ void SetHidden( const TDesC& aHiddenAppUid,
RPointerArray<CMenuSrvAppAttributes>& aArray );
/**
@@ -389,7 +352,7 @@
* @return ETrue if drive is in use.
*/
TBool IsDriveInUse(
- const DriveInfo::TDefaultDrives& aDefaultDrive );
+ const DriveInfo::TDefaultDrives& aDefaultDrive );
/**
TODO
@@ -430,7 +393,7 @@
TODO
*/
void UpdateApplicationItemL(
- RArray<TMenuItem>& aMcsItems,
+ RArray<TMenuItem>& aMcsItems,
const CMenuSrvAppAttributes& aApaItem,
TUint aMmcId,
TBool isLegacy );
@@ -490,12 +453,6 @@
CMcsFreeSpaceObserver* iFreeSpaceObserver;
TBool iOpStatus;
-
- RArray<TUid> iInstalledPackages; ///< Own.
-
- CMcsInstallNotifier* iSisInstallNotifier; ///< Native app notifier. Own.
- CMcsInstallNotifier* iJavaInstallNotifier; ///< Java app notifier. Own.
-
};
#endif // __MENUSRVAPPSCANNER_H__
--- a/menucontentsrv/srvsrc/mcscachehandler.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/menucontentsrv/srvsrc/mcscachehandler.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -11,7 +11,7 @@
*
* Contributors:
*
-* Description: Used for receive SIM Application name, icon or
+* Description: Used for receive SIM Application name, icon or
* visibility information.
*
*/
@@ -33,7 +33,7 @@
// Two-phased constructor.
// -----------------------------------------------------------------------------
//
-EXPORT_C CMcsCacheHandler* CMcsCacheHandler::NewL(
+EXPORT_C CMcsCacheHandler* CMcsCacheHandler::NewL(
CMenuEng& aEng,
CMenuSrvEngUtils& aUtils )
{
@@ -44,7 +44,7 @@
return self;
}
-// -----------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Destructor
// -----------------------------------------------------------------------------
CMcsCacheHandler::~CMcsCacheHandler()
@@ -58,7 +58,7 @@
// might leave.
// -----------------------------------------------------------------------------
//
-CMcsCacheHandler::CMcsCacheHandler(
+CMcsCacheHandler::CMcsCacheHandler(
CMenuEng& aEng,
CMenuSrvEngUtils& aUtils ): iEng( aEng ), iUtils( aUtils )
{
@@ -75,7 +75,7 @@
// -----------------------------------------------------------------------------
// -----------------------------------------------------------------------------
-//
+//
void CMcsCacheHandler::HandleRemoveId( TInt aId )
{
iAttrCache.RemoveId( aId );
@@ -83,7 +83,7 @@
// -----------------------------------------------------------------------------
// -----------------------------------------------------------------------------
-//
+//
void CMcsCacheHandler::HandleRemoveAttribute( TInt aId, const TDesC& aAttrName )
{
iAttrCache.RemoveAttribute(aId, aAttrName);
@@ -91,7 +91,7 @@
// -----------------------------------------------------------------------------
// -----------------------------------------------------------------------------
-//
+//
void CMcsCacheHandler::EngineEvents( TInt aEvents )
{
if( aEvents & RMenuNotifier::EItemsAddedRemoved )
@@ -100,7 +100,7 @@
}
if( aEvents & RMenuNotifier::EItemAttributeChanged )
{
- TRAP_IGNORE( RemoveItemsWithChangedAttributesL() );
+ TRAP_IGNORE(RemoveItemsWithChangedAttributesL());
}
}
@@ -118,9 +118,9 @@
TInt id = iAttrCache[i]->Id();
TPtrC name = iAttrCache[i]->Name();
TPtrC valueCache = iAttrCache[i]->Value();
-
+
TPtrC valueXml(KNullDesC);
-
+
exist = iEng.ObjectL(id).FindAttribute( name, valueXml, dummy );
if( exist && valueXml != valueCache )
{
@@ -151,4 +151,4 @@
}
}
-// End of File
+// End of File
--- a/menucontentsrv/srvsrc/mcsdrmhandler.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/menucontentsrv/srvsrc/mcsdrmhandler.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -11,7 +11,7 @@
*
* Contributors:
*
-* Description: Used for receive SIM Application name, icon or
+* Description: Used for receive SIM Application name, icon or
* visibility information.
*
*/
@@ -41,12 +41,12 @@
// -----------------------------------------------------------------------------
//
-CMcsDrmHandler* CMcsDrmHandler::NewL(
+CMcsDrmHandler* CMcsDrmHandler::NewL(
CMenuSrvEng& aSrvEng,
CMenuSrvEngUtils& aUtils,
CMcsCacheHandler& aCacheHandler )
{
- CMcsDrmHandler* self = new( ELeave )
+ CMcsDrmHandler* self = new( ELeave )
CMcsDrmHandler( aSrvEng, aUtils, aCacheHandler );
CleanupStack::PushL( self );
self->ConstructL();
@@ -54,7 +54,7 @@
return self;
}
-// -----------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// Destructor
// -----------------------------------------------------------------------------
CMcsDrmHandler::~CMcsDrmHandler()
@@ -70,10 +70,10 @@
// might leave.
// -----------------------------------------------------------------------------
//
-CMcsDrmHandler::CMcsDrmHandler(
+CMcsDrmHandler::CMcsDrmHandler(
CMenuSrvEng& aSrvEng,
CMenuSrvEngUtils& aUtils,
- CMcsCacheHandler& aCacheHandler ):
+ CMcsCacheHandler& aCacheHandler ):
iObserversManager( aUtils ), iSrvEng( aSrvEng ),
iUtils( aUtils ), iCacheHandler( aCacheHandler )
{
@@ -87,117 +87,148 @@
void CMcsDrmHandler::ConstructL()
{
iScanner = CMcsDrmScanner::NewL( *this, iSrvEng, iUtils );
- iInstallNotifier = CMcsInstallNotifier::NewL(
- *this, CMcsInstallNotifier::EJavaInstallNotification );
+ iInstallNotifier = CMcsInstallNotifier::NewL(*this, KPSUidJavaLatestInstallation);
}
// -----------------------------------------------------------------------------
// -----------------------------------------------------------------------------
-//
+//
TInt CMcsDrmHandler::AppFolderIdL( TUid aUid )
{
- RArray<TMenuItem> mcsItems;
+ RArray<TMenuItem> mcsItems;
CleanupClosePushL( mcsItems );
-
+
TInt root;
iSrvEng.Engine().RootFolderL( root );
TMenuSrvTypeAttrFilter appFilter;
- appFilter.SetType( KMenuTypeApp() );
-
+ appFilter.SetType( KMenuTypeApp() );
+
TBuf<KUidChars> uidString;
MenuSrvUtil::UidToStringL( aUid.iUid, uidString, 0, EHex );
-
+
appFilter.SetAttr( KMenuAttrUid(), uidString );
iSrvEng.Engine().GetItemsL( mcsItems, root, &appFilter, ETrue );
-
+
TInt folderId = KErrNotFound;
if (mcsItems.Count())
{
folderId = mcsItems[0].Parent();
iCacheHandler.HandleRemoveAttribute(mcsItems[0].Id(), KMenuAttrDrmProtection);
}
-
+
CleanupStack::PopAndDestroy( &mcsItems );
return folderId;
}
// -----------------------------------------------------------------------------
// -----------------------------------------------------------------------------
-//
+//
void CMcsDrmHandler::HandleDrmEvent( TUid aUid )
{
TRAP_IGNORE(
- iSrvEng.Engine().AppendNotifyL( AppFolderIdL( aUid ),
- RMenuNotifier::EItemAttributeChanged );
- iScanner->RemoveObserverAndScanL( aUid );
- );
+ iSrvEng.Engine().AppendNotifyL( AppFolderIdL( aUid ),
+ RMenuNotifier::EItemAttributeChanged );
+ iScanner->RemoveObserverAndScanL( aUid );
+ );
}
// -----------------------------------------------------------------------------
// -----------------------------------------------------------------------------
-//
+//
void CMcsDrmHandler::HandleDrmAppEvent()
{
TRAP_IGNORE( AddRemoveObserversL(
- iScanner->DrmProtectedAppArray() ) );
+ iScanner->DrmProtectedAppArray() ) );
}
// -----------------------------------------------------------------------------
// -----------------------------------------------------------------------------
-//
-void CMcsDrmHandler::AddRemoveObserversL(
- const RArray<TUid>& aDrmProtectedArray )
+//
+void CMcsDrmHandler::AddRemoveObserversL(
+ const RArray<TUid>& aDrmProtectedArray )
{
- iObserversManager.RemoveMissingObservers( aDrmProtectedArray );
+ iObserversManager.RemoveMissingObservers( aDrmProtectedArray );
iObserversManager.CreateObserversL( aDrmProtectedArray, *this );
- }
+ }
// -----------------------------------------------------------------------------
// -----------------------------------------------------------------------------
-//
+//
void CMcsDrmHandler::EngineEvents( TInt /*aFolder*/, TInt aEvents )
{
if ( aEvents & RMenuNotifier::EItemsAddedRemoved )
{
iScanner->Scan();
- }
+ }
}
// ---------------------------------------------------------
-//
+// CMcsDrmHandler::HandleInstallNotifyL
// ---------------------------------------------------------
//
-void CMcsDrmHandler::HandleInstallNotifyL( TUid aPackageUid,
- CMcsInstallNotifier::TNotificationType /*aNotificationType*/ )
- {
- if( aPackageUid != TUid::Null() )
- {
- if( ( iScanner->DrmExpiredAppArray() ).Find( aPackageUid )
- != KErrNotFound )
- {
- HandleDrmEvent( aPackageUid );
- }
- else
- {
- iObserversManager.RefreshObserverL(
- iScanner->DrmProtectedAppArray(), aPackageUid, *this );
- }
- }
- else
- {
- for( TInt i = 0; i < iScanner->DrmProtectedAppArray().Count(); i++ )
- {
- iObserversManager.RefreshObserverL(
- iScanner->DrmProtectedAppArray(),
- iScanner->DrmProtectedAppArray()[i], *this );
- }
- for( TInt i = 0; i < iScanner->DrmExpiredAppArray().Count(); i++ )
- {
- HandleDrmEvent( iScanner->DrmExpiredAppArray()[i] );
- }
- }
+void CMcsDrmHandler::HandleInstallNotifyL( TInt aPackageUid )
+ {
+ RArray<TUid> uids;
+ CleanupClosePushL( uids );
+
+ Java::CJavaRegistry* javaRegistry;
+ javaRegistry = Java::CJavaRegistry::NewLC();
+
+ Java::CJavaRegistryEntry* regEntry =
+ javaRegistry->RegistryEntryL( TUid::Uid(aPackageUid) );
+
+ if( regEntry )
+ {
+ CleanupStack::PushL( regEntry );
+
+ Java::TJavaRegistryEntryType entryType = regEntry->Type();
+
+ if ( ( entryType >= Java::EGeneralPackage ) &&
+ (entryType < Java::EGeneralApplication) )
+ {
+ //package entry
+ Java::CJavaRegistryPackageEntry* regPackageEntry =
+ static_cast<Java::CJavaRegistryPackageEntry*>( regEntry );
+ regPackageEntry->GetEmbeddedEntries( uids );
+ }
+ else
+ {
+ //application entry
+ uids.AppendL( regEntry->Uid() );
+ }
+
+ CleanupStack::PopAndDestroy( regEntry );
+ for ( TInt i = 0; i< uids.Count(); i++ )
+ {
+ if ( ( iScanner->DrmExpiredAppArray()).Find(uids[i]) != KErrNotFound )
+ {
+ HandleDrmEvent( uids[i] );
+ }
+ else
+ {
+ iObserversManager.RefreshObserverL( iScanner->DrmProtectedAppArray(),
+ uids[i], *this );
+ }
+ }
+ }
+ else
+ {
+ for ( TInt i = 0; i< iScanner->DrmProtectedAppArray().Count(); i++ )
+ {
+ iObserversManager.RefreshObserverL( iScanner->DrmProtectedAppArray(),
+ iScanner->DrmProtectedAppArray()[i], *this );
+ }
+ for ( TInt i = 0; i< iScanner->DrmExpiredAppArray().Count(); i++ )
+ {
+ HandleDrmEvent( iScanner->DrmExpiredAppArray()[i] );
+ }
+ }
+
+
+ CleanupStack::PopAndDestroy( javaRegistry );
+ CleanupStack::PopAndDestroy( &uids );
}
-// End of File
+// End of File
--- a/menucontentsrv/srvsrc/mcsinstallnotifier.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/menucontentsrv/srvsrc/mcsinstallnotifier.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -17,67 +17,68 @@
#include <javadomainpskeys.h>
#include "mcsinstallnotifier.h"
-#include "mcsinstallstrategy.h"
-
+#include <sacls.h>
-CMcsInstallNotifier* CMcsInstallNotifier::NewL(
- MMcsInstallListener& aListener, TNotificationType aNotificationType )
- {
- CMcsInstallNotifier* self = new ( ELeave ) CMcsInstallNotifier( aListener );
- CleanupStack::PushL( self );
- self->ConstructL( aNotificationType );
- CleanupStack::Pop( self );
- return self;
- }
+CMcsInstallNotifier* CMcsInstallNotifier::NewL(MMcsInstallListener& aListener, TInt aKey)
+ {
+ CMcsInstallNotifier* self = new (ELeave) CMcsInstallNotifier( aListener, aKey );
+ CleanupStack::PushL( self );
+ self->ConstructL( );
+ CleanupStack::Pop( self );
+
+ return self;
+ }
CMcsInstallNotifier::~CMcsInstallNotifier()
- {
- Cancel();
- iProperty.Close();
- delete iNotifierStrategy;
- }
-
-CMcsInstallNotifier::CMcsInstallNotifier( MMcsInstallListener& aListener ) :
- CActive( EPriorityNormal ), iListener( aListener )
- {
- CActiveScheduler::Add( this );
- SetActive();
- }
+ {
+ Cancel( );
+ iProperty.Close( );
+ }
-void CMcsInstallNotifier::ConstructL( TNotificationType aNotificationType )
- {
- switch( aNotificationType )
- {
- case ESisInstallNotification:
- iNotifierStrategy = CMcsSwiInstallStrategy::NewL(
- iProperty, iListener );
- break;
- case EJavaInstallNotification:
- iNotifierStrategy = CMcsJavaInstallStrategy::NewL(
- iProperty, iListener );
- break;
- default:
- User::Leave( KErrNotSupported );
- break;
- }
- iProperty.Subscribe( iStatus );
- }
+CMcsInstallNotifier::CMcsInstallNotifier( MMcsInstallListener& aListener, TInt aKey ) :
+ CActive(EPriorityNormal), iListener(aListener)
+ {
+ iKey = aKey;
+ // Prepare automatically
+ iProperty.Attach( KUidSystemCategory, iKey );
+ CActiveScheduler::Add( this );
+ iProperty.Subscribe( iStatus );
+ SetActive( );
+ }
+
+
+void CMcsInstallNotifier::ConstructL()
+ {
+
+ }
+
void CMcsInstallNotifier::DoCancel()
- {
- iProperty.Cancel();
- }
+ {
+ iProperty.Cancel( );
+ }
+
void CMcsInstallNotifier::RunL()
- {
- SetActive();
- iProperty.Subscribe( iStatus );
- iNotifierStrategy->NotifyListenerL();
- }
+ {
+ SetActive( );
+ iProperty.Subscribe( iStatus );
+ TInt status;
+ User::LeaveIfError( iProperty.Get( KUidSystemCategory,
+ iKey, status ) );
-TInt CMcsInstallNotifier::RunError( TInt /*aError*/)
- {
- // No need to do anything
+ if (( iKey == KPSUidJavaLatestInstallation ) ||
+ ((status & EInstOpInstall )||(status & EInstOpUninstall )) &&
+ (status & EInstOpStatusSuccess) )
+ {
+ iListener.HandleInstallNotifyL(status);
+ }
+
+ }
+
+
+TInt CMcsInstallNotifier::RunError( TInt /*aError*/ )
+ {
+ // No need to do anything
return KErrNone;
- }
-
+ }
--- a/menucontentsrv/srvsrc/mcsinstallstrategy.cpp Wed Sep 15 12:32:36 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,260 +0,0 @@
-/*
- * 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: ?Description
- *
- */
-#include <e32property.h>
-#include <SWInstallerInternalPSKeys.h>
-#include <swi/sisregistrysession.h>
-#include <swi/sisregistryentry.h>
-#include <swi/sisregistrypackage.h>
-#include <javadomainpskeys.h>
-#include <javaregistry.h>
-#include <javaregistrypackageentry.h>
-#include <javaregistryapplicationentry.h>
-#include "mcsinstallstrategy.h"
-
-
-
-// ---------------------------------------------------------------------------
-//
-// ---------------------------------------------------------------------------
-//
-CMcsNotifierStrategy::CMcsNotifierStrategy(
- RProperty& aProperty, MMcsInstallListener& aListener ) :
- iProperty( aProperty ), iListener( aListener )
- {
- }
-
-// ---------------------------------------------------------------------------
-//
-// ---------------------------------------------------------------------------
-//
-CMcsSwiInstallStrategy* CMcsSwiInstallStrategy::NewL(
- RProperty& aProperty, MMcsInstallListener& aListener )
- {
- CMcsSwiInstallStrategy* self = new ( ELeave ) CMcsSwiInstallStrategy(
- aProperty, aListener );
- CleanupStack::PushL( self );
- self->ConstructL();
- CleanupStack::Pop( self );
- return self;
- }
-
-// ---------------------------------------------------------------------------
-//
-// ---------------------------------------------------------------------------
-//
-void CMcsSwiInstallStrategy::NotifyListenerL()
- {
- TInt appUid;
- User::LeaveIfError( iProperty.Get( KUidSystemCategory,
- KUidSwiLatestInstallation, appUid ) );
- if( appUid )
- {
- HandleInstallNotifyL( appUid );
- }
- }
-
-// ---------------------------------------------------------
-//
-// ---------------------------------------------------------
-//
-void CMcsSwiInstallStrategy::HandleInstallNotifyL( TInt aUid )
- {
- Swi::RSisRegistrySession iSisRegSession;
- User::LeaveIfError( iSisRegSession.Connect() );
- CleanupClosePushL( iSisRegSession );
-
- // Open sis package entry related to aUid
- Swi::RSisRegistryEntry packageEntry;
- if( KErrNone == packageEntry.Open( iSisRegSession, TUid::Uid( aUid ) ) )
- {
- CleanupClosePushL( packageEntry );
-
- // Get packageEntry's embedded sis'
- RPointerArray<Swi::CSisRegistryPackage> embedded;
- CleanupClosePushL( embedded );
- packageEntry.EmbeddedPackagesL( embedded );
- if( embedded.Count() )
- {
- // For each embadded sis we notify storage - recursive call
- for( TInt i = 0; i < embedded.Count(); ++i )
- {
- iListener.HandleInstallNotifyL( embedded[i]->Uid(),
- CMcsInstallNotifier::ESisInstallNotification );
- }
- }
- else
- {
- // There are no embaddes sis', so we can notify storage
- // of changes in apps included in packageEntry
- NotifyL( packageEntry );
- }
- embedded.ResetAndDestroy();
- CleanupStack::PopAndDestroy( &embedded );
- CleanupStack::PopAndDestroy( &packageEntry );
- }
-
- CleanupStack::PopAndDestroy( &iSisRegSession );
- }
-
-// ---------------------------------------------------------
-//
-// ---------------------------------------------------------
-//
-void CMcsSwiInstallStrategy::NotifyL( Swi::RSisRegistryEntry & aPackageEntry )
- {
- // Get sids ( == uids of exetucables included in aPackageEntry )
- RArray<TUid> sids;
- CleanupClosePushL( sids );
- aPackageEntry.SidsL( sids );
- if( sids.Count() )
- {
- // For each sid we notify storage
- for( TInt i = 0; i < sids.Count(); ++i )
- {
- iListener.HandleInstallNotifyL(
- sids[i], CMcsInstallNotifier::ESisInstallNotification );
- }
- }
- CleanupStack::PopAndDestroy( &sids );
- }
-
-
-// ---------------------------------------------------------------------------
-//
-// ---------------------------------------------------------------------------
-//
-CMcsSwiInstallStrategy::CMcsSwiInstallStrategy(
- RProperty& aProperty, MMcsInstallListener& aListener )
- : CMcsNotifierStrategy( aProperty, aListener )
- {
- iProperty.Attach( KUidSystemCategory, KUidSwiLatestInstallation );
- }
-
-// ---------------------------------------------------------------------------
-//
-// ---------------------------------------------------------------------------
-//
-void CMcsSwiInstallStrategy::ConstructL()
- {
- }
-
-// ---------------------------------------------------------------------------
-//
-// ---------------------------------------------------------------------------
-//
-CMcsJavaInstallStrategy* CMcsJavaInstallStrategy::NewL(
- RProperty& aProperty, MMcsInstallListener& aListener )
- {
- CMcsJavaInstallStrategy* self =
- new ( ELeave ) CMcsJavaInstallStrategy( aProperty, aListener );
- CleanupStack::PushL( self );
- self->ConstructL();
- CleanupStack::Pop( self );
- return self;
- }
-
-// ---------------------------------------------------------------------------
-//
-// ---------------------------------------------------------------------------
-//
-void CMcsJavaInstallStrategy::NotifyListenerL()
- {
- TInt state;
- User::LeaveIfError( iProperty.Get( KUidSystemCategory,
- KPSUidJavaLatestInstallationState, state ) );
- if( ( ( state & ESASwisInstall ) || ( state & ESASwisUninstall ) )
- && ( state & ESASwisStatusSuccess ) )
- {
- TInt appUid;
- User::LeaveIfError( iProperty.Get( KUidSystemCategory,
- KPSUidJavaLatestInstallation, appUid ) );
- HandleInstallNotifyL( TUid::Uid( appUid ) );
- }
- }
-
-// ---------------------------------------------------------
-//
-// ---------------------------------------------------------
-//
-void CMcsJavaInstallStrategy::HandleInstallNotifyL( TUid aPackageUid )
- {
- RArray<TUid> uids;
- CleanupClosePushL( uids );
-
- Java::CJavaRegistry* javaRegistry;
- javaRegistry = Java::CJavaRegistry::NewLC();
-
- Java::CJavaRegistryEntry* regEntry =
- javaRegistry->RegistryEntryL( aPackageUid );
-
- if( regEntry )
- {
- CleanupStack::PushL( regEntry );
-
- Java::TJavaRegistryEntryType entryType = regEntry->Type();
-
- if ( ( entryType >= Java::EGeneralPackage ) &&
- (entryType < Java::EGeneralApplication) )
- {
- //package entry
- Java::CJavaRegistryPackageEntry* regPackageEntry =
- static_cast<Java::CJavaRegistryPackageEntry*>( regEntry );
- regPackageEntry->GetEmbeddedEntries( uids );
- }
- else
- {
- //application entry
- uids.AppendL( regEntry->Uid() );
- }
-
- for ( TInt i = 0; i < uids.Count(); i++ )
- {
- iListener.HandleInstallNotifyL(
- uids[i], CMcsInstallNotifier::EJavaInstallNotification );
- }
-
- CleanupStack::PopAndDestroy( regEntry );
- }
- else
- {
- iListener.HandleInstallNotifyL(
- TUid::Null(), CMcsInstallNotifier::EJavaInstallNotification );
- }
- CleanupStack::PopAndDestroy( javaRegistry );
- CleanupStack::PopAndDestroy( &uids );
- }
-
-
-// ---------------------------------------------------------------------------
-//
-// ---------------------------------------------------------------------------
-//
-CMcsJavaInstallStrategy::CMcsJavaInstallStrategy(
- RProperty& aProperty, MMcsInstallListener& aListener )
- : CMcsNotifierStrategy( aProperty, aListener )
- {
- iProperty.Attach( KUidSystemCategory, KPSUidJavaLatestInstallationState );
- }
-
-// ---------------------------------------------------------------------------
-//
-// ---------------------------------------------------------------------------
-//
-void CMcsJavaInstallStrategy::ConstructL()
- {
- }
-
--- a/menucontentsrv/srvsrc/menusrvappscanner.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/menucontentsrv/srvsrc/menusrvappscanner.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -73,8 +73,6 @@
{
Cancel();
delete iMcsSatNotifier;
- delete iSisInstallNotifier;
- delete iJavaInstallNotifier;
delete iNotifier;
iEng.DequeueOperation( *this );
delete iMmcHistory;
@@ -97,9 +95,9 @@
iCenRepNotifyHandlerCPHiddenFolders->StopListening();
}
delete iCenRepNotifyHandlerCPHiddenFolders;
- delete iCenRepSession;
- delete iFreeSpaceObserver;
- iInstalledPackages.Close();
+ delete iCenRepSession;
+ delete iFreeSpaceObserver;
+
}
// ---------------------------------------------------------
@@ -126,13 +124,13 @@
User::LeaveIfError( iFs.PrivatePath( path ) );
TUint attribute;
if( iFs.Att( path, attribute) == KErrNotFound )
- {
+ {
TInt mdRes = iFs.MkDirAll( path );
if ( mdRes != KErrNone )
- {
- User::Leave( mdRes );
- }
- }
+ {
+ User::Leave( mdRes );
+ }
+ }
iMmcHistory = new (ELeave) CMenuSrvMmcHistory();
iMmcHistory->LoadL( iFs, KMenuMmcHistoryFname() );
@@ -140,34 +138,30 @@
// it as argument... :(
iNotifier = CApaAppListNotifier::NewL( this, CActive::EPriorityStandard );
- iCenRepSession = CRepository::NewL( KCRUidMenu );
+ iCenRepSession = CRepository::NewL( KCRUidMenu );
- iCenRepNotifyHandlerHiddenApps = CCenRepNotifyHandler::NewL(
- *this, *iCenRepSession,
- CCenRepNotifyHandler::EStringKey, KMenuHideApplication );
- iCenRepNotifyHandlerCPHiddenApps = CCenRepNotifyHandler::NewL(
- *this, *iCenRepSession,
- CCenRepNotifyHandler::EStringKey, KMenuHideCPApplication );
-
- iCenRepNotifyHandlerCPHiddenFolders = CCenRepNotifyHandler::NewL(
- *this, *iCenRepSession,
- CCenRepNotifyHandler::EStringKey, KMenuHideCPFolder );
+ iCenRepNotifyHandlerHiddenApps = CCenRepNotifyHandler::NewL(
+ *this, *iCenRepSession,
+ CCenRepNotifyHandler::EStringKey, KMenuHideApplication );
+ iCenRepNotifyHandlerCPHiddenApps = CCenRepNotifyHandler::NewL(
+ *this, *iCenRepSession,
+ CCenRepNotifyHandler::EStringKey, KMenuHideCPApplication );
- iCenRepNotifyHandlerHiddenApps->StartListeningL();
- iCenRepNotifyHandlerCPHiddenApps->StartListeningL();
- iCenRepNotifyHandlerCPHiddenFolders->StartListeningL();
+ iCenRepNotifyHandlerCPHiddenFolders = CCenRepNotifyHandler::NewL(
+ *this, *iCenRepSession,
+ CCenRepNotifyHandler::EStringKey, KMenuHideCPFolder );
- iMcsSatNotifier = CMcsSatNotifier::NewL(
- this, KCRUidMenu, KMenuShowSatUI );
+ iCenRepNotifyHandlerHiddenApps->StartListeningL();
+ iCenRepNotifyHandlerCPHiddenApps->StartListeningL();
+ iCenRepNotifyHandlerCPHiddenFolders->StartListeningL();
- iFreeSpaceObserver = CMcsFreeSpaceObserver::NewL( *this );
+ iMcsSatNotifier = CMcsSatNotifier::NewL(
+ this, KCRUidMenu, KMenuShowSatUI );
- iSisInstallNotifier = CMcsInstallNotifier::NewL(
- *this, CMcsInstallNotifier::ESisInstallNotification );
- iJavaInstallNotifier = CMcsInstallNotifier::NewL(
- *this, CMcsInstallNotifier::EJavaInstallNotification );
+ iFreeSpaceObserver = CMcsFreeSpaceObserver::NewL( *this );
- ScheduleScan();
+ //SetActive();
+ ScheduleScan();
//iOpStatus = ETrue;
}
@@ -254,8 +248,7 @@
// CMenuSrvAppScanner::HideAppIfExists
// ---------------------------------------------------------
//
-void CMenuSrvAppScanner::HideItemIfPresentL(
- TInt aFolder, TInt aId, const TDesC& aUid, TBool aWasHidden )
+void CMenuSrvAppScanner::HideItemIfPresentL( TInt aFolder, TInt aId, const TDesC& aUid, TBool aWasHidden )
{
TBool hideItem = EFalse;
TMenuSrvAttrFilter uidAppFilter;
@@ -265,20 +258,21 @@
CleanupClosePushL( appItems );
iEng.GetItemsL( appItems, aFolder, &uidAppFilter, ETrue );
- for( TInt i=0; i < appItems.Count(); i++ )
+ for (TInt i=0; i < appItems.Count(); i++)
{
- if( appItems[i].Type() != KMenuTypeLink() )
- {
+ if(appItems[i].Type() != KMenuTypeLink())
+ {
const TMenuItem& item = appItems[i];
- TBool itemHidden = (0 != ( item.Flags() & TMenuItem::EHidden ) );
- TBool itemMissing = ( 0 != ( item.Flags() & TMenuItem::EMissing ) );
+ TBool itemHidden = (0 != (item.Flags() & TMenuItem::EHidden));
+ TBool itemMissing = (0 != (item.Flags() & TMenuItem::EMissing));
if ( !itemHidden && !itemMissing )
{
hideItem = ETrue;
}
- }
+ }
}
+
SetHiddenFlagL( aId, aWasHidden, hideItem );
CleanupStack::PopAndDestroy( &appItems );
@@ -290,7 +284,7 @@
//
void CMenuSrvAppScanner::SetHiddenFlagL( TInt aId, TBool aWasHidden, TBool aHide )
{
- if ( aWasHidden != aHide )
+ if ( aWasHidden ^ aHide )
{
iEng.ModifiableObjectL( aId, RMenuNotifier::EItemsAddedRemoved ).
SetFlags( TMenuItem::EHidden, aHide );
@@ -316,7 +310,7 @@
for (TInt i=0; i < appItems.Count(); i++)
{
if(appItems[i].Id() != aId)
- {
+ {
exists = ETrue;
const TMenuItem& item = appItems[i];
@@ -326,7 +320,7 @@
{
showItem = ETrue;
}
- }
+ }
}
UpdateLinkL( aId, exists, showItem, itemMissing );
@@ -471,72 +465,6 @@
User::RequestComplete( ownStatus, KErrNone );
}
}
-
-// ---------------------------------------------------------
-//
-// ---------------------------------------------------------
-//
-void CMenuSrvAppScanner::InstallationNotifyL()
- {
- TBool isLegacy = iEng.GetOnceLegacyFormat();
- for( TInt i = iInstalledPackages.Count() - 1; i >= 0; i-- )
- {
- RArray<TMenuItem> mcsUidItems;
- CleanupClosePushL( mcsUidItems );
- GetMcsAppItemsL( isLegacy, iInstalledPackages[i].iUid, mcsUidItems );
- if( mcsUidItems.Count() )
- {
- iEng.ModifiableObjectL( mcsUidItems[0].Id() );
- iInstalledPackages.Remove( i );
- }
- CleanupStack::PopAndDestroy( &mcsUidItems );
- }
- }
-
-// ---------------------------------------------------------
-//
-// ---------------------------------------------------------
-//
-void CMenuSrvAppScanner::RemoveFromInstalledPackages( TUid aUid )
- {
- TInt appIndex = iInstalledPackages.Find( aUid );
- if( appIndex != KErrNotFound )
- {
- iInstalledPackages.Remove( appIndex );
- }
- }
-
-// ---------------------------------------------------------
-//
-// ---------------------------------------------------------
-//
-CMenuEngObject& CMenuSrvAppScanner::ModifiableObjectL( TUid aUid, TInt aId,
- TInt aEvent )
- {
- if( aEvent != RMenuNotifier::EItemsNone )
- {
- RemoveFromInstalledPackages( aUid );
- }
- return iEng.ModifiableObjectL( aId, aEvent );
- }
-
-// ---------------------------------------------------------
-//
-// ---------------------------------------------------------
-//
-void CMenuSrvAppScanner::HandleInstallNotifyL( TUid aUid,
- CMcsInstallNotifier::TNotificationType aNotificationType )
- {
- iInstalledPackages.AppendL( aUid );
- // when installing java, appscanner first gets notification from appArc,
- // and then it is notified with instal notifier(RProperty)
- // so we need another scan for java apps
- if( aNotificationType == CMcsInstallNotifier::EJavaInstallNotification )
- {
- ScheduleScan();
- }
- }
-
// ---------------------------------------------------------
// CMenuSrvAppScanner::RunMenuEngOperationL
// ---------------------------------------------------------
@@ -546,44 +474,43 @@
UpdateApplicationItemsL();
UpdateApplicationWithHideIfInstalledItemsL();
UpdateLinkItemsL();
- InstallationNotifyL();
iOpStatus = EFalse;
}
+
// ---------------------------------------------------------
// CMenuSrvAppScanner::UpdateApplicationItemL
// ---------------------------------------------------------
//
void CMenuSrvAppScanner::UpdateApplicationItemL(
- RArray<TMenuItem>& aMcsItems, const CMenuSrvAppAttributes& aApaItem,
- TUint aMmcId, TBool isLegacy)
+ RArray<TMenuItem>& aMcsItems, const CMenuSrvAppAttributes& aApaItem,
+ TUint aMmcId, TBool isLegacy)
{
RArray<TMenuItem> mcsUidItems;
CleanupClosePushL( mcsUidItems );
- TUid appUid = aApaItem.GetUid();
- GetMcsAppItemsL( isLegacy, appUid.iUid, mcsUidItems );
+ TUid appuid = aApaItem.GetUid();
+ GetMcsAppItemsL( isLegacy, appuid.iUid, mcsUidItems );
TBool isApaItemHidden( aApaItem.IsHidden() );
// This app is not in the menu, add it now.
// We don't add hidden items, there are too many of them!
// do not display Menu app
if ( !mcsUidItems.Count()
- && !isApaItemHidden
- && appUid != KMmUid3 )
+ && !isApaItemHidden
+ && appuid != KMmUid3 )
{
- if( appUid == KSatUid )
+ if( appuid == KSatUid )
{
if( CMcsSatHandler::CheckVisibility() )
- {
- AddAppItemL( aApaItem, aMmcId );
- }
+ {
+ AddAppItemL( aApaItem, aMmcId );
+ }
}
else
- {
- AddAppItemL( aApaItem, aMmcId );
- GetMcsAppItemsL( isLegacy, appUid.iUid, mcsUidItems );
- RemoveFromInstalledPackages( appUid );
- }
+ {
+ AddAppItemL( aApaItem, aMmcId );
+ GetMcsAppItemsL( isLegacy, appuid.iUid, mcsUidItems );
+ }
}//if
// if there are any items with legacy UID format
@@ -592,12 +519,13 @@
{
//for every item with matching UID
for (TInt j=0; j < mcsUidItems.Count(); j++)
- {
+ {
+ CMenuEngObject& object =
+ iEng.ModifiableObjectL( mcsUidItems[j].Id() );
TBuf<KUidChars> uidString;
- MenuSrvUtil::UidToStringL( appUid.iUid, uidString, EFalse, EHex );
- ModifiableObjectL( appUid, mcsUidItems[j].Id() ).SetAttributeL(
- KMenuAttrUid(), uidString, EFalse );
- }//for
+ MenuSrvUtil::UidToStringL( appuid.iUid, uidString, EFalse, EHex );
+ object.SetAttributeL( KMenuAttrUid(), uidString, EFalse );
+ }//for
}//else if
// "hidden", "missing" and "lock_delete" flags update
for ( TInt j = 0; j < mcsUidItems.Count(); j++ )
@@ -607,24 +535,24 @@
//we need to handle first run of appscanner,
//there might be some incorrect data in content xml file
//if this will have impact on performance we may run this methods only at start up
- HandleMmcAttrUpdateL( item, aApaItem, aMmcId );
- HandleNativeAttrUpdateL( item, aApaItem );
+ HandleMmcAttrUpdateL( item, aApaItem, aMmcId );
+ HandleNativeAttrUpdateL( item, aApaItem );
// "hidden" flag handling.
HandleHiddenFlagUpdateL( item, aApaItem );
// "missing" flag handling
- HandleMissingFlagUpdateL( item, aApaItem );
+ HandleMissingFlagUpdateL( item );
//"lock_delete" flag handling
- HandleLockDeleteFlagUpdateL( item, aApaItem );
+ HandleLockDeleteFlagUpdateL(item, aApaItem );
// if item was just added to MCS it is not present in aMcsItems
// so we cannot remove it
TInt index = aMcsItems.Find( item, TIdentityRelation<TMenuItem>( IdMatch ) );
if ( index != KErrNotFound )
- {
- aMcsItems.Remove( index );
- }
+ {
+ aMcsItems.Remove( index );
+ }
}//for
CleanupStack::PopAndDestroy( &mcsUidItems );
}
@@ -635,40 +563,37 @@
//
void CMenuSrvAppScanner::HandleHiddenFlagUpdateL( const TMenuItem & aItem,
const CMenuSrvAppAttributes& aApaItem )
- {
- TBool itemHidden = ( 0 != ( aItem.Flags() & TMenuItem::EHidden ) );
- if( aApaItem.GetUid() == KSatUid )
- {
- if( itemHidden == CMcsSatHandler::CheckVisibility() )
- {
- ModifiableObjectL( aApaItem.GetUid(), aItem.Id(),
- RMenuNotifier::EItemsAddedRemoved ).SetFlags(
- TMenuItem::EHidden,
- !CMcsSatHandler::CheckVisibility() );
- }
- }
- else if( itemHidden != aApaItem.IsHidden() )
- {
- ModifiableObjectL( aApaItem.GetUid(), aItem.Id(),
- RMenuNotifier::EItemsAddedRemoved ).SetFlags(
- TMenuItem::EHidden, aApaItem.IsHidden() );
- }
- }
+ {
+ TBool itemHidden = (0 != (aItem.Flags() & TMenuItem::EHidden));
+ if ( aApaItem.GetUid() == KSatUid )
+ {
+ if (itemHidden == CMcsSatHandler::CheckVisibility())
+ {
+ iEng.ModifiableObjectL(aItem.Id(), RMenuNotifier::EItemsAddedRemoved).
+ SetFlags( TMenuItem::EHidden, !CMcsSatHandler::CheckVisibility());
+ }
+ }
+ else if ( itemHidden != aApaItem.IsHidden() )
+ {
+ iEng.ModifiableObjectL(aItem.Id(), RMenuNotifier::EItemsAddedRemoved).
+ SetFlags( TMenuItem::EHidden, aApaItem.IsHidden() );
+ }
+ }
// ---------------------------------------------------------
// CMenuSrvAppScanner::HandleNativeAttrUpdateL
// ---------------------------------------------------------
//
void CMenuSrvAppScanner::HandleNativeAttrUpdateL(
- const TMenuItem& aItem, const CMenuSrvAppAttributes& aApaItem )
- {
+ const TMenuItem& aItem, const CMenuSrvAppAttributes& aApaItem )
+ {
//we need this to delete uninstalled java app item
if( aApaItem.GetAppType() != iEng.ObjectL( aItem.Id() ).GetAppType() )
- {
- ModifiableObjectL( aApaItem.GetUid(), aItem.Id(),
- RMenuNotifier::EItemsNone ).SetAppType( aApaItem.GetAppType() );
- }
- }
+ {
+ iEng.ModifiableObjectL( aItem.Id(),
+ RMenuNotifier::EItemsNone ).SetAppType( aApaItem.GetAppType() );
+ }
+ }
// ---------------------------------------------------------
@@ -676,41 +601,31 @@
// ---------------------------------------------------------
//
void CMenuSrvAppScanner::HandleMmcAttrUpdateL(
- const TMenuItem& aItem, const CMenuSrvAppAttributes& aApaItem, TUint aMmcId )
- {
- TPtrC val;
- TBool dummy;
- TBool attributeExists = iEng.ObjectL( aItem.Id() ).FindAttribute(
- KMenuAttrMmcId(), val, dummy );
- if( IsInMmc( aApaItem ) )
- {
- //app is instaled on mmc - KMenuAttrMmcId attribute update
- TBuf<KUidChars> uidString;
+ const TMenuItem& aItem, const CMenuSrvAppAttributes& aApaItem, TUint aMmcId )
+ {
+ if ( IsInMmc( aApaItem ) )
+ {
+ //app is instaled on mmc - KMenuAttrMmcId attribute update
+ TBuf<KUidChars> uidString;
uidString.Format( KHexFormat, aMmcId );
- if( uidString.Compare( val ) )
- {
- ModifiableObjectL( aApaItem.GetUid(), aItem.Id() ).SetAttributeL(
- KMenuAttrMmcId, uidString, EFalse );
- }
- }
- else if( IsInMassStorage( aApaItem )
- && aApaItem.GetAppType() == CMenuEngObject::EWidgetApp )
- {
- //its java app installed on mass storage, we need to leave it in xml
- //in case of connecting usb in mass storage mode
- if( KMenuMassStorage().Compare( val ) )
- {
- ModifiableObjectL( aApaItem.GetUid(), aItem.Id() ).SetAttributeL(
- KMenuAttrMmcId, KMenuMassStorage, EFalse );
- }
- }
- else if( attributeExists )
- {
- //its installed on c: drive - remove attribute
- ModifiableObjectL( aApaItem.GetUid(), aItem.Id() ).RemoveAttribute(
- KMenuAttrMmcId );
- }
- }
+ iEng.ModifiableObjectL( aItem.Id(), RMenuNotifier::EItemsAddedRemoved ).
+ SetAttributeL( KMenuAttrMmcId, uidString, EFalse );
+ }
+ else if ( IsInMassStorage( aApaItem )
+ && aApaItem.GetAppType() == CMenuEngObject::EWidgetApp )
+ {
+ //its java app installed on mass storage, we need to leave it in xml
+ //in case of connecting usb in mass storage mode
+ iEng.ModifiableObjectL( aItem.Id(), RMenuNotifier::EItemsAddedRemoved ).
+ SetAttributeL( KMenuAttrMmcId, KMenuMassStorage, EFalse );
+ }
+ else
+ {
+ //its installed on c: drive - remove attribute
+ iEng.ModifiableObjectL( aItem.Id(), RMenuNotifier::EItemsAddedRemoved ).
+ RemoveAttribute( KMenuAttrMmcId );
+ }
+ }
// ---------------------------------------------------------
// CMenuSrvAppScanner::UpdateApplicationItemsL
// ---------------------------------------------------------
@@ -726,13 +641,14 @@
GetCrItemsL( iSrvEngUtils.GetAppItemsL() );
TBool isLegacy = iEng.GetOnceLegacyFormat();
+
//for every item in apaAndCrItems array
for ( TInt i = ( iSrvEngUtils.GetAppItemsL().Count() - 1 ); i >= 0 ; i-- )
{
// if there was leave for any item we ignore it
// and proceed to the next one
- TRAP_IGNORE( UpdateApplicationItemL( mcsItems,
- *iSrvEngUtils.GetAppItemsL()[i], currentMmcId, isLegacy ) );
+ TRAP_IGNORE(UpdateApplicationItemL(
+ mcsItems, *iSrvEngUtils.GetAppItemsL()[i], currentMmcId, isLegacy));
}
// Here the big list contains menu items that refer to missing apps.
HandleMissingItemsL( mcsItems );
@@ -744,44 +660,42 @@
// ---------------------------------------------------------
//
void CMenuSrvAppScanner::HandleLockDeleteFlagUpdateL(
- const TMenuItem& aItem, const CMenuSrvAppAttributes& aApaItem )
- {
- TBool isHidden = ( ( iEng.ObjectL( aItem.Id() )
- .Flags() & TMenuItem::EHidden ) != 0 );
- if ( !isHidden && IsInRomL( aApaItem ) )
- {
- if ( ( aItem.Flags() & TMenuItem::ELockDelete ) == 0 )
- {
- ModifiableObjectL( aApaItem.GetUid(), aItem.Id()).SetFlags(
- TMenuItem::ELockDelete, ETrue );
- }
- }
- else
- {
- if ( ( aItem.Flags() & TMenuItem::ELockDelete ) != 0 )
- {
- ModifiableObjectL( aApaItem.GetUid(), aItem.Id() ).SetFlags(
- TMenuItem::ELockDelete, EFalse );
- }
- }
- }
+ const TMenuItem& aItem, const CMenuSrvAppAttributes& aApaItem )
+ {
+ TBool isHidden = ( ( iEng.ObjectL( aItem.Id() )
+ .Flags() & TMenuItem::EHidden ) != 0 );
+ if ( !isHidden && IsInRomL( aApaItem ) )
+ {
+ if ( ( aItem.Flags() & TMenuItem::ELockDelete ) == 0 )
+ {
+ iEng.ModifiableObjectL(aItem.Id())
+ .SetFlags( TMenuItem::ELockDelete, ETrue );
+ }
+ }
+ else
+ {
+ if ( ( aItem.Flags() & TMenuItem::ELockDelete ) != 0 )
+ {
+ iEng.ModifiableObjectL(aItem.Id())
+ .SetFlags( TMenuItem::ELockDelete, EFalse );
+ }
+ }
+ }
// ---------------------------------------------------------
// CMenuSrvAppScanner::HandleMissingFlagUpdateL
// ---------------------------------------------------------
//
-void CMenuSrvAppScanner::HandleMissingFlagUpdateL(
- const TMenuItem& aItem, const CMenuSrvAppAttributes& aApaItem )
- {
- if ( aItem.Flags() & TMenuItem::EMissing )
+void CMenuSrvAppScanner::HandleMissingFlagUpdateL( const TMenuItem& aItem )
+ {
+ if ( aItem.Flags() & TMenuItem::EMissing )
{
CLOG_WRITE_FORMAT8( "Unsetting flag EMissing on %d", item.Id() );
//application found so we unset "missing" flag
- ModifiableObjectL( aApaItem.GetUid(), aItem.Id(),
- RMenuNotifier::EItemsAddedRemoved ).SetFlags(
- TMenuItem::EMissing, EFalse );
+ iEng.ModifiableObjectL( aItem.Id(), RMenuNotifier::EItemsAddedRemoved ).
+ SetFlags( TMenuItem::EMissing, EFalse );
}
- }
+ }
// ---------------------------------------------------------
// CMenuSrvAppScanner::GetCrItemsL
@@ -789,11 +703,11 @@
//
void CMenuSrvAppScanner::GetCrItemsL( RPointerArray<CMenuSrvAppAttributes>& aArray )
{
- TBuf<KCenRepBufferSize> buf;
- iCenRepSession->Get( KMenuHideCPApplication, buf );
- ParseUidsL( buf, aArray );// parses UIDs from buf and appends them to array
- iCenRepSession->Get( KMenuHideApplication, buf );
- ParseUidsL( buf, aArray );// parses UIDs from buf and appends them to array
+ TBuf<KCenRepBufferSize> buf;
+ iCenRepSession->Get( KMenuHideCPApplication, buf );
+ ParseUidsL( buf, aArray );// parses UIDs from buf and appends them to array
+ iCenRepSession->Get( KMenuHideApplication, buf );
+ ParseUidsL( buf, aArray );// parses UIDs from buf and appends them to array
}
// ---------------------------------------------------------
@@ -811,24 +725,26 @@
{
if( input.Peek() == ',')
{
- SetHiddenL(input.MarkedToken( startMark ), aArray);
+ SetHidden(input.MarkedToken( startMark ), aArray);
input.Inc();
input.Mark( startMark );
}
input.Inc();
notEmpty = ETrue;
}
- if ( notEmpty )
- {
- SetHiddenL( input.MarkedToken( startMark ), aArray );
- }
+ if ( notEmpty )
+ {
+ SetHidden(input.MarkedToken( startMark ), aArray);
+ }
+
+
}
// ---------------------------------------------------------
// CMenuSrvAppScanner::SetHidden
// ---------------------------------------------------------
//
-void CMenuSrvAppScanner::SetHiddenL(
+void CMenuSrvAppScanner::SetHidden(
const TDesC& aHiddenAppUid, RPointerArray<CMenuSrvAppAttributes>& aArray )
{
TLex appUidDescriptor(aHiddenAppUid);
@@ -950,23 +866,23 @@
// ---------------------------------------------------------
//
void CMenuSrvAppScanner::ScheduleScan()
- {
- if ( !IsActive() && !iOpStatus )
- {
- iOpStatus = ETrue;
- TRequestStatus* ownStatus = &iStatus;
- *ownStatus = KRequestPending;
- SetActive();
- User::RequestComplete( ownStatus, KErrNone );
- }
- }
+ {
+ if ( !IsActive() && !iOpStatus )
+ {
+ iOpStatus = ETrue;
+ TRequestStatus* ownStatus = &iStatus;
+ *ownStatus = KRequestPending;
+ SetActive();
+ User::RequestComplete( ownStatus, KErrNone );
+ }
+ }
// ---------------------------------------------------------
// CMenuSrvAppScanner::CreateInstallFolderL
// ---------------------------------------------------------
//
TInt CMenuSrvAppScanner::CreateInstallFolderL( const CMenuSrvAppAttributes& aApaItem )
- {
+ {
// Find a folder for this app.
TInt folder(0);
if ( aApaItem.GetGroupName().Length() )
@@ -985,7 +901,7 @@
iEng.RootFolderL( folder );
}
return folder;
- }
+ }
// ---------------------------------------------------------
// CMenuSrvAppScanner::AddAppItemL
@@ -1011,14 +927,14 @@
object->SetAttributeL( KMenuAttrMmcId, uidString, EFalse );
}
if( aApaItem.GetAppType() == CMenuEngObject::EWidgetApp )
- {
- //we need this to delete uninstalled java or wrt widget app item
- if ( !IsInMmc( aApaItem )
- && IsInMassStorage( aApaItem ) )
- {
- object->SetAttributeL( KMenuAttrMmcId, KMenuMassStorage, EFalse );
- }
- }
+ {
+ //we need this to delete uninstalled java or wrt widget app item
+ if ( !IsInMmc( aApaItem )
+ && IsInMassStorage( aApaItem ) )
+ {
+ object->SetAttributeL( KMenuAttrMmcId, KMenuMassStorage, EFalse );
+ }
+ }
object->SetAppType( aApaItem.GetAppType() );
EnsureFolderWritableL( folder );
iEng.AddL( *object, folder, 0 );
@@ -1041,12 +957,12 @@
TBool localized;
if ( rootObject.FindAttribute( KMenuAttrAppGroupName, groupName, localized ) &&
- groupName.Compare( aAppGroupName )==0 )
+ groupName.Compare( aAppGroupName )==0 )
{
folder = defaultFolderId;
}
else
- {
+ {
TMenuSrvTypeAttrFilter filter;
filter.SetType( KMenuTypeFolder() );
filter.SetAttr( KMenuAttrAppGroupName(), aAppGroupName );
@@ -1059,7 +975,7 @@
folder = items[0].Id();
}
CleanupStack::PopAndDestroy( &items );
- }
+ }
if ( !folder )
{
// No such folder, create it now.
@@ -1149,7 +1065,7 @@
else if( iEng.ObjectL( aItem.Id() ).GetAppType()
!= CMenuEngObject::EWidgetApp
|| iEng.ObjectL( aItem.Id() ).FindAttribute(
- KMenuAttrPredefined(), val, dummy ) )
+ KMenuAttrPredefined(), val, dummy ) )
{
flags = TMenuItem::EHidden;
}
@@ -1183,15 +1099,15 @@
// ---------------------------------------------------------
//
void CMenuSrvAppScanner::SetObjectFlagsL( TBool aFlagValue, const TMenuItem& aItem,
- const TMenuItem::TFlags& aFlag, const RMenuNotifier::TEvent& aEvent )
- {
- TBool itemFlagPresent = (0 != (aItem.Flags() & aFlag));
- if( aFlagValue != itemFlagPresent )
- {
- iEng.ModifiableObjectL( aItem.Id(), aEvent ).
- SetFlags( aFlag, aFlagValue );
- }
- }
+ const TMenuItem::TFlags& aFlag, const RMenuNotifier::TEvent& aEvent )
+ {
+ TBool itemFlagPresent = (0 != (aItem.Flags() & aFlag));
+ if( aFlagValue != itemFlagPresent )
+ {
+ iEng.ModifiableObjectL( aItem.Id(), aEvent ).
+ SetFlags( aFlag, aFlagValue );
+ }
+ }
// ---------------------------------------------------------
// CMenuSrvAppScanner::UpdateMmcHistoryL
@@ -1201,10 +1117,10 @@
{
TUint mmcId = CurrentMmcId();
if( mmcId )
- {
- iMmcHistory->InsertL( mmcId );
- iMmcHistory->SaveL( iFs, KMenuMmcHistoryFname() );
- }
+ {
+ iMmcHistory->InsertL( mmcId );
+ iMmcHistory->SaveL( iFs, KMenuMmcHistoryFname() );
+ }
return mmcId;
}
@@ -1219,7 +1135,7 @@
TInt mmcDrive;
TInt err;
err = DriveInfo::GetDefaultDrive(
- DriveInfo::EDefaultRemovableMassStorage, mmcDrive );
+ DriveInfo::EDefaultRemovableMassStorage, mmcDrive );
if ( !err )
{
TVolumeInfo volumeInfo;
@@ -1237,14 +1153,14 @@
// ---------------------------------------------------------
//
TBool CMenuSrvAppScanner::IsFileInDrive(
- const TDesC& aFileName,
- const DriveInfo::TDefaultDrives& aDefaultDrive ) const
+ const TDesC& aFileName,
+ const DriveInfo::TDefaultDrives& aDefaultDrive ) const
{
if ( aFileName.Length() )
{
TInt mmcDrive;
TInt err = DriveInfo::GetDefaultDrive(
- aDefaultDrive, mmcDrive );
+ aDefaultDrive, mmcDrive );
if ( !err )
{
TInt fileDrive;
@@ -1264,13 +1180,13 @@
//
TBool CMenuSrvAppScanner::IsAppInDrive(
const CMenuSrvAppAttributes& aApaItem,
- const DriveInfo::TDefaultDrives& aDefaultDrive ) const
+ const DriveInfo::TDefaultDrives& aDefaultDrive ) const
{
TBool ret( EFalse );
if ( IsFileInDrive( aApaItem.GetFullName(), aDefaultDrive ) )
- {
- ret = ETrue;
- }
+ {
+ ret = ETrue;
+ }
return ret;
}
@@ -1306,24 +1222,24 @@
// ---------------------------------------------------------
//
TBool CMenuSrvAppScanner::IsDriveInUse(
- const DriveInfo::TDefaultDrives& aDefaultDrive )
+ const DriveInfo::TDefaultDrives& aDefaultDrive )
{
TBool inUse( EFalse );
TInt drive;
TInt err = DriveInfo::GetDefaultDrive( aDefaultDrive, drive );
if( err == KErrNone )
- {
- TUint status;
- err = DriveInfo::GetDriveStatus( iFs, drive, status );
- if( err == KErrNone
- && ( status & DriveInfo::EDriveInUse ) )
- {
- inUse = ETrue;
- }
- }
+ {
+ TUint status;
+ err = DriveInfo::GetDriveStatus( iFs, drive, status );
+ if( err == KErrNone
+ && ( status & DriveInfo::EDriveInUse ) )
+ {
+ inUse = ETrue;
+ }
+ }
- return inUse;
+ return inUse;
}
// End of File
--- a/menucontentsrv/srvsrc/menusrveng.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/menucontentsrv/srvsrc/menusrveng.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -347,8 +347,9 @@
// CMenuSrvEng::GetRunningAppsL()
// ---------------------------------------------------------
//
-void CMenuSrvEng::GetExtendedAttributesL(TInt aId, const TDesC& aAttrName,
- TBool& aAttrExists, TDes& aAttrVal )
+void CMenuSrvEng::GetExtendedAttributesL(TInt aId,
+ const TDesC& aAttrName, TBool& aAttrExists,
+ TDes& aAttrVal )
{
TBool captionInfo(aAttrName.Compare( KMenuAttrShortName ) == KErrNone ||
aAttrName.Compare( KMenuAttrLongName ) == KErrNone ||
@@ -375,7 +376,6 @@
else if( KErrNone == aAttrName.Compare( KMenuAttrNative ) )
{
ApplicationNativeAttributeL( aId, aAttrExists, aAttrVal );
- addToCache = EFalse;
}
else // The attribute doesn't present for the item
{
@@ -384,7 +384,7 @@
}
if( aAttrExists && addToCache )
{
- AddToCacheL( aId, aAttrName, aAttrVal );
+ AddToCacheL(aId, aAttrName, aAttrVal );
}
}
@@ -392,8 +392,8 @@
// CMenuSrvEng::ApplicationNativeAttributeL
// ---------------------------------------------------------
//
-void CMenuSrvEng::ApplicationNativeAttributeL( TInt aId,
- TBool & aAttrExists, TDes & aAttrVal )
+void CMenuSrvEng::ApplicationNativeAttributeL(
+ TInt aId, TBool & aAttrExists, TDes & aAttrVal )
{
const CMenuEngObject & aEngObj = iEng->ObjectL(aId);
@@ -449,7 +449,7 @@
void CMenuSrvEng::CaptionInfoL( TInt aId, const TDesC& aAttrName,
TBool& aExists, TDes& aAttrVal )
{
- const CMenuEngObject& obj = iEng->ObjectL( aId );
+ const CMenuEngObject& obj = iEng->ObjectL(aId);
if ( obj.Type().Compare( KMenuTypeFolder ) == KErrNone )
{
TBool localized;
@@ -459,14 +459,15 @@
{
aExists = ETrue;
aAttrVal = attrvalue;
- AddToCacheL( aId, KMenuAttrLongName, aAttrVal );
- AddToCacheL( aId, KMenuAttrShortName, aAttrVal );
- AddToCacheL( aId, KMenuAttrTitleName, aAttrVal );
+ AddToCacheL(aId, KMenuAttrLongName, aAttrVal );
+ AddToCacheL(aId, KMenuAttrShortName, aAttrVal );
+ AddToCacheL(aId, KMenuAttrTitleName, aAttrVal );
}
}
else if ( obj.Type().Compare( KMenuTypeApp ) == KErrNone )
{
aAttrVal = AppCaptionInfoL( obj, aAttrName, aExists );
+ AddToCacheL(aId, aAttrName, aAttrVal );
}
else
{
@@ -561,8 +562,7 @@
// CMenuSrvEng::FolderChildrenCountL
// ---------------------------------------------------------
//
- void CMenuSrvEng::FolderChildrenCountL(
- TInt aId, TBool& aExists, TDes& aAttrVal )
+ void CMenuSrvEng::FolderChildrenCountL( TInt aId, TBool& aExists, TDes& aAttrVal )
{
const CMenuEngObject& obj = iEng->ObjectL(aId);
@@ -680,54 +680,47 @@
void CMenuSrvEng::AppendExtendedAttrributesL(
const TDesC& aType,
RArray<TPtrC>& aList )
-{
+ {
+
if ( KErrNone == aType.Compare( KMenuTypeApp ) )
{
- if( KErrNotFound == aList.Find( KMenuAttrTitleName(),
- TIdentityRelation<TPtrC>( CmpAttrName )) )
- {
- aList.AppendL( TPtrC( KMenuAttrTitleName ) );
- }
- if( KErrNotFound == aList.Find( KMenuAttrShortName(),
- TIdentityRelation<TPtrC>( CmpAttrName )) )
- {
- aList.AppendL( TPtrC( KMenuAttrShortName ) );
- }
- if( KErrNotFound == aList.Find( KMenuAttrLongName(),
- TIdentityRelation<TPtrC>( CmpAttrName )) )
- {
- aList.AppendL( TPtrC( KMenuAttrLongName ) );
- }
- if( KErrNotFound == aList.Find( KMenuAttrDrmProtection(),
- TIdentityRelation<TPtrC>( CmpAttrName )) )
- {
- aList.AppendL( TPtrC( KMenuAttrDrmProtection ) );
- }
+ if( KErrNotFound == aList.Find( KMenuAttrTitleName(), TIdentityRelation<TPtrC>( CmpAttrName )) )
+ {
+ aList.AppendL( TPtrC( KMenuAttrTitleName ) );
+ }
+ if( KErrNotFound == aList.Find( KMenuAttrShortName(), TIdentityRelation<TPtrC>( CmpAttrName )) )
+ {
+ aList.AppendL( TPtrC( KMenuAttrShortName ) );
+ }
+ if( KErrNotFound == aList.Find( KMenuAttrLongName(), TIdentityRelation<TPtrC>( CmpAttrName )) )
+ {
+ aList.AppendL( TPtrC( KMenuAttrLongName ) );
+ }
+ if( KErrNotFound == aList.Find( KMenuAttrDrmProtection(), TIdentityRelation<TPtrC>( CmpAttrName )) )
+ {
+ aList.AppendL( TPtrC( KMenuAttrDrmProtection ) );
+ }
}
else if ( KErrNone == aType.Compare( KMenuTypeFolder ) )
{
- if( KErrNotFound == aList.Find( KMenuAttrTitleName(),
- TIdentityRelation<TPtrC>( CmpAttrName )) )
- {
- aList.AppendL( TPtrC( KMenuAttrTitleName ) );
- }
- if( KErrNotFound == aList.Find( KMenuAttrShortName(),
- TIdentityRelation<TPtrC>( CmpAttrName )) )
- {
- aList.AppendL( TPtrC( KMenuAttrShortName ) );
- }
- if( KErrNotFound == aList.Find( KMenuAttrLongName(),
- TIdentityRelation<TPtrC>( CmpAttrName )) )
- {
- aList.AppendL( TPtrC( KMenuAttrLongName ) );
- }
- if( KErrNotFound == aList.Find( KChildrenCount(),
- TIdentityRelation<TPtrC>( CmpAttrName )) )
- {
- aList.AppendL( TPtrC( KChildrenCount ) );
- }
+ if( KErrNotFound == aList.Find( KMenuAttrTitleName(), TIdentityRelation<TPtrC>( CmpAttrName )) )
+ {
+ aList.AppendL( TPtrC( KMenuAttrTitleName ) );
+ }
+ if( KErrNotFound == aList.Find( KMenuAttrShortName(), TIdentityRelation<TPtrC>( CmpAttrName )) )
+ {
+ aList.AppendL( TPtrC( KMenuAttrShortName ) );
+ }
+ if( KErrNotFound == aList.Find( KMenuAttrLongName(), TIdentityRelation<TPtrC>( CmpAttrName )) )
+ {
+ aList.AppendL( TPtrC( KMenuAttrLongName ) );
+ }
+ if( KErrNotFound == aList.Find( KChildrenCount(), TIdentityRelation<TPtrC>( CmpAttrName )) )
+ {
+ aList.AppendL( TPtrC( KChildrenCount ) );
+ }
}
- }
+ }
// End of File
--- a/xcfw/src/xcfwlocalizer.cpp Wed Sep 15 12:32:36 2010 +0300
+++ b/xcfw/src/xcfwlocalizer.cpp Wed Oct 13 14:53:46 2010 +0300
@@ -138,10 +138,9 @@
if( !BaflUtils::FileExists( aFileSystem, locfile->Des() ) )
{
RArray<TLanguage> langs;
- CleanupClosePushL( langs );
BaflUtils::GetDowngradePathL( aFileSystem, langcode, langs );
//add current language to array for ROM fetching
- langs.AppendL( langcode );
+ langs.Append( langcode );
TInt current = langs.Count() - 1;
do
{
@@ -166,8 +165,8 @@
} while ( current >= 0 &&
!BaflUtils::FileExists( aFileSystem, locfile->Des() ) );
}
-
- CleanupStack::PopAndDestroy( &langs );
+ langs.Reset();
+ langs.Close();
}