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

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

Issue 13483010: Add UI notifications for admin-provided SSL certificates. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 7 years, 8 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/views/website_settings/website_settings_popup_view.h " 5 #include "chrome/browser/ui/views/website_settings/website_settings_popup_view.h "
6 6
7 #include "base/strings/string_number_conversions.h" 7 #include "base/strings/string_number_conversions.h"
8 #include "base/utf_string_conversions.h" 8 #include "base/utf_string_conversions.h"
9 #include "chrome/browser/certificate_viewer.h" 9 #include "chrome/browser/certificate_viewer.h"
10 #include "chrome/browser/infobars/infobar_service.h" 10 #include "chrome/browser/infobars/infobar_service.h"
(...skipping 497 matching lines...) Expand 10 before | Expand all | Expand 10 after
508 const IdentityInfo& identity_info) { 508 const IdentityInfo& identity_info) {
509 string16 identity_status_text; 509 string16 identity_status_text;
510 SkColor text_color = SK_ColorBLACK; 510 SkColor text_color = SK_ColorBLACK;
511 switch (identity_info.identity_status) { 511 switch (identity_info.identity_status) {
512 case WebsiteSettings::SITE_IDENTITY_STATUS_CERT: 512 case WebsiteSettings::SITE_IDENTITY_STATUS_CERT:
513 case WebsiteSettings::SITE_IDENTITY_STATUS_EV_CERT: 513 case WebsiteSettings::SITE_IDENTITY_STATUS_EV_CERT:
514 identity_status_text = 514 identity_status_text =
515 l10n_util::GetStringUTF16(IDS_WEBSITE_SETTINGS_IDENTITY_VERIFIED); 515 l10n_util::GetStringUTF16(IDS_WEBSITE_SETTINGS_IDENTITY_VERIFIED);
516 text_color = kIdentityVerifiedTextColor; 516 text_color = kIdentityVerifiedTextColor;
517 break; 517 break;
518 case WebsiteSettings::SITE_IDENTITY_STATUS_ADMIN_PROVIDED_CERT:
519 identity_status_text =
520 l10n_util::GetStringUTF16(IDS_CERT_POLICY_PROVIDED_CERT_HEADER);
521 break;
518 default: 522 default:
519 identity_status_text = 523 identity_status_text =
520 l10n_util::GetStringUTF16(IDS_WEBSITE_SETTINGS_IDENTITY_NOT_VERIFIED); 524 l10n_util::GetStringUTF16(IDS_WEBSITE_SETTINGS_IDENTITY_NOT_VERIFIED);
521 break; 525 break;
522 } 526 }
523 header_->SetIdentityName(UTF8ToUTF16(identity_info.site_identity)); 527 header_->SetIdentityName(UTF8ToUTF16(identity_info.site_identity));
524 header_->SetIdentityStatus(identity_status_text, text_color); 528 header_->SetIdentityStatus(identity_status_text, text_color);
525 529
526 // The headline and the certificate dialog link of the site's identity 530 // The headline and the certificate dialog link of the site's identity
527 // section is only displayed if the site's identity was verified. If the 531 // section is only displayed if the site's identity was verified. If the
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after
742 746
743 if (link) { 747 if (link) {
744 content_layout->StartRow(1, 0); 748 content_layout->StartRow(1, 0);
745 content_layout->AddView(link); 749 content_layout->AddView(link);
746 } 750 }
747 751
748 layout->AddView(content_pane, 1, 1, views::GridLayout::LEADING, 752 layout->AddView(content_pane, 1, 1, views::GridLayout::LEADING,
749 views::GridLayout::LEADING); 753 views::GridLayout::LEADING);
750 layout->AddPaddingRow(0, kConnectionSectionPaddingBottom); 754 layout->AddPaddingRow(0, kConnectionSectionPaddingBottom);
751 } 755 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/location_bar/location_bar_view.cc ('k') | chrome/browser/ui/website_settings/website_settings.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698