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

Unified Diff: chrome/browser/infobars/insecure_content_infobar_delegate.cc

Issue 56123010: [InfoBar] remove unnecesary checks from some delegates. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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
« no previous file with comments | « chrome/browser/geolocation/geolocation_infobar_delegate.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/infobars/insecure_content_infobar_delegate.cc
diff --git a/chrome/browser/infobars/insecure_content_infobar_delegate.cc b/chrome/browser/infobars/insecure_content_infobar_delegate.cc
index 9e568371d9fb27206301d2d0c66a2810aca345ea..66278c95759997792c69669edd6cdbf41f1ac4a1 100644
--- a/chrome/browser/infobars/insecure_content_infobar_delegate.cc
+++ b/chrome/browser/infobars/insecure_content_infobar_delegate.cc
@@ -82,7 +82,6 @@ bool InsecureContentInfoBarDelegate::Accept() {
return true;
}
-
// Cancel button is labelled "load anyways". It triggers Cancel(), but really
// means become insecure, so do the work of reloading the page.
bool InsecureContentInfoBarDelegate::Cancel() {
@@ -90,14 +89,12 @@ bool InsecureContentInfoBarDelegate::Cancel() {
(type_ == DISPLAY) ? DISPLAY_USER_OVERRIDE : RUN_USER_OVERRIDE,
NUM_EVENTS);
- if (web_contents()) {
- int32 routing_id = web_contents()->GetRoutingID();
- web_contents()->Send((type_ == DISPLAY) ?
- static_cast<IPC::Message*>(
- new ChromeViewMsg_SetAllowDisplayingInsecureContent(routing_id,
- true)) :
- new ChromeViewMsg_SetAllowRunningInsecureContent(routing_id, true));
- }
+ int32 routing_id = web_contents()->GetRoutingID();
+ web_contents()->Send((type_ == DISPLAY) ?
+ static_cast<IPC::Message*>(
+ new ChromeViewMsg_SetAllowDisplayingInsecureContent(routing_id,
+ true)) :
+ new ChromeViewMsg_SetAllowRunningInsecureContent(routing_id, true));
return true;
}
« no previous file with comments | « chrome/browser/geolocation/geolocation_infobar_delegate.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698