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

Unified Diff: chrome/browser/safe_browsing/download_protection_service.cc

Issue 10421021: Make DownloadProtectionService not use BrowserList::GetLastActive() to load a link. Instead pass th… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/safe_browsing/download_protection_service.cc
===================================================================
--- chrome/browser/safe_browsing/download_protection_service.cc (revision 138377)
+++ chrome/browser/safe_browsing/download_protection_service.cc (working copy)
@@ -865,13 +865,14 @@
}
void DownloadProtectionService::ShowDetailsForDownload(
- const DownloadProtectionService::DownloadInfo& info) {
- Browser* browser = BrowserList::GetLastActive();
- DCHECK(browser && browser->is_type_tabbed());
- content::OpenURLParams params(GURL(chrome::kDownloadScanningLearnMoreURL),
- content::Referrer(), NEW_FOREGROUND_TAB,
- content::PAGE_TRANSITION_TYPED, false);
- browser->OpenURL(params);
+ const DownloadProtectionService::DownloadInfo& info,
+ content::PageNavigator* navigator) {
+ navigator->OpenURL(
+ content::OpenURLParams(GURL(chrome::kDownloadScanningLearnMoreURL),
+ content::Referrer(),
+ NEW_FOREGROUND_TAB,
+ content::PAGE_TRANSITION_LINK,
+ false));
}
namespace {

Powered by Google App Engine
This is Rietveld 408576698