browserutilities/downloadmgr/DownloadMgrUiLib/Src/CDownloadMgrUiUserInteractions.cpp
changeset 37 cb62a4f66ebe
parent 36 0ed94ceaa377
child 62 c711bdda59f4
child 65 5bfc169077b2
equal deleted inserted replaced
36:0ed94ceaa377 37:cb62a4f66ebe
    13 *
    13 *
    14 * Description:  Supports user interaction dialogs for downloads
    14 * Description:  Supports user interaction dialogs for downloads
    15 *
    15 *
    16 */
    16 */
    17 
    17 
    18 
       
    19 
       
    20 // INCLUDE FILES
    18 // INCLUDE FILES
    21 #include    "cdownloadmgruiuserinteractions.h"
    19 #include    <cdownloadmgruiuserinteractions.h>
    22 #include    "CUserInteractionsUtils.h"
    20 #include    "CUserInteractionsUtils.h"
    23 #include    "cdownloadmgruidownloadslist.h"
    21 #include    <cdownloadmgruidownloadslist.h>
    24 #include    "cdownloadmgruilibregistry.h"
    22 #include    <cdownloadmgruilibregistry.h>
    25 #include    "UserInteractionsEventHandler.h"
    23 #include    "UserInteractionsEventHandler.h"
    26 #include    "AsyncEventHandlerArray.h"
    24 #include    "AsyncEventHandlerArray.h"
    27 #include    "UiLibLogger.h"
    25 #include    "UiLibLogger.h"
    28 #include    "DMgrUiLibPanic.h"
    26 #include    "DMgrUiLibPanic.h"
    29 #include    "MDownloadHandlerObserver.h"
    27 #include    "MDownloadHandlerObserver.h"
   455         TInt resp = conf->RunLD();
   453         TInt resp = conf->RunLD();
   456         CleanupStack::PopAndDestroy( prompt ); // prompt
   454         CleanupStack::PopAndDestroy( prompt ); // prompt
   457         
   455         
   458         downloadCnt = iRegistryModel.DownloadCount();
   456         downloadCnt = iRegistryModel.DownloadCount();
   459 
   457 
   460         TBool isProgressive (EFalse);
   458        
   461         if ( resp == EAknSoftkeyYes || resp == EAknSoftkeyOk )
   459         if ( resp == EAknSoftkeyYes || resp == EAknSoftkeyOk )
   462 		    {
   460 		    {
   463             for ( TInt i = downloadCnt - 1; i >=0; --i )
   461             for ( TInt i = downloadCnt - 1; i >=0; --i )
   464 		        {
   462 		        {
   465 	            RHttpDownload* dl = downloads.At(i); //current download
   463 	            RHttpDownload* dl = downloads.At(i); //current download
   466                 dl->GetBoolAttribute( EDlAttrProgressive, isProgressive );
       
   467                 dl->GetBoolAttribute( EDlAttrPausable , isPausable );
   464                 dl->GetBoolAttribute( EDlAttrPausable , isPausable );
   468                 if (!( isProgressive || isPausable ) ) // delete only no-PDL downloads and Non pausable Downloads
   465                 if (!( isPausable ) ) // delete only Non pausable Downloads
   469     			    {
   466     			    {
   470                     // Delete not attached downloads.
   467                     // Delete not attached downloads.
   471     	            dl->Delete(); // Return value ignored.
   468     	            dl->Delete(); // Return value ignored.
   472 			        }
   469 			        }
   473 		        }
   470 		        }