diff -r 5181328fad28 -r efe289f793e7 filemanager/schbkup/src/filemanagerschbackuptask.cpp --- a/filemanager/schbkup/src/filemanagerschbackuptask.cpp Tue May 11 16:01:48 2010 +0300 +++ b/filemanager/schbkup/src/filemanagerschbackuptask.cpp Tue May 25 12:28:34 2010 +0300 @@ -126,6 +126,7 @@ delete iSubscriber; delete iCenRep; + delete iSystemStateMonitor; Cancel(); } @@ -198,6 +199,9 @@ parse.Assign( data ); User::LeaveIfError( parse.Val( iDay ) ); } + + // Get pointer to system state monitor + iSystemStateMonitor = CFmSystemStateMonitor::NewL( *this ); Retry(); } @@ -246,6 +250,15 @@ // TBool CFileManagerSchBackupTask::CheckPhoneStateL() { + + // Check phone is normal state or not + if ( !iSystemStateMonitor->IsSystemStateNormal() ) + { + INFO_LOG( "CFileManagerSchBackupTask::CheckPhoneStateL()-System State is not normal" ) + iSystemStateMonitor->StartMonitor( ESsmNormal ); + return EFalse; + } + // Check call state TInt callState( 0 ); RProperty::Get( @@ -471,4 +484,16 @@ } } +// --------------------------------------------------------------------------- +// CFileManagerSchBackupTask::SystemStateChangedEvent +// --------------------------------------------------------------------------- +// +void CFileManagerSchBackupTask::SystemStateChangedEvent() + { + FUNC_LOG + + // Backup was not started, try starting it again + Retry(); + } + // End of file