diff -r 63339781d179 -r 09b1ac925e3f remotelock/RemoteLockEngine/Src/RemoteLock.cpp --- a/remotelock/RemoteLockEngine/Src/RemoteLock.cpp Thu Aug 19 10:45:23 2010 +0300 +++ b/remotelock/RemoteLockEngine/Src/RemoteLock.cpp Tue Aug 31 16:04:40 2010 +0300 @@ -33,6 +33,7 @@ #include #endif //RD_MULTIPLE_DRIVE #include +#include #include #include #include @@ -625,7 +626,7 @@ if ( !iProfileSession ) { RL_TRACE_PRINT(" [ rl.exe ] CheckSettingsL() create session "); - iProfileSession = CRepository::NewL( KCRUidProfileEngine ); + iProfileSession = CRepository::NewL( KCRUidCoreApplicationUIs ); // previously it was KCRUidProfileEngine } if ( !iObserver ) { @@ -655,7 +656,7 @@ if ( !iProfileSession ) { RL_TRACE_PRINT(" [ rl.exe ] CheckSettingsL() create session "); - iProfileSession = CRepository::NewL( KCRUidProfileEngine ); + iProfileSession = CRepository::NewL( KCRUidCoreApplicationUIs ); // previously it was KCRUidProfileEngine } ProfileNotifyL( EFalse ); delete iProfileSession; @@ -1458,7 +1459,10 @@ if ( aNotifyEnable ) { - TInt err = iProfileSession->Get( KProEngActiveProfile, iCurrentProfile ); + TInt err = iProfileSession->Get( KCoreAppUIsNetworkConnectionAllowed , iCurrentProfile ); // previously was KProEngActiveProfile + RL_TRACE_PRINT_NUM("[rl.exe] HandleNotifyGeneric() err = %d", err ); + RL_TRACE_PRINT_NUM("[rl.exe] HandleNotifyGeneric() iCurrentProfile = %d", iCurrentProfile ); + User::LeaveIfError( err ); RL_TRACE_PRINT(" [ rl.exe ] ProfileNotifyL() startlisten"); iProfileNotifyHandler->StartListeningL(); @@ -1486,7 +1490,9 @@ { RL_TRACE_PRINT(" [ rl.exe ] GetProfile() "); TInt err; - err = iProfileSession->Get( KProEngActiveProfile, aProfile ); + err = iProfileSession->Get( KCoreAppUIsNetworkConnectionAllowed , aProfile ); // previously was KProEngActiveProfile + RL_TRACE_PRINT_NUM("[rl.exe] HandleNotifyGeneric() err = %d", err ); + RL_TRACE_PRINT(" [ rl.exe ] exit GetProfile() "); return ( err == KErrNone ); } @@ -1505,8 +1511,9 @@ TInt profile = 0; GetProfile( profile ); - - if ( ( profile == EProfileOffLineId ) && ( iIsEnabled ) && ( iCurrentProfile != EProfileOffLineId )) + RL_TRACE_PRINT_NUM("[rl.exe] HandleNotifyGeneric() profile = %d", profile ); + RL_TRACE_PRINT_NUM("[rl.exe] HandleNotifyGeneric() iCurrentProfile = %d", iCurrentProfile ); + if ( ( profile == ECoreAppUIsNetworkConnectionNotAllowed ) && ( iIsEnabled ) && ( iCurrentProfile != ECoreAppUIsNetworkConnectionNotAllowed )) { ActivateDeviceLock(); }