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

Unified Diff: chrome/browser/ui/content_settings/content_setting_bubble_model.cc

Issue 2220573004: Caption for the Subresource filter bubble prompt. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix mac Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/content_settings/content_setting_bubble_model.cc
diff --git a/chrome/browser/ui/content_settings/content_setting_bubble_model.cc b/chrome/browser/ui/content_settings/content_setting_bubble_model.cc
index d141885ee2c4aa3fac1494050a393fe45f9ad5da..d4d6bddb66d965b18d8c47f8e0f59b58197ef334 100644
--- a/chrome/browser/ui/content_settings/content_setting_bubble_model.cc
+++ b/chrome/browser/ui/content_settings/content_setting_bubble_model.cc
@@ -159,7 +159,7 @@ void ContentSettingSimpleBubbleModel::SetTitle() {
int title_id =
GetIdForContentType(title_ids, num_title_ids, content_type());
if (title_id)
- set_title(l10n_util::GetStringUTF8(title_id));
+ set_title(l10n_util::GetStringUTF16(title_id));
}
void ContentSettingSimpleBubbleModel::SetManageLink() {
@@ -654,7 +654,7 @@ void ContentSettingMediaStreamBubbleModel::SetTitle() {
} else if (CameraAccessed()) {
title_id = IDS_CAMERA_ACCESSED;
}
- set_title(l10n_util::GetStringUTF8(title_id));
+ set_title(l10n_util::GetStringUTF16(title_id));
}
void ContentSettingMediaStreamBubbleModel::SetRadioGroup() {
@@ -1047,12 +1047,12 @@ ContentSettingRPHBubbleModel::ContentSettingRPHBubbleModel(
// Note that we ignore the |title| parameter.
if (previous_handler_.IsEmpty()) {
- set_title(l10n_util::GetStringFUTF8(
+ set_title(l10n_util::GetStringFUTF16(
IDS_REGISTER_PROTOCOL_HANDLER_CONFIRM,
base::UTF8ToUTF16(pending_handler_.url().host()),
protocol));
} else {
- set_title(l10n_util::GetStringFUTF8(
+ set_title(l10n_util::GetStringFUTF16(
IDS_REGISTER_PROTOCOL_HANDLER_CONFIRM_REPLACE,
base::UTF8ToUTF16(pending_handler_.url().host()),
protocol,
@@ -1171,6 +1171,7 @@ ContentSettingSubresourceFilterBubbleModel::
Profile* profile)
: ContentSettingBubbleModel(delegate, web_contents, profile) {
SetTitle();
+ SetMessage();
SetManageLink();
}
@@ -1178,10 +1179,8 @@ ContentSettingSubresourceFilterBubbleModel::
~ContentSettingSubresourceFilterBubbleModel() {}
void ContentSettingSubresourceFilterBubbleModel::SetTitle() {
- // TODO(melandory): For this bubble we need to introduce ability to have a
- // caption (something which appears above title and has bigger font).
- set_title(l10n_util::GetStringUTF8(
- IDS_FILTERED_DECEPTIVE_CONTENT_PROMPT_EXPLANATION));
+ set_title(
+ l10n_util::GetStringUTF16(IDS_FILTERED_DECEPTIVE_CONTENT_PROMPT_TITLE));
}
void ContentSettingSubresourceFilterBubbleModel::SetManageLink() {
@@ -1190,6 +1189,11 @@ void ContentSettingSubresourceFilterBubbleModel::SetManageLink() {
l10n_util::GetStringUTF8(IDS_FILTERED_DECEPTIVE_CONTENT_PROMPT_RELOAD));
}
+void ContentSettingSubresourceFilterBubbleModel::SetMessage() {
+ set_message(l10n_util::GetStringUTF16(
+ IDS_FILTERED_DECEPTIVE_CONTENT_PROMPT_EXPLANATION));
+}
+
void ContentSettingSubresourceFilterBubbleModel::OnManageLinkClicked() {
subresource_filter::ContentSubresourceFilterDriverFactory* driver_factory =
subresource_filter::ContentSubresourceFilterDriverFactory::

Powered by Google App Engine
This is Rietveld 408576698