telephonyserverplugins/common_tsy/commontsy/src/mmtsy/cmmsecuritytsy.cpp
branchRCL_3
changeset 18 17af172ffa5f
parent 0 3553901f7fa8
child 19 630d2f34d719
equal deleted inserted replaced
17:1ac40e087278 18:17af172ffa5f
     1 // Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
     1 // Copyright (c) 2006-2010 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     3 // This component and the accompanying materials are made available
     4 // under the terms of "Eclipse Public License v1.0"
     4 // under the terms of "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
   103         case EMobilePhoneNotifySecurityCapsChange:
   103         case EMobilePhoneNotifySecurityCapsChange:
   104             ret = NotifySecurityCapsChange(
   104             ret = NotifySecurityCapsChange(
   105                 REINTERPRET_CAST( TUint32*, dataPtr ) );
   105                 REINTERPRET_CAST( TUint32*, dataPtr ) );
   106             break;
   106             break;
   107                 case EMobilePhoneGetLockInfo:
   107                 case EMobilePhoneGetLockInfo:
   108             ret = GetLockInfoL( aPackage );
   108             ret = GetLockInfoL( aTsyReqHandle, aPackage );
   109             break;
   109             break;
   110         // Notify Change of Lock Information
   110         // Notify Change of Lock Information
   111         case EMobilePhoneNotifyLockInfoChange:
   111         case EMobilePhoneNotifyLockInfoChange:
   112             ret = NotifyLockInfoChange(  
   112             ret = NotifyLockInfoChange(  
   113                 REINTERPRET_CAST( RMobilePhone::TMobilePhoneLock*, dataPtr ),
   113                 REINTERPRET_CAST( RMobilePhone::TMobilePhoneLock*, dataPtr ),
   286 // CMmSecurityTsy::GetLockInfoL
   286 // CMmSecurityTsy::GetLockInfoL
   287 // This method retrieves the current status and setting of a lock.   
   287 // This method retrieves the current status and setting of a lock.   
   288 // (other items were commented in a header).
   288 // (other items were commented in a header).
   289 // ---------------------------------------------------------------------------
   289 // ---------------------------------------------------------------------------
   290 //
   290 //
   291 TInt CMmSecurityTsy::GetLockInfoL( const TDataPackage& aPackage ) 
   291 TInt CMmSecurityTsy::GetLockInfoL( const TTsyReqHandle aTsyReqHandle, const TDataPackage& aPackage ) 
   292     {
   292     {
   293 TFLOGSTRING("LTSY: CMmSecurityTsy::GetLockInfoL - Client call");
   293 TFLOGSTRING("LTSY: CMmSecurityTsy::GetLockInfoL - Client call");
   294     
   294     
   295     TInt ret ( KErrArgument );
   295     TInt ret ( KErrArgument );
   296     
   296     
   300         data->MaxLength() )
   300         data->MaxLength() )
   301         {   
   301         {   
   302         //save pointer to client side for completion
   302         //save pointer to client side for completion
   303         iRetGetLockInfo = data;
   303         iRetGetLockInfo = data;
   304 
   304 
       
   305 #ifdef REQHANDLE_TIMER
       
   306         iMmPhoneTsy->SetTypeOfResponse( CMmPhoneTsy::EMultimodePhoneGetLockInfo, aTsyReqHandle );
       
   307 #else
       
   308         iMmPhoneTsy->iTsyReqHandleStore->SetTsyReqHandle( 
       
   309                     CMmPhoneTsy::EMultimodePhoneGetLockInfo, aTsyReqHandle );
       
   310 #endif //REQHANDLE_TIMER
       
   311 
   305         ret = iMmPhoneTsy->iMmPhoneExtInterface->GetLockInfoL( aPackage );
   312         ret = iMmPhoneTsy->iMmPhoneExtInterface->GetLockInfoL( aPackage );
   306          
   313          
   307         if ( KErrNone == ret )
   314         if ( KErrNone != ret )
   308             {
   315             {
   309             //save req handle type
   316             iMmPhoneTsy->iTsyReqHandleStore->ResetTsyReqHandle( CMmPhoneTsy::EMultimodePhoneGetLockInfo );
   310             iMmPhoneTsy->iReqHandleType = 
       
   311                 CMmPhoneTsy::EMultimodePhoneGetLockInfo;
       
   312             }
   317             }
   313         }
   318         }
   314 
   319 
   315     return ret;
   320     return ret;
   316     }
   321     }