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

Side by Side Diff: chrome/browser/ui/page_info/page_info_ui.cc

Issue 2945113004: Page info UI icons updated for Ads. (Closed)
Patch Set: Renamed icon names and file names Created 3 years, 6 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
« no previous file with comments | « chrome/app/theme/theme_resources.grd ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/page_info/page_info_ui.h" 5 #include "chrome/browser/ui/page_info/page_info_ui.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 {CONTENT_SETTINGS_TYPE_AUTOMATIC_DOWNLOADS, 122 {CONTENT_SETTINGS_TYPE_AUTOMATIC_DOWNLOADS,
123 IDS_AUTOMATIC_DOWNLOADS_TAB_LABEL, IDR_BLOCKED_DOWNLOADS, 123 IDS_AUTOMATIC_DOWNLOADS_TAB_LABEL, IDR_BLOCKED_DOWNLOADS,
124 IDR_ALLOWED_DOWNLOADS}, 124 IDR_ALLOWED_DOWNLOADS},
125 {CONTENT_SETTINGS_TYPE_MIDI_SYSEX, IDS_PAGE_INFO_TYPE_MIDI_SYSEX, 125 {CONTENT_SETTINGS_TYPE_MIDI_SYSEX, IDS_PAGE_INFO_TYPE_MIDI_SYSEX,
126 IDR_BLOCKED_MIDI_SYSEX, IDR_ALLOWED_MIDI_SYSEX}, 126 IDR_BLOCKED_MIDI_SYSEX, IDR_ALLOWED_MIDI_SYSEX},
127 {CONTENT_SETTINGS_TYPE_BACKGROUND_SYNC, IDS_PAGE_INFO_TYPE_BACKGROUND_SYNC, 127 {CONTENT_SETTINGS_TYPE_BACKGROUND_SYNC, IDS_PAGE_INFO_TYPE_BACKGROUND_SYNC,
128 IDR_BLOCKED_BACKGROUND_SYNC, IDR_ALLOWED_BACKGROUND_SYNC}, 128 IDR_BLOCKED_BACKGROUND_SYNC, IDR_ALLOWED_BACKGROUND_SYNC},
129 // Autoplay is Android-only at the moment, and the Page Info popup on 129 // Autoplay is Android-only at the moment, and the Page Info popup on
130 // Android ignores these block/allow icon pairs, so we can specify 0 there. 130 // Android ignores these block/allow icon pairs, so we can specify 0 there.
131 {CONTENT_SETTINGS_TYPE_AUTOPLAY, IDS_PAGE_INFO_TYPE_AUTOPLAY, 0, 0}, 131 {CONTENT_SETTINGS_TYPE_AUTOPLAY, IDS_PAGE_INFO_TYPE_AUTOPLAY, 0, 0},
132 {CONTENT_SETTINGS_TYPE_ADS, IDS_PAGE_INFO_TYPE_ADS, 132 {CONTENT_SETTINGS_TYPE_ADS, IDS_PAGE_INFO_TYPE_ADS, IDR_BLOCKED_ADS,
133 IDR_ALLOWED_SUBRESOURCE_FILTER, IDR_BLOCKED_SUBRESOURCE_FILTER}, 133 IDR_ALLOWED_ADS},
134 }; 134 };
135 135
136 std::unique_ptr<PageInfoUI::SecurityDescription> CreateSecurityDescription( 136 std::unique_ptr<PageInfoUI::SecurityDescription> CreateSecurityDescription(
137 int summary_id, 137 int summary_id,
138 int details_id) { 138 int details_id) {
139 std::unique_ptr<PageInfoUI::SecurityDescription> security_description( 139 std::unique_ptr<PageInfoUI::SecurityDescription> security_description(
140 new PageInfoUI::SecurityDescription()); 140 new PageInfoUI::SecurityDescription());
141 security_description->summary = l10n_util::GetStringUTF16(summary_id); 141 security_description->summary = l10n_util::GetStringUTF16(summary_id);
142 security_description->details = l10n_util::GetStringUTF16(details_id); 142 security_description->details = l10n_util::GetStringUTF16(details_id);
143 return security_description; 143 return security_description;
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 const gfx::ImageSkia PageInfoUI::GetCertificateIcon() { 444 const gfx::ImageSkia PageInfoUI::GetCertificateIcon() {
445 return gfx::CreateVectorIcon(kCertificateIcon, 16, gfx::kChromeIconGrey); 445 return gfx::CreateVectorIcon(kCertificateIcon, 16, gfx::kChromeIconGrey);
446 } 446 }
447 #endif 447 #endif
448 448
449 // static 449 // static
450 bool PageInfoUI::ShouldShowCertificateLink() { 450 bool PageInfoUI::ShouldShowCertificateLink() {
451 return base::CommandLine::ForCurrentProcess()->HasSwitch( 451 return base::CommandLine::ForCurrentProcess()->HasSwitch(
452 switches::kShowCertLink); 452 switches::kShowCertLink);
453 } 453 }
OLDNEW
« no previous file with comments | « chrome/app/theme/theme_resources.grd ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698