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

Unified Diff: chrome/browser/chrome_content_browser_client.cc

Issue 2344293002: [HBD] Detect user-initiated Flash download in a new window (Closed)
Patch Set: fix mac test Created 4 years, 3 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
« no previous file with comments | « no previous file | chrome/browser/content_settings/host_content_settings_map_factory.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chrome_content_browser_client.cc
diff --git a/chrome/browser/chrome_content_browser_client.cc b/chrome/browser/chrome_content_browser_client.cc
index 71fb48b244cb8e6fee0f474832a27def252e25e0..75f55865d9af7afdec687c40cd8a6c800f5a8107 100644
--- a/chrome/browser/chrome_content_browser_client.cc
+++ b/chrome/browser/chrome_content_browser_client.cc
@@ -2253,6 +2253,16 @@ bool ChromeContentBrowserClient::CanCreateWindow(
HostContentSettingsMap* content_settings =
ProfileIOData::FromResourceContext(context)->GetHostContentSettingsMap();
+
+#if defined(ENABLE_PLUGINS)
+ if (FlashDownloadInterception::ShouldStopFlashDownloadAction(
+ content_settings, opener_top_level_frame_url, target_url,
+ user_gesture)) {
+ // TODO(crbug.com/626728): Implement permission prompt logic.
+ return false;
+ }
+#endif
+
BlockedWindowParams blocked_params(target_url,
referrer,
frame_name,
« no previous file with comments | « no previous file | chrome/browser/content_settings/host_content_settings_map_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698