summaryrefslogtreecommitdiff
path: root/src/download
diff options
context:
space:
mode:
Diffstat (limited to 'src/download')
-rw-r--r--src/download/downloadmanager.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/download/downloadmanager.cpp b/src/download/downloadmanager.cpp
index 151858d2..560ddb9d 100644
--- a/src/download/downloadmanager.cpp
+++ b/src/download/downloadmanager.cpp
@@ -263,14 +263,15 @@ bool DownloadManager::downloadResource(const KUrl &srcUrl, const KIO::MetaData &
return true;
}
- KIO::CopyJob *job = KIO::copy(srcUrl, destUrl, KIO::Overwrite);
+ KIO::CopyJob *job = KIO::copy(srcUrl, destUrl);
if (!metaData.isEmpty())
job->setMetaData(metaData);
job->addMetaData(QL1S("MaxCacheSize"), QL1S("0")); // Don't store in http cache.
job->addMetaData(QL1S("cache"), QL1S("cache")); // Use entry from cache if available.
- job->uiDelegate()->setAutoErrorHandlingEnabled(true);
+ job->ui()->setWindow((parent ? parent->window() : 0));
+ job->ui()->setAutoErrorHandlingEnabled(true);
addDownload(job);
return true;