Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(894)

Side by Side Diff: content/browser/download/download_manager_impl.cc

Issue 233723002: Workarounding fix for save complete page problems. Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « content/browser/download/download_manager_impl.h ('k') | content/browser/download/save_item.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/download/download_manager_impl.h" 5 #include "content/browser/download/download_manager_impl.h"
6 6
7 #include <iterator> 7 #include <iterator>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 500 matching lines...) Expand 10 before | Expand all | Expand 10 after
511 mime_type, 511 mime_type,
512 request_handle.Pass(), 512 request_handle.Pass(),
513 bound_net_log); 513 bound_net_log);
514 downloads_[download_item->GetId()] = download_item; 514 downloads_[download_item->GetId()] = download_item;
515 FOR_EACH_OBSERVER(Observer, observers_, OnDownloadCreated( 515 FOR_EACH_OBSERVER(Observer, observers_, OnDownloadCreated(
516 this, download_item)); 516 this, download_item));
517 if (!item_created.is_null()) 517 if (!item_created.is_null())
518 item_created.Run(download_item); 518 item_created.Run(download_item);
519 } 519 }
520 520
521 void DownloadManagerImpl::OnSavePackageSuccessfullyFinished( 521 void DownloadManagerImpl::OnSavePackageFinished(
522 DownloadItem* download_item) { 522 bool success, DownloadItem* download_item) {
523 FOR_EACH_OBSERVER(Observer, observers_, 523 FOR_EACH_OBSERVER(Observer, observers_,
524 OnSavePackageSuccessfullyFinished(this, download_item)); 524 OnSavePackageFinished(success, this, download_item));
525 } 525 }
526 526
527 // Resume a download of a specific URL. We send the request to the 527 // Resume a download of a specific URL. We send the request to the
528 // ResourceDispatcherHost, and let it send us responses like a regular 528 // ResourceDispatcherHost, and let it send us responses like a regular
529 // download. 529 // download.
530 void DownloadManagerImpl::ResumeInterruptedDownload( 530 void DownloadManagerImpl::ResumeInterruptedDownload(
531 scoped_ptr<content::DownloadUrlParameters> params, 531 scoped_ptr<content::DownloadUrlParameters> params,
532 uint32 id) { 532 uint32 id) {
533 RecordDownloadSource(INITIATED_BY_RESUMPTION); 533 RecordDownloadSource(INITIATED_BY_RESUMPTION);
534 BrowserThread::PostTask( 534 BrowserThread::PostTask(
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
708 if (delegate_) 708 if (delegate_)
709 delegate_->OpenDownload(download); 709 delegate_->OpenDownload(download);
710 } 710 }
711 711
712 void DownloadManagerImpl::ShowDownloadInShell(DownloadItemImpl* download) { 712 void DownloadManagerImpl::ShowDownloadInShell(DownloadItemImpl* download) {
713 if (delegate_) 713 if (delegate_)
714 delegate_->ShowDownloadInShell(download); 714 delegate_->ShowDownloadInShell(download);
715 } 715 }
716 716
717 } // namespace content 717 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/download/download_manager_impl.h ('k') | content/browser/download/save_item.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698