diff -r 88330f36f634 -r 41137c634688 inc/DrmUtilityDmgrWrapper.h --- a/inc/DrmUtilityDmgrWrapper.h Wed Jun 23 18:30:42 2010 +0300 +++ b/inc/DrmUtilityDmgrWrapper.h Tue Jul 06 14:34:12 2010 +0300 @@ -20,10 +20,13 @@ #define CDRMUTILITYDMGRWRAPPER_H #include // RFs -#include #include // Roap::MRoapObserver #include // MAknProgressDialogCallback CAknProgressDialog +// download apis +#include +#include +#include namespace Roap { @@ -36,7 +39,8 @@ } class CDRMRights; class CEikProgressInfo; - +class DrmUtilityEventHandler; +class QDrmUtilityDmgrEventHandler; /** * Environment gate function @@ -67,7 +71,6 @@ */ class CDrmUtilityDmgrWrapper : public CActive, - public MHttpDownloadMgrObserver, public Roap::MRoapObserver, public MDrmUtilityDmgrWrapper, public MProgressDialogCallback @@ -105,18 +108,6 @@ HBufC8* GetErrorUrlL(); - - // from base class MHttpDownloadMgrObserver - - /** - * From MHttpDownloadMgrObserver. - * Handle download manager events - * - * @param aDownload the download - * @param aEvent the event - */ - void HandleDMgrEventL( RHttpDownload& aDownload, THttpDownloadEvent aEvent ); - // From Roap::MRoapObserver /** * ConnectionConfL @@ -252,6 +243,14 @@ * @param aButtonId ID of the button pressed */ void DialogDismissedL( TInt aButtonId ); + + /** + * Handle download manager events + * + * @param aEvent the event + */ + + void HandleDownloadEventL( WRT::DownloadEvent* aEvent ); protected: //from Cactive @@ -287,15 +286,22 @@ void DoHandleRoapTriggerL( TDownloadState aNextState ); void CompleteToState( TDownloadState aNextState, TInt aError ); + + void ProcessDownloadEventL( WRT::Download& aDownload, WRT::DownloadEvent& aEvent ); private: // data /** * Download manager session */ - RHttpDownloadMgr iDlMgr; + WRT::DownloadManager* iDlMgr; /** + * Download instance needs to be stored for handling signal slot mechanism + */ + WRT::Download* iDownload; + + /** * Used to make downloads synchronous */ CActiveSchedulerWait iWait; @@ -360,6 +366,8 @@ HBufC* iFileName; DRM::CDrmUtilityConnection* iConnection; + + QDrmUtilityDmgrEventHandler* iDrmUtilityDmgrEventHandler; }; #endif // CDRMUTILITYDMGRWRAPPER_H