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

Side by Side Diff: chrome/browser/ui/website_settings/website_settings.cc

Issue 2397273002: Show a custom page info bubble for chrome-devtools:// URLs (Closed)
Patch Set: Rebase Created 4 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
OLDNEW
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 #include "chrome/browser/ui/website_settings/website_settings.h" 5 #include "chrome/browser/ui/website_settings/website_settings.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after
389 void WebsiteSettings::OnRevokeSSLErrorBypassButtonPressed() { 389 void WebsiteSettings::OnRevokeSSLErrorBypassButtonPressed() {
390 DCHECK(chrome_ssl_host_state_delegate_); 390 DCHECK(chrome_ssl_host_state_delegate_);
391 chrome_ssl_host_state_delegate_->RevokeUserAllowExceptionsHard( 391 chrome_ssl_host_state_delegate_->RevokeUserAllowExceptionsHard(
392 site_url().host()); 392 site_url().host());
393 did_revoke_user_ssl_decisions_ = true; 393 did_revoke_user_ssl_decisions_ = true;
394 } 394 }
395 395
396 void WebsiteSettings::Init( 396 void WebsiteSettings::Init(
397 const GURL& url, 397 const GURL& url,
398 const SecurityStateModel::SecurityInfo& security_info) { 398 const SecurityStateModel::SecurityInfo& security_info) {
399 #if !defined(OS_ANDROID) && !defined(OS_IOS)
400 // On desktop, internal URLs aren't handled by this class. Instead, a
401 // custom and simpler popup is shown.
402 DCHECK(!url.SchemeIs(content::kChromeUIScheme) &&
403 !url.SchemeIs(content::kChromeDevToolsScheme) &&
404 !url.SchemeIs(content::kViewSourceScheme) &&
405 !url.SchemeIs(content_settings::kExtensionScheme));
406 #endif
407
399 bool isChromeUINativeScheme = false; 408 bool isChromeUINativeScheme = false;
400 #if BUILDFLAG(ANDROID_JAVA_UI) 409 #if BUILDFLAG(ANDROID_JAVA_UI)
401 isChromeUINativeScheme = url.SchemeIs(chrome::kChromeUINativeScheme); 410 isChromeUINativeScheme = url.SchemeIs(chrome::kChromeUINativeScheme);
402 #endif 411 #endif
403 412
404 if (url.SchemeIs(url::kAboutScheme)) { 413 if (url.SchemeIs(url::kAboutScheme)) {
405 // All about: URLs except about:blank are redirected. 414 // All about: URLs except about:blank are redirected.
406 DCHECK_EQ(url::kAboutBlankURL, url.spec()); 415 DCHECK_EQ(url::kAboutBlankURL, url.spec());
407 site_identity_status_ = SITE_IDENTITY_STATUS_NO_CERT; 416 site_identity_status_ = SITE_IDENTITY_STATUS_NO_CERT;
408 site_identity_details_ = 417 site_identity_details_ =
(...skipping 389 matching lines...) Expand 10 before | Expand all | Expand 10 after
798 info.connection_status = site_connection_status_; 807 info.connection_status = site_connection_status_;
799 info.connection_status_description = 808 info.connection_status_description =
800 UTF16ToUTF8(site_connection_details_); 809 UTF16ToUTF8(site_connection_details_);
801 info.identity_status = site_identity_status_; 810 info.identity_status = site_identity_status_;
802 info.identity_status_description = 811 info.identity_status_description =
803 UTF16ToUTF8(site_identity_details_); 812 UTF16ToUTF8(site_identity_details_);
804 info.certificate = certificate_; 813 info.certificate = certificate_;
805 info.show_ssl_decision_revoke_button = show_ssl_decision_revoke_button_; 814 info.show_ssl_decision_revoke_button = show_ssl_decision_revoke_button_;
806 ui_->SetIdentityInfo(info); 815 ui_->SetIdentityInfo(info);
807 } 816 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698