Index: chrome/browser/ui/page_info/page_info_ui.cc |
diff --git a/chrome/browser/ui/page_info/website_settings_ui.cc b/chrome/browser/ui/page_info/page_info_ui.cc |
similarity index 62% |
rename from chrome/browser/ui/page_info/website_settings_ui.cc |
rename to chrome/browser/ui/page_info/page_info_ui.cc |
index f65f3fb6c0c04ceea03c1e8c4919a0ef9d2c2705..ed5c88896d3361ec4fe6123bf63b026176b9355b 100644 |
--- a/chrome/browser/ui/page_info/website_settings_ui.cc |
+++ b/chrome/browser/ui/page_info/page_info_ui.cc |
@@ -2,7 +2,7 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-#include "chrome/browser/ui/page_info/website_settings_ui.h" |
+#include "chrome/browser/ui/page_info/page_info_ui.h" |
#include "base/macros.h" |
#include "chrome/browser/content_settings/host_content_settings_map_factory.h" |
@@ -26,9 +26,9 @@ const int kInvalidResourceID = -1; |
// button if the permission setting is managed by policy. |
const int kPermissionButtonTextIDPolicyManaged[] = { |
kInvalidResourceID, |
- IDS_WEBSITE_SETTINGS_BUTTON_TEXT_ALLOWED_BY_POLICY, |
- IDS_WEBSITE_SETTINGS_BUTTON_TEXT_BLOCKED_BY_POLICY, |
- IDS_WEBSITE_SETTINGS_BUTTON_TEXT_ASK_BY_POLICY, |
+ IDS_PAGE_INFO_BUTTON_TEXT_ALLOWED_BY_POLICY, |
+ IDS_PAGE_INFO_BUTTON_TEXT_BLOCKED_BY_POLICY, |
+ IDS_PAGE_INFO_BUTTON_TEXT_ASK_BY_POLICY, |
kInvalidResourceID, |
kInvalidResourceID}; |
static_assert(arraysize(kPermissionButtonTextIDPolicyManaged) == |
@@ -39,8 +39,8 @@ static_assert(arraysize(kPermissionButtonTextIDPolicyManaged) == |
// button if the permission setting is managed by an extension. |
const int kPermissionButtonTextIDExtensionManaged[] = { |
kInvalidResourceID, |
- IDS_WEBSITE_SETTINGS_BUTTON_TEXT_ALLOWED_BY_EXTENSION, |
- IDS_WEBSITE_SETTINGS_BUTTON_TEXT_BLOCKED_BY_EXTENSION, |
+ IDS_PAGE_INFO_BUTTON_TEXT_ALLOWED_BY_EXTENSION, |
+ IDS_PAGE_INFO_BUTTON_TEXT_BLOCKED_BY_EXTENSION, |
kInvalidResourceID, |
kInvalidResourceID, |
kInvalidResourceID}; |
@@ -53,11 +53,11 @@ static_assert(arraysize(kPermissionButtonTextIDExtensionManaged) == |
// button if the permission setting is managed by the user. |
const int kPermissionButtonTextIDUserManaged[] = { |
kInvalidResourceID, |
- IDS_WEBSITE_SETTINGS_BUTTON_TEXT_ALLOWED_BY_USER, |
- IDS_WEBSITE_SETTINGS_BUTTON_TEXT_BLOCKED_BY_USER, |
- IDS_WEBSITE_SETTINGS_BUTTON_TEXT_ASK_BY_USER, |
+ IDS_PAGE_INFO_BUTTON_TEXT_ALLOWED_BY_USER, |
+ IDS_PAGE_INFO_BUTTON_TEXT_BLOCKED_BY_USER, |
+ IDS_PAGE_INFO_BUTTON_TEXT_ASK_BY_USER, |
kInvalidResourceID, |
- IDS_WEBSITE_SETTINGS_BUTTON_TEXT_DETECT_IMPORTANT_CONTENT_BY_USER}; |
+ IDS_PAGE_INFO_BUTTON_TEXT_DETECT_IMPORTANT_CONTENT_BY_USER}; |
static_assert(arraysize(kPermissionButtonTextIDUserManaged) == |
CONTENT_SETTING_NUM_SETTINGS, |
"kPermissionButtonTextIDUserManaged array size is incorrect"); |
@@ -66,11 +66,11 @@ static_assert(arraysize(kPermissionButtonTextIDUserManaged) == |
// button if the permission setting is the global default setting. |
const int kPermissionButtonTextIDDefaultSetting[] = { |
kInvalidResourceID, |
- IDS_WEBSITE_SETTINGS_BUTTON_TEXT_ALLOWED_BY_DEFAULT, |
- IDS_WEBSITE_SETTINGS_BUTTON_TEXT_BLOCKED_BY_DEFAULT, |
- IDS_WEBSITE_SETTINGS_BUTTON_TEXT_ASK_BY_DEFAULT, |
+ IDS_PAGE_INFO_BUTTON_TEXT_ALLOWED_BY_DEFAULT, |
+ IDS_PAGE_INFO_BUTTON_TEXT_BLOCKED_BY_DEFAULT, |
+ IDS_PAGE_INFO_BUTTON_TEXT_ASK_BY_DEFAULT, |
kInvalidResourceID, |
- IDS_WEBSITE_SETTINGS_BUTTON_TEXT_DETECT_IMPORTANT_CONTENT_BY_DEFAULT}; |
+ IDS_PAGE_INFO_BUTTON_TEXT_DETECT_IMPORTANT_CONTENT_BY_DEFAULT}; |
static_assert(arraysize(kPermissionButtonTextIDDefaultSetting) == |
CONTENT_SETTING_NUM_SETTINGS, |
"kPermissionButtonTextIDDefaultSetting array size is incorrect"); |
@@ -85,121 +85,117 @@ struct PermissionsUIInfo { |
const PermissionsUIInfo kPermissionsUIInfo[] = { |
{CONTENT_SETTINGS_TYPE_COOKIES, 0, IDR_BLOCKED_COOKIES, |
IDR_ACCESSED_COOKIES}, |
- {CONTENT_SETTINGS_TYPE_IMAGES, IDS_WEBSITE_SETTINGS_TYPE_IMAGES, |
+ {CONTENT_SETTINGS_TYPE_IMAGES, IDS_PAGE_INFO_TYPE_IMAGES, |
IDR_BLOCKED_IMAGES, IDR_ALLOWED_IMAGES}, |
- {CONTENT_SETTINGS_TYPE_JAVASCRIPT, IDS_WEBSITE_SETTINGS_TYPE_JAVASCRIPT, |
+ {CONTENT_SETTINGS_TYPE_JAVASCRIPT, IDS_PAGE_INFO_TYPE_JAVASCRIPT, |
IDR_BLOCKED_JAVASCRIPT, IDR_ALLOWED_JAVASCRIPT}, |
- {CONTENT_SETTINGS_TYPE_POPUPS, IDS_WEBSITE_SETTINGS_TYPE_POPUPS, |
+ {CONTENT_SETTINGS_TYPE_POPUPS, IDS_PAGE_INFO_TYPE_POPUPS, |
IDR_BLOCKED_POPUPS, IDR_ALLOWED_POPUPS}, |
#if BUILDFLAG(ENABLE_PLUGINS) |
- {CONTENT_SETTINGS_TYPE_PLUGINS, IDS_WEBSITE_SETTINGS_TYPE_FLASH, |
+ {CONTENT_SETTINGS_TYPE_PLUGINS, IDS_PAGE_INFO_TYPE_FLASH, |
IDR_BLOCKED_PLUGINS, IDR_ALLOWED_PLUGINS}, |
#endif |
- {CONTENT_SETTINGS_TYPE_GEOLOCATION, IDS_WEBSITE_SETTINGS_TYPE_LOCATION, |
+ {CONTENT_SETTINGS_TYPE_GEOLOCATION, IDS_PAGE_INFO_TYPE_LOCATION, |
IDR_BLOCKED_LOCATION, IDR_ALLOWED_LOCATION}, |
- {CONTENT_SETTINGS_TYPE_NOTIFICATIONS, |
- IDS_WEBSITE_SETTINGS_TYPE_NOTIFICATIONS, IDR_BLOCKED_NOTIFICATION, |
- IDR_ALLOWED_NOTIFICATION}, |
- {CONTENT_SETTINGS_TYPE_MEDIASTREAM_MIC, IDS_WEBSITE_SETTINGS_TYPE_MIC, |
+ {CONTENT_SETTINGS_TYPE_NOTIFICATIONS, IDS_PAGE_INFO_TYPE_NOTIFICATIONS, |
+ IDR_BLOCKED_NOTIFICATION, IDR_ALLOWED_NOTIFICATION}, |
+ {CONTENT_SETTINGS_TYPE_MEDIASTREAM_MIC, IDS_PAGE_INFO_TYPE_MIC, |
IDR_BLOCKED_MIC, IDR_ALLOWED_MIC}, |
- {CONTENT_SETTINGS_TYPE_MEDIASTREAM_CAMERA, IDS_WEBSITE_SETTINGS_TYPE_CAMERA, |
+ {CONTENT_SETTINGS_TYPE_MEDIASTREAM_CAMERA, IDS_PAGE_INFO_TYPE_CAMERA, |
IDR_BLOCKED_CAMERA, IDR_ALLOWED_CAMERA}, |
{CONTENT_SETTINGS_TYPE_AUTOMATIC_DOWNLOADS, |
IDS_AUTOMATIC_DOWNLOADS_TAB_LABEL, IDR_BLOCKED_DOWNLOADS, |
IDR_ALLOWED_DOWNLOADS}, |
- {CONTENT_SETTINGS_TYPE_MIDI_SYSEX, IDS_WEBSITE_SETTINGS_TYPE_MIDI_SYSEX, |
+ {CONTENT_SETTINGS_TYPE_MIDI_SYSEX, IDS_PAGE_INFO_TYPE_MIDI_SYSEX, |
IDR_BLOCKED_MIDI_SYSEX, IDR_ALLOWED_MIDI_SYSEX}, |
- {CONTENT_SETTINGS_TYPE_BACKGROUND_SYNC, |
- IDS_WEBSITE_SETTINGS_TYPE_BACKGROUND_SYNC, IDR_BLOCKED_BACKGROUND_SYNC, |
- IDR_ALLOWED_BACKGROUND_SYNC}, |
+ {CONTENT_SETTINGS_TYPE_BACKGROUND_SYNC, IDS_PAGE_INFO_TYPE_BACKGROUND_SYNC, |
+ IDR_BLOCKED_BACKGROUND_SYNC, IDR_ALLOWED_BACKGROUND_SYNC}, |
// Autoplay is Android-only at the moment, and the Origin Info bubble in |
// Android ignores these block/allow icon pairs, so we can specify 0 there. |
- {CONTENT_SETTINGS_TYPE_AUTOPLAY, IDS_WEBSITE_SETTINGS_TYPE_AUTOPLAY, 0, 0}, |
+ {CONTENT_SETTINGS_TYPE_AUTOPLAY, IDS_PAGE_INFO_TYPE_AUTOPLAY, 0, 0}, |
}; |
-std::unique_ptr<WebsiteSettingsUI::SecurityDescription> |
-CreateSecurityDescription(int summary_id, int details_id) { |
- std::unique_ptr<WebsiteSettingsUI::SecurityDescription> security_description( |
- new WebsiteSettingsUI::SecurityDescription()); |
+std::unique_ptr<PageInfoUI::SecurityDescription> CreateSecurityDescription( |
+ int summary_id, |
+ int details_id) { |
+ std::unique_ptr<PageInfoUI::SecurityDescription> security_description( |
+ new PageInfoUI::SecurityDescription()); |
security_description->summary = l10n_util::GetStringUTF16(summary_id); |
security_description->details = l10n_util::GetStringUTF16(details_id); |
return security_description; |
} |
} // namespace |
-WebsiteSettingsUI::CookieInfo::CookieInfo() : allowed(-1), blocked(-1) {} |
+PageInfoUI::CookieInfo::CookieInfo() : allowed(-1), blocked(-1) {} |
-WebsiteSettingsUI::PermissionInfo::PermissionInfo() |
+PageInfoUI::PermissionInfo::PermissionInfo() |
: type(CONTENT_SETTINGS_TYPE_DEFAULT), |
setting(CONTENT_SETTING_DEFAULT), |
default_setting(CONTENT_SETTING_DEFAULT), |
source(content_settings::SETTING_SOURCE_NONE), |
is_incognito(false) {} |
-WebsiteSettingsUI::ChosenObjectInfo::ChosenObjectInfo( |
- const WebsiteSettings::ChooserUIInfo& ui_info, |
+PageInfoUI::ChosenObjectInfo::ChosenObjectInfo( |
+ const PageInfo::ChooserUIInfo& ui_info, |
std::unique_ptr<base::DictionaryValue> object) |
: ui_info(ui_info), object(std::move(object)) {} |
-WebsiteSettingsUI::ChosenObjectInfo::~ChosenObjectInfo() {} |
+PageInfoUI::ChosenObjectInfo::~ChosenObjectInfo() {} |
-WebsiteSettingsUI::IdentityInfo::IdentityInfo() |
- : identity_status(WebsiteSettings::SITE_IDENTITY_STATUS_UNKNOWN), |
- connection_status(WebsiteSettings::SITE_CONNECTION_STATUS_UNKNOWN), |
+PageInfoUI::IdentityInfo::IdentityInfo() |
+ : identity_status(PageInfo::SITE_IDENTITY_STATUS_UNKNOWN), |
+ connection_status(PageInfo::SITE_CONNECTION_STATUS_UNKNOWN), |
show_ssl_decision_revoke_button(false) {} |
-WebsiteSettingsUI::IdentityInfo::~IdentityInfo() {} |
+PageInfoUI::IdentityInfo::~IdentityInfo() {} |
-std::unique_ptr<WebsiteSettingsUI::SecurityDescription> |
-WebsiteSettingsUI::IdentityInfo::GetSecurityDescription() const { |
- std::unique_ptr<WebsiteSettingsUI::SecurityDescription> security_description( |
- new WebsiteSettingsUI::SecurityDescription()); |
+std::unique_ptr<PageInfoUI::SecurityDescription> |
+PageInfoUI::IdentityInfo::GetSecurityDescription() const { |
+ std::unique_ptr<PageInfoUI::SecurityDescription> security_description( |
+ new PageInfoUI::SecurityDescription()); |
switch (identity_status) { |
- case WebsiteSettings::SITE_IDENTITY_STATUS_INTERNAL_PAGE: |
+ case PageInfo::SITE_IDENTITY_STATUS_INTERNAL_PAGE: |
// Internal pages have their own UI implementations which should never |
// call this function. |
NOTREACHED(); |
- case WebsiteSettings::SITE_IDENTITY_STATUS_CERT: |
- case WebsiteSettings::SITE_IDENTITY_STATUS_EV_CERT: |
- case WebsiteSettings::SITE_IDENTITY_STATUS_CERT_REVOCATION_UNKNOWN: |
- case WebsiteSettings::SITE_IDENTITY_STATUS_ADMIN_PROVIDED_CERT: |
+ case PageInfo::SITE_IDENTITY_STATUS_CERT: |
+ case PageInfo::SITE_IDENTITY_STATUS_EV_CERT: |
+ case PageInfo::SITE_IDENTITY_STATUS_CERT_REVOCATION_UNKNOWN: |
+ case PageInfo::SITE_IDENTITY_STATUS_ADMIN_PROVIDED_CERT: |
switch (connection_status) { |
- case WebsiteSettings:: |
- SITE_CONNECTION_STATUS_INSECURE_ACTIVE_SUBRESOURCE: |
+ case PageInfo::SITE_CONNECTION_STATUS_INSECURE_ACTIVE_SUBRESOURCE: |
return CreateSecurityDescription(IDS_PAGEINFO_NOT_SECURE_SUMMARY, |
IDS_PAGEINFO_NOT_SECURE_DETAILS); |
- case WebsiteSettings:: |
- SITE_CONNECTION_STATUS_INSECURE_PASSIVE_SUBRESOURCE: |
+ case PageInfo::SITE_CONNECTION_STATUS_INSECURE_PASSIVE_SUBRESOURCE: |
return CreateSecurityDescription(IDS_PAGEINFO_MIXED_CONTENT_SUMMARY, |
IDS_PAGEINFO_MIXED_CONTENT_DETAILS); |
default: |
return CreateSecurityDescription(IDS_PAGEINFO_SECURE_SUMMARY, |
IDS_PAGEINFO_SECURE_DETAILS); |
} |
- case WebsiteSettings::SITE_IDENTITY_STATUS_MALWARE: |
+ case PageInfo::SITE_IDENTITY_STATUS_MALWARE: |
return CreateSecurityDescription(IDS_PAGEINFO_MALWARE_SUMMARY, |
IDS_PAGEINFO_MALWARE_DETAILS); |
- case WebsiteSettings::SITE_IDENTITY_STATUS_SOCIAL_ENGINEERING: |
+ case PageInfo::SITE_IDENTITY_STATUS_SOCIAL_ENGINEERING: |
return CreateSecurityDescription(IDS_PAGEINFO_SOCIAL_ENGINEERING_SUMMARY, |
IDS_PAGEINFO_SOCIAL_ENGINEERING_DETAILS); |
- case WebsiteSettings::SITE_IDENTITY_STATUS_UNWANTED_SOFTWARE: |
+ case PageInfo::SITE_IDENTITY_STATUS_UNWANTED_SOFTWARE: |
return CreateSecurityDescription(IDS_PAGEINFO_UNWANTED_SOFTWARE_SUMMARY, |
IDS_PAGEINFO_UNWANTED_SOFTWARE_DETAILS); |
- case WebsiteSettings::SITE_IDENTITY_STATUS_DEPRECATED_SIGNATURE_ALGORITHM: |
- case WebsiteSettings::SITE_IDENTITY_STATUS_UNKNOWN: |
- case WebsiteSettings::SITE_IDENTITY_STATUS_NO_CERT: |
+ case PageInfo::SITE_IDENTITY_STATUS_DEPRECATED_SIGNATURE_ALGORITHM: |
+ case PageInfo::SITE_IDENTITY_STATUS_UNKNOWN: |
+ case PageInfo::SITE_IDENTITY_STATUS_NO_CERT: |
default: |
return CreateSecurityDescription(IDS_PAGEINFO_NOT_SECURE_SUMMARY, |
IDS_PAGEINFO_NOT_SECURE_DETAILS); |
} |
} |
-WebsiteSettingsUI::~WebsiteSettingsUI() {} |
+PageInfoUI::~PageInfoUI() {} |
// static |
-base::string16 WebsiteSettingsUI::PermissionTypeToUIString( |
- ContentSettingsType type) { |
+base::string16 PageInfoUI::PermissionTypeToUIString(ContentSettingsType type) { |
for (const PermissionsUIInfo& info : kPermissionsUIInfo) { |
if (info.type == type) |
return l10n_util::GetStringUTF16(info.string_id); |
@@ -209,15 +205,14 @@ base::string16 WebsiteSettingsUI::PermissionTypeToUIString( |
} |
// static |
-base::string16 WebsiteSettingsUI::PermissionValueToUIString( |
- ContentSetting value) { |
+base::string16 PageInfoUI::PermissionValueToUIString(ContentSetting value) { |
switch (value) { |
case CONTENT_SETTING_ALLOW: |
- return l10n_util::GetStringUTF16(IDS_WEBSITE_SETTINGS_PERMISSION_ALLOW); |
+ return l10n_util::GetStringUTF16(IDS_PAGE_INFO_PERMISSION_ALLOW); |
case CONTENT_SETTING_BLOCK: |
- return l10n_util::GetStringUTF16(IDS_WEBSITE_SETTINGS_PERMISSION_BLOCK); |
+ return l10n_util::GetStringUTF16(IDS_PAGE_INFO_PERMISSION_BLOCK); |
case CONTENT_SETTING_ASK: |
- return l10n_util::GetStringUTF16(IDS_WEBSITE_SETTINGS_PERMISSION_ASK); |
+ return l10n_util::GetStringUTF16(IDS_PAGE_INFO_PERMISSION_ASK); |
default: |
NOTREACHED(); |
return base::string16(); |
@@ -225,7 +220,7 @@ base::string16 WebsiteSettingsUI::PermissionValueToUIString( |
} |
// static |
-base::string16 WebsiteSettingsUI::PermissionActionToUIString( |
+base::string16 PageInfoUI::PermissionActionToUIString( |
Profile* profile, |
ContentSettingsType type, |
ContentSetting setting, |
@@ -276,8 +271,8 @@ base::string16 WebsiteSettingsUI::PermissionActionToUIString( |
} |
// static |
-int WebsiteSettingsUI::GetPermissionIconID(ContentSettingsType type, |
- ContentSetting setting) { |
+int PageInfoUI::GetPermissionIconID(ContentSettingsType type, |
+ ContentSetting setting) { |
bool use_blocked = (setting == CONTENT_SETTING_BLOCK); |
for (const PermissionsUIInfo& info : kPermissionsUIInfo) { |
if (info.type == type) |
@@ -288,8 +283,7 @@ int WebsiteSettingsUI::GetPermissionIconID(ContentSettingsType type, |
} |
// static |
-const gfx::Image& WebsiteSettingsUI::GetPermissionIcon( |
- const PermissionInfo& info) { |
+const gfx::Image& PageInfoUI::GetPermissionIcon(const PermissionInfo& info) { |
ContentSetting setting = info.setting; |
if (setting == CONTENT_SETTING_DEFAULT) |
setting = info.default_setting; |
@@ -298,7 +292,7 @@ const gfx::Image& WebsiteSettingsUI::GetPermissionIcon( |
} |
// static |
-base::string16 WebsiteSettingsUI::ChosenObjectToUIString( |
+base::string16 PageInfoUI::ChosenObjectToUIString( |
const ChosenObjectInfo& object) { |
base::string16 name; |
object.object->GetString(object.ui_info.ui_name_key, &name); |
@@ -306,7 +300,7 @@ base::string16 WebsiteSettingsUI::ChosenObjectToUIString( |
} |
// static |
-const gfx::Image& WebsiteSettingsUI::GetChosenObjectIcon( |
+const gfx::Image& PageInfoUI::GetChosenObjectIcon( |
const ChosenObjectInfo& object, |
bool deleted) { |
ResourceBundle& rb = ResourceBundle::GetSharedInstance(); |
@@ -315,30 +309,29 @@ const gfx::Image& WebsiteSettingsUI::GetChosenObjectIcon( |
} |
// static |
-int WebsiteSettingsUI::GetIdentityIconID( |
- WebsiteSettings::SiteIdentityStatus status) { |
+int PageInfoUI::GetIdentityIconID(PageInfo::SiteIdentityStatus status) { |
int resource_id = IDR_PAGEINFO_INFO; |
switch (status) { |
- case WebsiteSettings::SITE_IDENTITY_STATUS_UNKNOWN: |
- case WebsiteSettings::SITE_IDENTITY_STATUS_INTERNAL_PAGE: |
+ case PageInfo::SITE_IDENTITY_STATUS_UNKNOWN: |
+ case PageInfo::SITE_IDENTITY_STATUS_INTERNAL_PAGE: |
break; |
- case WebsiteSettings::SITE_IDENTITY_STATUS_CERT: |
- case WebsiteSettings::SITE_IDENTITY_STATUS_EV_CERT: |
+ case PageInfo::SITE_IDENTITY_STATUS_CERT: |
+ case PageInfo::SITE_IDENTITY_STATUS_EV_CERT: |
resource_id = IDR_PAGEINFO_GOOD; |
break; |
- case WebsiteSettings::SITE_IDENTITY_STATUS_CERT_REVOCATION_UNKNOWN: |
+ case PageInfo::SITE_IDENTITY_STATUS_CERT_REVOCATION_UNKNOWN: |
resource_id = IDR_PAGEINFO_WARNING_MINOR; |
break; |
- case WebsiteSettings::SITE_IDENTITY_STATUS_NO_CERT: |
+ case PageInfo::SITE_IDENTITY_STATUS_NO_CERT: |
resource_id = IDR_PAGEINFO_WARNING_MAJOR; |
break; |
- case WebsiteSettings::SITE_IDENTITY_STATUS_ERROR: |
+ case PageInfo::SITE_IDENTITY_STATUS_ERROR: |
resource_id = IDR_PAGEINFO_BAD; |
break; |
- case WebsiteSettings::SITE_IDENTITY_STATUS_ADMIN_PROVIDED_CERT: |
+ case PageInfo::SITE_IDENTITY_STATUS_ADMIN_PROVIDED_CERT: |
resource_id = IDR_PAGEINFO_ENTERPRISE_MANAGED; |
break; |
- case WebsiteSettings::SITE_IDENTITY_STATUS_DEPRECATED_SIGNATURE_ALGORITHM: |
+ case PageInfo::SITE_IDENTITY_STATUS_DEPRECATED_SIGNATURE_ALGORITHM: |
resource_id = IDR_PAGEINFO_WARNING_MINOR; |
break; |
default: |
@@ -349,31 +342,30 @@ int WebsiteSettingsUI::GetIdentityIconID( |
} |
// static |
-const gfx::Image& WebsiteSettingsUI::GetIdentityIcon( |
- WebsiteSettings::SiteIdentityStatus status) { |
+const gfx::Image& PageInfoUI::GetIdentityIcon( |
+ PageInfo::SiteIdentityStatus status) { |
ResourceBundle& rb = ResourceBundle::GetSharedInstance(); |
return rb.GetNativeImageNamed(GetIdentityIconID(status)); |
} |
// static |
-int WebsiteSettingsUI::GetConnectionIconID( |
- WebsiteSettings::SiteConnectionStatus status) { |
+int PageInfoUI::GetConnectionIconID(PageInfo::SiteConnectionStatus status) { |
int resource_id = IDR_PAGEINFO_INFO; |
switch (status) { |
- case WebsiteSettings::SITE_CONNECTION_STATUS_UNKNOWN: |
- case WebsiteSettings::SITE_CONNECTION_STATUS_INTERNAL_PAGE: |
+ case PageInfo::SITE_CONNECTION_STATUS_UNKNOWN: |
+ case PageInfo::SITE_CONNECTION_STATUS_INTERNAL_PAGE: |
break; |
- case WebsiteSettings::SITE_CONNECTION_STATUS_ENCRYPTED: |
+ case PageInfo::SITE_CONNECTION_STATUS_ENCRYPTED: |
resource_id = IDR_PAGEINFO_GOOD; |
break; |
- case WebsiteSettings::SITE_CONNECTION_STATUS_INSECURE_PASSIVE_SUBRESOURCE: |
+ case PageInfo::SITE_CONNECTION_STATUS_INSECURE_PASSIVE_SUBRESOURCE: |
resource_id = IDR_PAGEINFO_WARNING_MINOR; |
break; |
- case WebsiteSettings::SITE_CONNECTION_STATUS_UNENCRYPTED: |
+ case PageInfo::SITE_CONNECTION_STATUS_UNENCRYPTED: |
resource_id = IDR_PAGEINFO_WARNING_MAJOR; |
break; |
- case WebsiteSettings::SITE_CONNECTION_STATUS_INSECURE_ACTIVE_SUBRESOURCE: |
- case WebsiteSettings::SITE_CONNECTION_STATUS_ENCRYPTED_ERROR: |
+ case PageInfo::SITE_CONNECTION_STATUS_INSECURE_ACTIVE_SUBRESOURCE: |
+ case PageInfo::SITE_CONNECTION_STATUS_ENCRYPTED_ERROR: |
resource_id = IDR_PAGEINFO_BAD; |
break; |
} |
@@ -381,8 +373,8 @@ int WebsiteSettingsUI::GetConnectionIconID( |
} |
// static |
-const gfx::Image& WebsiteSettingsUI::GetConnectionIcon( |
- WebsiteSettings::SiteConnectionStatus status) { |
+const gfx::Image& PageInfoUI::GetConnectionIcon( |
+ PageInfo::SiteConnectionStatus status) { |
ResourceBundle& rb = ResourceBundle::GetSharedInstance(); |
return rb.GetNativeImageNamed(GetConnectionIconID(status)); |
} |