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

Side by Side Diff: chrome/browser/ssl_manager.cc

Issue 4088: Move a bunch of stuff out of WebContents. I removed a bunch of render view ho... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 12 years, 2 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 #include "chrome/browser/ssl_manager.h" 5 #include "chrome/browser/ssl_manager.h"
6 6
7 #include "base/message_loop.h" 7 #include "base/message_loop.h"
8 #include "base/string_util.h" 8 #include "base/string_util.h"
9 #include "chrome/app/theme/theme_resources.h" 9 #include "chrome/app/theme/theme_resources.h"
10 #include "chrome/browser/browser_process.h" 10 #include "chrome/browser/browser_process.h"
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
189 // Delegate API method. 189 // Delegate API method.
190 void SSLManager::AddMessageToConsole(const std::wstring& msg, 190 void SSLManager::AddMessageToConsole(const std::wstring& msg,
191 ConsoleMessageLevel level) { 191 ConsoleMessageLevel level) {
192 TabContents* tab_contents = controller_->GetTabContents(TAB_CONTENTS_WEB); 192 TabContents* tab_contents = controller_->GetTabContents(TAB_CONTENTS_WEB);
193 if (!tab_contents) 193 if (!tab_contents)
194 return; 194 return;
195 WebContents* web_contents = tab_contents->AsWebContents(); 195 WebContents* web_contents = tab_contents->AsWebContents();
196 if (!web_contents) 196 if (!web_contents)
197 return; 197 return;
198 198
199 web_contents->AddMessageToConsole(std::wstring(), msg, level); 199 web_contents->render_view_host()->AddMessageToConsole(
200 std::wstring(), msg, level);
200 } 201 }
201 202
202 // Delegate API method. 203 // Delegate API method.
203 void SSLManager::DenyCertForHost(net::X509Certificate* cert, 204 void SSLManager::DenyCertForHost(net::X509Certificate* cert,
204 const std::string& host) { 205 const std::string& host) {
205 // Remember that we don't like this cert for this host. 206 // Remember that we don't like this cert for this host.
206 // TODO(abarth): Do we want to persist this information in the user's profile? 207 // TODO(abarth): Do we want to persist this information in the user's profile?
207 cert_policy_for_host_[host].Deny(cert); 208 cert_policy_for_host_[host].Deny(cert);
208 } 209 }
209 210
(...skipping 534 matching lines...) Expand 10 before | Expand all | Expand 10 after
744 745
745 if (ca_name) { 746 if (ca_name) {
746 // TODO(wtc): should we show the root CA's name instead? 747 // TODO(wtc): should we show the root CA's name instead?
747 *ca_name = l10n_util::GetStringF( 748 *ca_name = l10n_util::GetStringF(
748 IDS_SECURE_CONNECTION_EV_CA, 749 IDS_SECURE_CONNECTION_EV_CA,
749 UTF8ToWide(cert.issuer().organization_names[0])); 750 UTF8ToWide(cert.issuer().organization_names[0]));
750 } 751 }
751 return true; 752 return true;
752 } 753 }
753 754
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698