Commit 14199559 authored by Jana Grill's avatar Jana Grill Committed by Chromium LUCI CQ

Adjust powerwash requirements notification for FlexOrgs

Adjust IDS_POWERWASH_REQUEST_MESSAGE_FOR_ARC and
IDS_POWERWASH_REQUEST_MESSAGE_FOR_CROSTINI to support FlexOrgs by
adjusting the domain placeholder names and descriptions to make it
easier for the translators to understand the usage of the texts.

Additionally replace a call to
BrowserPolicyConnectorChromeOS::GetEnterpriseDisplayDomain with a call
to BrowserPolicyConnectorChromeOS::GetEnterpriseDomainManager.

Bug: b:172685729
Test: Manual
Change-Id: I7636b1b9123fa2714cb002d1561e0665628ca8ec
Skip-Translation-Screenshots-Check: True
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2587029Reviewed-by: default avatarBrian Malcolm <bmalcolm@chromium.org>
Reviewed-by: default avatarSergey Poromov <poromov@chromium.org>
Commit-Queue: Jana Grill <janagrill@chromium.org>
Cr-Commit-Position: refs/heads/master@{#836641}
parent 2353bba4
......@@ -5794,11 +5794,11 @@ You can manage this account’s settings by installing the Family Link app on yo
<message name="IDS_POWERWASH_REQUEST_TITLE" desc="Title of a notification asking user to powerwash the device">
Update required
</message>
<message name="IDS_POWERWASH_REQUEST_MESSAGE_FOR_ARC" desc="Message of the notification for user trying to start ARC application">
To start Google Play, <ph name="ORGANIZATION_NAME">$1</ph> requires you to back up your data and reset this Chromebook to factory settings.
<message name="IDS_POWERWASH_REQUEST_MESSAGE_FOR_ARC" desc="Message of the notification for user trying to start ARC application. MANAGER can be a domain or an email address.">
To start Google Play, <ph name="MANAGER">$1</ph> requires you to back up your data and reset this Chromebook to factory settings.
</message>
<message name="IDS_POWERWASH_REQUEST_MESSAGE_FOR_CROSTINI" desc="Message of the notification for user trying to start Crostini application">
To start Linux, <ph name="ORGANIZATION_NAME">$1</ph> requires you to back up your data and reset this Chromebook to factory settings.
<message name="IDS_POWERWASH_REQUEST_MESSAGE_FOR_CROSTINI" desc="Message of the notification for user trying to start Crostini application. MANAGER can be a domain or an email address.">
To start Linux, <ph name="MANAGER">$1</ph> requires you to back up your data and reset this Chromebook to factory settings.
</message>
<message name="IDS_POWERWASH_REQUEST_MESSAGE_BUTTON" desc="Name of the button appearing in the notification">
Learn more
......
......@@ -56,10 +56,10 @@ constexpr mc::SystemNotificationWarningLevel kNotificationLevel =
const char kNotificationLearnMoreLink[] =
"https://support.google.com/chromebook?p=factory_reset";
base::string16 GetEnterpriseDisplayDomain() {
base::string16 GetEnterpriseManager() {
policy::BrowserPolicyConnectorChromeOS* connector =
g_browser_process->platform_part()->browser_policy_connector_chromeos();
return base::UTF8ToUTF16(connector->GetEnterpriseDisplayDomain());
return base::UTF8ToUTF16(connector->GetEnterpriseDomainManager());
}
void OnNotificationClicked(Profile* profile) {
......@@ -205,7 +205,7 @@ void PowerwashRequirementsChecker::ShowNotification() {
auto notification = ash::CreateSystemNotification(
mc::NOTIFICATION_TYPE_SIMPLE, notification_id,
l10n_util::GetStringUTF16(IDS_POWERWASH_REQUEST_TITLE),
l10n_util::GetStringFUTF16(message_id, GetEnterpriseDisplayDomain()),
l10n_util::GetStringFUTF16(message_id, GetEnterpriseManager()),
base::string16{}, GURL{},
mc::NotifierId(mc::NotifierType::SYSTEM_COMPONENT, notification_id),
std::move(rich_data), std::move(delegate), kNotificationIcon,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment