145 TN_DEBUG1( "CThumbAGCameraObserver::~CThumbAGCameraObserver() - begin" ); |
145 TN_DEBUG1( "CThumbAGCameraObserver::~CThumbAGCameraObserver() - begin" ); |
146 |
146 |
147 iShutdown = ETrue; |
147 iShutdown = ETrue; |
148 |
148 |
149 delete iMDSShutdownObserver; |
149 delete iMDSShutdownObserver; |
|
150 iMDSShutdownObserver = NULL; |
|
151 |
150 delete iShutdownObserver; |
152 delete iShutdownObserver; |
|
153 iShutdownObserver = NULL; |
151 |
154 |
152 if(iReconnect) |
155 if(iReconnect) |
153 { |
156 { |
154 iReconnect->Cancel(); |
157 iReconnect->Cancel(); |
155 delete iReconnect; |
158 delete iReconnect; |
298 CMdEObjectDef& objectDef = defaultNamespace.GetObjectDefL( MdeConstants::Object::KBaseObject ); |
301 CMdEObjectDef& objectDef = defaultNamespace.GetObjectDefL( MdeConstants::Object::KBaseObject ); |
299 CMdEPropertyDef& originPropDef = objectDef.GetPropertyDefL( MdeConstants::Object::KOriginProperty ); |
302 CMdEPropertyDef& originPropDef = objectDef.GetPropertyDefL( MdeConstants::Object::KOriginProperty ); |
300 |
303 |
301 // set observing conditions |
304 // set observing conditions |
302 CMdELogicCondition* addCondition = CMdELogicCondition::NewLC( ELogicConditionOperatorAnd ); |
305 CMdELogicCondition* addCondition = CMdELogicCondition::NewLC( ELogicConditionOperatorAnd ); |
303 addCondition->AddPropertyConditionL( originPropDef, TMdEUintEqual(MdeConstants::Object::ECamera)); |
306 CMdEPropertyCondition& addPropertyCondition = addCondition->AddPropertyConditionL( originPropDef, TMdEUintEqual(MdeConstants::Object::ECamera)); |
304 CleanupStack::Pop( addCondition ); |
307 CleanupStack::PushL( &addPropertyCondition ); |
305 |
308 |
306 CMdELogicCondition* modifyCondition = CMdELogicCondition::NewLC( ELogicConditionOperatorAnd ); |
309 CMdELogicCondition* modifyCondition = CMdELogicCondition::NewLC( ELogicConditionOperatorAnd ); |
307 modifyCondition->AddPropertyConditionL( originPropDef, TMdEUintEqual(MdeConstants::Object::ECamera)); |
310 CMdEPropertyCondition& modifyPropertyCondition = modifyCondition->AddPropertyConditionL( originPropDef, TMdEUintEqual(MdeConstants::Object::ECamera)); |
308 CleanupStack::Pop( modifyCondition ); |
311 CleanupStack::PushL( &modifyPropertyCondition ); |
309 |
312 |
310 // add observer |
313 // add observer |
311 iMdESession->AddObjectObserverL( *this, addCondition, ENotifyAdd ); |
314 iMdESession->AddObjectObserverL( *this, addCondition, ENotifyAdd ); |
312 |
315 |
313 // modify observer |
316 // modify observer |
314 iMdESession->AddObjectObserverL( *this, modifyCondition, ENotifyModify ); |
317 iMdESession->AddObjectObserverL( *this, modifyCondition, ENotifyModify ); |
|
318 |
|
319 CleanupStack::Pop( 4, addCondition ); |
315 |
320 |
316 TN_DEBUG1( "CThumbAGCameraObserver::AddObserversL() - end" ); |
321 TN_DEBUG1( "CThumbAGCameraObserver::AddObserversL() - end" ); |
317 } |
322 } |
318 |
323 |
319 // --------------------------------------------------------------------------- |
324 // --------------------------------------------------------------------------- |