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

Unified Diff: chrome/browser/download/chrome_download_manager_delegate.cc

Issue 2478583004: implementation for new duplicate download UI (Closed)
Patch Set: grouping inherited methods Created 4 years, 1 month 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/download/chrome_download_manager_delegate.cc
diff --git a/chrome/browser/download/chrome_download_manager_delegate.cc b/chrome/browser/download/chrome_download_manager_delegate.cc
index c151f3e44f63f0d7c13715d52176b9115e634039..c514a0f95f6354f50d3a69ca296401d08d1b960d 100644
--- a/chrome/browser/download/chrome_download_manager_delegate.cc
+++ b/chrome/browser/download/chrome_download_manager_delegate.cc
@@ -57,7 +57,7 @@
#include "ui/base/l10n/l10n_util.h"
#if BUILDFLAG(ANDROID_JAVA_UI)
-#include "chrome/browser/android/download/chrome_download_manager_overwrite_infobar_delegate.h"
+#include "chrome/browser/android/download/chrome_duplicate_download_infobar_delegate.h"
#include "chrome/browser/infobars/infobar_service.h"
#endif
@@ -617,9 +617,11 @@ void ChromeDownloadManagerDelegate::PromptUserForDownloadPath(
const DownloadTargetDeterminerDelegate::FileSelectedCallback& callback) {
DCHECK_CURRENTLY_ON(BrowserThread::UI);
#if BUILDFLAG(ANDROID_JAVA_UI)
- chrome::android::ChromeDownloadManagerOverwriteInfoBarDelegate::Create(
- InfoBarService::FromWebContents(download->GetWebContents()), download,
- suggested_path, callback);
+ content::WebContents* web_contents = download->GetWebContents();
asanka 2016/11/10 20:49:39 It's possible for the WebContents to be null here.
qinmin 2016/11/10 21:37:08 null WebContents caused by resumption attempt with
asanka 2016/11/10 21:57:13 Sure. But ReserveVirtualPathDone() isn't where we
+ chrome::android::ChromeDuplicateDownloadInfoBarDelegate::Create(
+ InfoBarService::FromWebContents(web_contents), download,
+ suggested_path, web_contents->GetBrowserContext()->IsOffTheRecord(),
asanka 2016/11/10 20:49:39 Nit: IsOffTheRecord() is redundant. ChromeDuplicat
qinmin 2016/11/10 21:37:08 Done.
+ callback);
#else
DownloadFilePicker::ShowFilePicker(download, suggested_path, callback);
#endif
« no previous file with comments | « chrome/browser/android/offline_pages/downloads/offline_page_infobar_delegate.cc ('k') | chrome/browser/ui/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698