--- a/webengine/osswebengine/WebCore/platform/network/symbian/HttpDownload.cpp Thu Aug 19 10:58:56 2010 +0300
+++ b/webengine/osswebengine/WebCore/platform/network/symbian/HttpDownload.cpp Tue Aug 31 16:17:46 2010 +0300
@@ -16,12 +16,12 @@
*/
#include "HttpDownload.h"
-#include <cdownloadmgruiuserinteractions.h>
-#include <cdownloadmgruidownloadslist.h>
+#include <CDownloadMgrUiUserInteractions.h>
+#include <CDownloadMgrUiDownloadsList.h>
#include "HttpDlConnection.h"
#include "HttpDefs.h"
#include "HttpSessionManager.h"
-#include "brctl.h"
+#include "BrCtl.h"
#include "StaticObjectsContainer.h"
// CONSTANTS
@@ -30,41 +30,15 @@
using namespace WebCore;
-// -----------------------------------------------------------------------------
-// HttpDownload::NewL
-//
-// Two-phased constructor.
-// -----------------------------------------------------------------------------
-//
-HttpDownload* HttpDownload::NewL(HttpSessionManager* sessionManager)
- {
- HttpDownload* self = new (ELeave) HttpDownload();
-
- CleanupStack::PushL (self);
- self->ConstructL ( sessionManager);
- CleanupStack::Pop ();
- return self;
- }
-
-HttpDownload::HttpDownload()
+HttpDownload::HttpDownload(HttpSessionManager* sessionManager)
{
+ m_sessionManager = sessionManager;
m_dMgrReady = false;
m_dMgrUiReg = NULL;
+ m_downloadObserver = StaticObjectsContainer::instance()->brctl()->brCtlDownloadObserver();
+ TRAP_IGNORE(PREPARE_DOWNLOAD_MANAGER)
}
-// -----------------------------------------------------------------------------
-// HttpDownload::ConstructL
-// Symbian 2nd phase constructor can leave.
-// by this method.
-// -----------------------------------------------------------------------------
-//
-void HttpDownload::ConstructL(HttpSessionManager* sessionManager)
- {
- m_sessionManager = sessionManager;
- m_downloadObserver = StaticObjectsContainer::instance()->brctl()->brCtlDownloadObserver();
- PREPARE_DOWNLOAD_MANAGER;
- }
-
HttpDownload::~HttpDownload()
{
delete m_dMgrUiReg;
@@ -98,10 +72,7 @@
if ( errMngr == KErrAlreadyExists && master ) {
m_downloadMgr.ConnectL( myProcess.Identity(), *this, EFalse );
}
- else
- {
- User::LeaveIfError(errMngr);
- }
+
if( !master ){
// Browser is embedded. Downloads must be paused when the user closes
// the embedded Browser (that is always started from the Launcher), and