equal
deleted
inserted
replaced
19 // INCLUDE FILES |
19 // INCLUDE FILES |
20 #include "cvimpstcmddeletecontact.h" |
20 #include "cvimpstcmddeletecontact.h" |
21 |
21 |
22 #include "vimpstcmd.hrh" |
22 #include "vimpstcmd.hrh" |
23 #include "mvimpstcmdobserver.h" |
23 #include "mvimpstcmdobserver.h" |
24 #include "vimpstdebugprint.h" |
24 |
|
25 #include "uiservicetabtracer.h" |
25 |
26 |
26 #include <e32def.h> |
27 #include <e32def.h> |
27 #include "mvimpstengine.h" |
28 #include "mvimpstengine.h" |
28 #include "cvimpststoragemanagerfactory.h" |
29 #include "cvimpststoragemanagerfactory.h" |
29 #include "mvimpststorageserviceview.h" |
30 #include "mvimpststorageserviceview.h" |
70 // |
71 // |
71 CVIMPSTCmdDeleteContact* CVIMPSTCmdDeleteContact::NewL( |
72 CVIMPSTCmdDeleteContact* CVIMPSTCmdDeleteContact::NewL( |
72 const TInt aCommandId, MVPbkContactLink* aContactLink, |
73 const TInt aCommandId, MVPbkContactLink* aContactLink, |
73 MVIMPSTEngine& aEngine) |
74 MVIMPSTEngine& aEngine) |
74 { |
75 { |
|
76 TRACER_AUTO; |
75 CVIMPSTCmdDeleteContact* self = new (ELeave ) CVIMPSTCmdDeleteContact( aCommandId ,aContactLink, aEngine); |
77 CVIMPSTCmdDeleteContact* self = new (ELeave ) CVIMPSTCmdDeleteContact( aCommandId ,aContactLink, aEngine); |
76 self->ConstructL(); //use contsurctL if necessary |
78 self->ConstructL(); //use contsurctL if necessary |
77 return self; |
79 return self; |
78 } |
80 } |
79 // -------------------------------------------------------------------------- |
81 // -------------------------------------------------------------------------- |
89 // CVIMPSTCmdDeleteContact::ExecuteLD |
91 // CVIMPSTCmdDeleteContact::ExecuteLD |
90 // -------------------------------------------------------------------------- |
92 // -------------------------------------------------------------------------- |
91 // |
93 // |
92 void CVIMPSTCmdDeleteContact::ExecuteLD() |
94 void CVIMPSTCmdDeleteContact::ExecuteLD() |
93 { |
95 { |
94 CHAT_DP_FUNC_ENTER("CVIMPSTCmdDeleteContact::ExecuteLD"); |
96 |
|
97 TRACER_AUTO; |
95 //push to the cleanupstack |
98 //push to the cleanupstack |
96 CleanupStack::PushL( this ); |
99 CleanupStack::PushL( this ); |
97 iError = KErrNone; |
100 iError = KErrNone; |
98 MVIMPSTStorageServiceView* storage = CVIMPSTStorageManagerFactory::ContactListInterfaceL( iEngine.ServiceId()) ; |
101 MVIMPSTStorageServiceView* storage = CVIMPSTStorageManagerFactory::ContactListInterfaceL( iEngine.ServiceId()) ; |
99 if(storage) |
102 if(storage) |
138 { |
141 { |
139 storage->RemoveContactL( contact ); |
142 storage->RemoveContactL( contact ); |
140 } |
143 } |
141 } // contact |
144 } // contact |
142 } // storage |
145 } // storage |
143 CHAT_DP_FUNC_ENTER("CVIMPSTCmdDeleteContact:: CommandFinished"); |
146 |
144 |
147 |
145 if(iObserver) |
148 if(iObserver) |
146 { |
149 { |
147 iObserver->CommandFinishedL(*this); |
150 iObserver->CommandFinishedL(*this); |
148 } |
151 } |
149 CHAT_DP_FUNC_ENTER("CVIMPSTCmdDeleteContact:: CommandFinished"); |
152 |
150 CleanupStack::PopAndDestroy(); |
153 CleanupStack::PopAndDestroy(); |
151 CHAT_DP_FUNC_DONE("CVIMPSTCmdDeleteContact::ExecuteLD"); |
154 |
152 } |
155 } |
153 |
156 |
154 |
157 |
155 // -------------------------------------------------------------------------- |
158 // -------------------------------------------------------------------------- |
156 // CVIMPSTCmdDeleteContact::AddObserver |
159 // CVIMPSTCmdDeleteContact::AddObserver |