Index: chrome/browser/ui/webui/downloads_dom_handler.cc |
diff --git a/chrome/browser/ui/webui/downloads_dom_handler.cc b/chrome/browser/ui/webui/downloads_dom_handler.cc |
index 124b278084b02757b18d296904bb554ce45957ae..c57f89e41f1587ff4ae6ce9aa5d5276dd69c487f 100644 |
--- a/chrome/browser/ui/webui/downloads_dom_handler.cc |
+++ b/chrome/browser/ui/webui/downloads_dom_handler.cc |
@@ -514,14 +514,16 @@ void DownloadsDOMHandler::ShowDangerPrompt( |
dangerous_item, |
GetWebUIWebContents(), |
false, |
- base::Bind(&DownloadsDOMHandler::DangerPromptAccepted, |
- weak_ptr_factory_.GetWeakPtr(), dangerous_item->GetId()), |
- base::Closure()); |
+ base::Bind(&DownloadsDOMHandler::DangerPromptDone, |
+ weak_ptr_factory_.GetWeakPtr(), dangerous_item->GetId())); |
// danger_prompt will delete itself. |
DCHECK(danger_prompt); |
} |
-void DownloadsDOMHandler::DangerPromptAccepted(int download_id) { |
+void DownloadsDOMHandler::DangerPromptDone( |
+ int download_id, DownloadDangerPrompt::Action action) { |
+ if (action != DownloadDangerPrompt::ACCEPT) |
+ return; |
content::DownloadItem* item = NULL; |
if (main_notifier_.GetManager()) |
item = main_notifier_.GetManager()->GetDownload(download_id); |