--- a/locationmanager/locationtrail/src/locationremappingao.cpp Wed Sep 15 12:40:59 2010 +0300
+++ b/locationmanager/locationtrail/src/locationremappingao.cpp Wed Oct 13 15:02:02 2010 +0300
@@ -24,11 +24,6 @@
using namespace MdeConstants;
-
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::NewL()
-// --------------------------------------------------------------------------
-//
CLocationRemappingAO* CLocationRemappingAO::NewL()
{
LOG( "CLocationRemappingAO::NewL" ); // DEBUG INFO
@@ -40,10 +35,6 @@
return self;
}
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::ConstructL()
-// --------------------------------------------------------------------------
-//
void CLocationRemappingAO::ConstructL()
{
LOG( "CLocationRemappingAO::ConstructL" ); // DEBUG INFO
@@ -58,10 +49,6 @@
}
}
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::~CLocationRemappingAO()
-// --------------------------------------------------------------------------
-//
CLocationRemappingAO::~CLocationRemappingAO()
{
LOG( "CLocationRemappingAO::~CLocationRemappingAO" ); // DEBUG INFO
@@ -72,10 +59,6 @@
iObjects.ResetAndDestroy();
}
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::CLocationRemappingAO()
-// --------------------------------------------------------------------------
-//
CLocationRemappingAO::CLocationRemappingAO() : CActive( CActive::EPriorityStandard ),
iState ( EIdle ),
iContinue( EFalse ),
@@ -88,10 +71,7 @@
// No implementation required
}
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::InitialiseL()
-// --------------------------------------------------------------------------
-//
+
void CLocationRemappingAO::InitialiseL(CMdESession* aMdEClient)
{
LOG( "CLocationRemappingAO::Initialise start" ); // DEBUG INFO
@@ -117,41 +97,21 @@
LOG( "CLocationRemappingAO::Initialise end" );
}
-
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::Append()
-// --------------------------------------------------------------------------
-//
void CLocationRemappingAO::Append( TRemapItem aItem )
{
iRemapItems.Append( aItem );
}
-
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::ResetQueue()
-// --------------------------------------------------------------------------
-//
void CLocationRemappingAO::ResetQueue()
{
iRemapItems.Reset();
}
-
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::ItemsInQueue()
-// --------------------------------------------------------------------------
-//
TBool CLocationRemappingAO::ItemsInQueue()
{
return iRemapItems.Count() > 0;
}
-
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::CheckQueue()
-// --------------------------------------------------------------------------
-//
TBool CLocationRemappingAO::CheckQueue()
{
LOG( "CLocationRemappingAO::CheckQueue - start" );
@@ -205,21 +165,13 @@
return create;
}
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::StopRemapping()
-// --------------------------------------------------------------------------
-//
+
void CLocationRemappingAO::StopRemapping()
{
LOG( "CLocationRemappingAO::StopRemapping" ); // DEBUG INFO
NextState(EIdle);
}
-
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::StartRemappingObjects()
-// --------------------------------------------------------------------------
-//
void CLocationRemappingAO::StartRemappingObjects( const TLocationData& aLocationData )
{
iLocationData = aLocationData;
@@ -233,11 +185,6 @@
NextState( ERemapObjects );
}
-
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::NextState()
-// --------------------------------------------------------------------------
-//
void CLocationRemappingAO::NextState(TMappingState aState)
{
LOG1( "CLocationRemappingAO::NextState - state: %d", aState ); // DEBUG INFO
@@ -251,11 +198,6 @@
}
}
-
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::DoCancel()
-// --------------------------------------------------------------------------
-//
void CLocationRemappingAO::DoCancel()
{
LOG( "CLocationRemappingAO::DoCancel" ); // DEBUG INFO
@@ -263,11 +205,6 @@
NextState(EIdle);
}
-
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::RunError()
-// --------------------------------------------------------------------------
-//
TInt CLocationRemappingAO::RunError( TInt aError )
{
if (aError != KErrNone)
@@ -279,11 +216,6 @@
return KErrNone;
}
-
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::RunL()
-// --------------------------------------------------------------------------
-//
void CLocationRemappingAO::RunL()
{
LOG1( "CCameraTrailMonitorAO::RunL iStatus: %d", iStatus.Int() ); // DEBUG INFO
@@ -320,10 +252,7 @@
}
}
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::RemapObjectsL()
-// --------------------------------------------------------------------------
-//
+
void CLocationRemappingAO::RemapObjectsL()
{
LOG( "CLocationRemappingAO::RemapObjects - start" ); // DEBUG INFO
@@ -385,14 +314,12 @@
relation = iMdEClient->GetRelationL( iRemapItems[i].iRelationId );
if(relation)
- {
- CleanupStack::PushL(relation);
+ {
TTime timestamp( 0 );
timestamp.UniversalTime();
relation->SetLastModifiedDate( timestamp );
iMdEClient->UpdateRelationL( *relation );
- CleanupStack::PopAndDestroy(relation);
}
}
@@ -404,11 +331,6 @@
LOG( "CLocationRemappingAO::RemapObjects - end" );
}
-
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::CommitObjectsL()
-// --------------------------------------------------------------------------
-//
void CLocationRemappingAO::CommitObjectsL()
{
LOG( "CLocationRemappingAO::CommitObjects" ); // DEBUG INFO
@@ -438,10 +360,7 @@
LOG( "CLocationRemappingAO::ReadTimeFromCenRepL(), end" );
}
-// --------------------------------------------------------------------------
-// CLocationRemappingAO::UpdateRelationsL()
-// --------------------------------------------------------------------------
-//
+
void CLocationRemappingAO::UpdateRelationsL( TItemId aLocationId )
{
LOG("CLocationRemappingAO::UpdateRelationsL - start");
@@ -462,16 +381,14 @@
iRemapItems[i].iObjectId, aLocationId, 0 );
iMdEClient->AddRelationL( *relationObject );
CleanupStack::PopAndDestroy( relationObject );
- LOG("new relation created");
+ LOG("CLocationRemappingAO::UpdateRelationsL - new relation created");
}
else
{
CMdERelation* relationObject = iMdEClient->GetRelationL( iRemapItems[i].iRelationId );
- CleanupStack::PushL(relationObject);
relationObject->SetRightObjectIdL( aLocationId );
iMdEClient->UpdateRelationL( *relationObject );
- CleanupStack::PopAndDestroy(relationObject);
- LOG("old relation updated");
+ LOG("CLocationRemappingAO::UpdateRelationsL - old relation updated");
}
iRemapItems.Remove( i );
}
@@ -479,30 +396,6 @@
LOG("CLocationRemappingAO::UpdateRelationsL - end");
}
-#ifdef LOC_REVERSEGEOCODE
-// --------------------------------------------------------------------------
-// CLocationRemapping::AttachGeoTagsL
-// --------------------------------------------------------------------------
-//
-void CLocationRemappingAO::AttachGeoTagsL( CTagCreator *aTagCreator,
- const TItemId aCountryTagId, const TItemId aCityTagId )
- {
- LOG("CLocationRemapping::AttachGeoTagsL - start");
-
- TInt count = iObjectIds.Count() - 1;
- for( TInt i = count; i >= 0; i-- )
- {
- aTagCreator->AttachTagsL( iObjectIds[i], aCountryTagId, aCityTagId );
- }
-
- iObjectIds.Reset();
-
- LOG("CLocationRemapping::AttachGeoTagsL - end");
- }
-
-#endif //LOC_REVERSEGEOCODE
-
-
// --------------------------------------------------------------------------
// TRemapItem constructor
// --------------------------------------------------------------------------
@@ -516,4 +409,3 @@
}
-// End of file