OLD | NEW |
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 // Implementation of the SafeBrowsingBlockingPage class. | 5 // Implementation of the SafeBrowsingBlockingPage class. |
6 | 6 |
7 #include "chrome/browser/safe_browsing/safe_browsing_blocking_page.h" | 7 #include "chrome/browser/safe_browsing/safe_browsing_blocking_page.h" |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 &SafeBrowsingBlockingPage::kTypeForTesting; | 120 &SafeBrowsingBlockingPage::kTypeForTesting; |
121 | 121 |
122 SafeBrowsingBlockingPage::SafeBrowsingBlockingPage( | 122 SafeBrowsingBlockingPage::SafeBrowsingBlockingPage( |
123 SafeBrowsingUIManager* ui_manager, | 123 SafeBrowsingUIManager* ui_manager, |
124 WebContents* web_contents, | 124 WebContents* web_contents, |
125 const UnsafeResourceList& unsafe_resources) | 125 const UnsafeResourceList& unsafe_resources) |
126 : SecurityInterstitialPage(web_contents, unsafe_resources[0].url), | 126 : SecurityInterstitialPage(web_contents, unsafe_resources[0].url), |
127 malware_details_proceed_delay_ms_( | 127 malware_details_proceed_delay_ms_( |
128 kMalwareDetailsProceedDelayMilliSeconds), | 128 kMalwareDetailsProceedDelayMilliSeconds), |
129 ui_manager_(ui_manager), | 129 ui_manager_(ui_manager), |
130 report_loop_(NULL), | |
131 is_main_frame_load_blocked_(IsMainPageLoadBlocked(unsafe_resources)), | 130 is_main_frame_load_blocked_(IsMainPageLoadBlocked(unsafe_resources)), |
132 unsafe_resources_(unsafe_resources), | 131 unsafe_resources_(unsafe_resources), |
133 proceeded_(false) { | 132 proceeded_(false) { |
134 bool malware = false; | 133 bool malware = false; |
135 bool harmful = false; | 134 bool harmful = false; |
136 bool phishing = false; | 135 bool phishing = false; |
137 for (UnsafeResourceList::const_iterator iter = unsafe_resources_.begin(); | 136 for (UnsafeResourceList::const_iterator iter = unsafe_resources_.begin(); |
138 iter != unsafe_resources_.end(); ++iter) { | 137 iter != unsafe_resources_.end(); ++iter) { |
139 const UnsafeResource& resource = *iter; | 138 const UnsafeResource& resource = *iter; |
140 SBThreatType threat_type = resource.threat_type; | 139 SBThreatType threat_type = resource.threat_type; |
(...skipping 495 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
636 load_time_data->SetString( | 635 load_time_data->SetString( |
637 "explanationParagraph", | 636 "explanationParagraph", |
638 l10n_util::GetStringFUTF16(IDS_PHISHING_V3_EXPLANATION_PARAGRAPH, | 637 l10n_util::GetStringFUTF16(IDS_PHISHING_V3_EXPLANATION_PARAGRAPH, |
639 GetFormattedHostName())); | 638 GetFormattedHostName())); |
640 load_time_data->SetString( | 639 load_time_data->SetString( |
641 "finalParagraph", | 640 "finalParagraph", |
642 l10n_util::GetStringUTF16(IDS_PHISHING_V3_PROCEED_PARAGRAPH)); | 641 l10n_util::GetStringUTF16(IDS_PHISHING_V3_PROCEED_PARAGRAPH)); |
643 | 642 |
644 PopulateExtendedReportingOption(load_time_data); | 643 PopulateExtendedReportingOption(load_time_data); |
645 } | 644 } |
OLD | NEW |