Fix bug 299839: prevent 'reset camino' from deleting downloaded files by preventing -cancel: from doing anything on completed downloads. r=me, sr=pinkerton.

This commit is contained in:
smfr%smfr.org 2005-07-17 04:51:20 +00:00
Родитель 0c99614933
Коммит c7eed5f33e
1 изменённых файлов: 3 добавлений и 2 удалений

Просмотреть файл

@ -220,8 +220,9 @@ enum {
-(IBAction)cancel:(id)sender
{
// don't allow download to be cancelled twice or we get a nasty crash
if (!mUserCancelled) {
// don't allow download to be cancelled twice or we get a nasty crash,
// and don't cancel completed downloads, because that deletes the file
if (!mUserCancelled && !mDownloadDone) {
mUserCancelled = YES;
if (mDownloader) { // we should always have one