XDMEngine/src/XdmDocument.cpp
branchRCL_3
changeset 7 96b99892dd80
parent 0 c8caa15ef882
equal deleted inserted replaced
6:aca99fb8a3dd 7:96b99892dd80
    95 void CXdmDocument::EmptyOperationQueue()
    95 void CXdmDocument::EmptyOperationQueue()
    96     {
    96     {
    97     #ifdef _DEBUG
    97     #ifdef _DEBUG
    98         iXdmEngine.WriteToLog( _L8( "CXdmDocument::EmptyOperationQueue()" ) );
    98         iXdmEngine.WriteToLog( _L8( "CXdmDocument::EmptyOperationQueue()" ) );
    99     #endif
    99     #endif
   100     MXdmOperation* operation = NULL;
   100     
   101     TInt count = iChangeRequests.Count();
   101     while (iChangeRequests.Count())
   102     for( TInt i = 0;i < count;i++ )
   102         {
   103         {
   103         MXdmOperation* operation = iChangeRequests[0];
   104         operation = iChangeRequests[i];
   104         iChangeRequests.Remove( 0 );    
   105         iChangeRequests.Remove( i );    
       
   106         operation->Destroy();
   105         operation->Destroy();
   107         operation = NULL;
   106         operation = NULL;
   108         }
   107         }
   109     }
   108     }
   110     
   109