emailuis/emailui/src/freestyleemailuimailboxdeleter.cpp
branchRCL_3
changeset 61 dcf0eedfc1a3
parent 13 0396474f30f5
equal deleted inserted replaced
60:d620048b4810 61:dcf0eedfc1a3
   298     	return;
   298     	return;
   299     	}
   299     	}
   300     
   300     
   301     // Start wait note.
   301     // Start wait note.
   302     iWaitDialog = new ( ELeave ) CAknWaitDialog(
   302     iWaitDialog = new ( ELeave ) CAknWaitDialog(
   303         ( REINTERPRET_CAST( CEikDialog**, &iWaitDialog ) ), EFalse );
   303         ( REINTERPRET_CAST( CEikDialog**, &iWaitDialog ) ), ETrue );
   304     iWaitDialog->PrepareLC( R_FS_WAIT_NOTE_REMOVING_MAILBOX );
   304     iWaitDialog->PrepareLC( R_FS_WAIT_NOTE_REMOVING_MAILBOX );
   305     iWaitDialog->SetCallback( this );
   305     iWaitDialog->SetCallback( this );
   306     iWaitDialog->RunLD();
   306     iWaitDialog->RunLD();
   307 
   307 
   308     // Set email indicator off.
   308     // Set email indicator off.
   461     switch( aEvent.iProgressStatus )
   461     switch( aEvent.iProgressStatus )
   462         {
   462         {
   463         case TFSProgress::EFSStatus_RequestComplete:
   463         case TFSProgress::EFSStatus_RequestComplete:
   464         case TFSProgress::EFSStatus_RequestCancelled:
   464         case TFSProgress::EFSStatus_RequestCancelled:
   465             {
   465             {
   466             if( aRequestId == iMailboxDeleteOperationId )
   466             if( iMailboxesToDelete.Count() > 0 )
   467                 {
   467             	{
   468                 if( iMailboxesToDelete.Count() > 0 )
   468                 // Delete next mailbox in queue.
       
   469                 iIdle->Cancel();
       
   470                 iIdle->Start(TCallBack(IdleCallbackL,this));
       
   471             	}
       
   472             else
       
   473             	{
       
   474                 if( iWaitDialog )
   469                     {
   475                     {
   470                     // Delete next mailbox in queue.
   476                     iWaitDialog->ProcessFinishedL();
   471             	    iIdle->Cancel();
       
   472             		iIdle->Start(TCallBack(IdleCallbackL,this));
       
   473                     }
   477                     }
   474                 else
   478                 // Notify observer that the deletion is complete. 
   475                     {
   479                 iObserver.MailboxDeletionComplete();
   476                     if( iWaitDialog )
   480             	}          
   477                         {
       
   478                         iWaitDialog->ProcessFinishedL();
       
   479                         }
       
   480                     // Notify observer that the deletion is complete. 
       
   481                     iObserver.MailboxDeletionComplete();
       
   482                     }
       
   483                 }            
       
   484             break;
   481             break;
   485             }
   482             }
   486         default:
   483         default:
   487             {
   484             {
   488             break;
   485             break;