OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/webui/settings/md_settings_localized_strings_provide
r.h" | 5 #include "chrome/browser/ui/webui/settings/md_settings_localized_strings_provide
r.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
11 #include "build/build_config.h" | 11 #include "build/build_config.h" |
12 #include "chrome/browser/browser_process.h" | 12 #include "chrome/browser/browser_process.h" |
13 #include "chrome/browser/profiles/profile.h" | 13 #include "chrome/browser/profiles/profile.h" |
14 #include "chrome/browser/ui/webui/policy_indicator_localized_strings_provider.h" | 14 #include "chrome/browser/ui/webui/policy_indicator_localized_strings_provider.h" |
15 #include "chrome/common/url_constants.h" | 15 #include "chrome/common/url_constants.h" |
16 #include "chrome/grit/chromium_strings.h" | 16 #include "chrome/grit/chromium_strings.h" |
17 #include "chrome/grit/generated_resources.h" | 17 #include "chrome/grit/generated_resources.h" |
18 #include "chrome/grit/google_chrome_strings.h" | 18 #include "chrome/grit/google_chrome_strings.h" |
19 #include "chrome/grit/locale_settings.h" | 19 #include "chrome/grit/locale_settings.h" |
20 #include "chrome/grit/settings_chromium_strings.h" | 20 #include "chrome/grit/settings_chromium_strings.h" |
21 #include "chrome/grit/settings_google_chrome_strings.h" | 21 #include "chrome/grit/settings_google_chrome_strings.h" |
22 #include "chrome/grit/settings_strings.h" | 22 #include "chrome/grit/settings_strings.h" |
23 #include "components/google/core/browser/google_util.h" | 23 #include "components/google/core/browser/google_util.h" |
| 24 #include "components/password_manager/core/browser/password_manager_constants.h" |
24 #include "content/public/browser/web_ui_data_source.h" | 25 #include "content/public/browser/web_ui_data_source.h" |
25 #include "grit/components_strings.h" | 26 #include "grit/components_strings.h" |
26 #include "ui/base/l10n/l10n_util.h" | 27 #include "ui/base/l10n/l10n_util.h" |
27 | 28 |
28 #if defined(OS_CHROMEOS) | 29 #if defined(OS_CHROMEOS) |
29 #include "ash/system/chromeos/devicetype_utils.h" | 30 #include "ash/system/chromeos/devicetype_utils.h" |
30 #include "chrome/browser/chromeos/profiles/profile_helper.h" | 31 #include "chrome/browser/chromeos/profiles/profile_helper.h" |
31 #include "chrome/browser/signin/easy_unlock_service.h" | 32 #include "chrome/browser/signin/easy_unlock_service.h" |
32 #include "chrome/browser/ui/webui/chromeos/ui_account_tweaks.h" | 33 #include "chrome/browser/ui/webui/chromeos/ui_account_tweaks.h" |
33 #include "chromeos/chromeos_switches.h" | 34 #include "chromeos/chromeos_switches.h" |
(...skipping 558 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
592 {"passwordExceptionsHeading", IDS_SETTINGS_PASSWORDS_EXCEPTIONS_HEADING}, | 593 {"passwordExceptionsHeading", IDS_SETTINGS_PASSWORDS_EXCEPTIONS_HEADING}, |
593 {"deletePasswordException", IDS_SETTINGS_PASSWORDS_DELETE_EXCEPTION}, | 594 {"deletePasswordException", IDS_SETTINGS_PASSWORDS_DELETE_EXCEPTION}, |
594 {"passwordMenu", IDS_SETTINGS_PASSWORDS_MENU}, | 595 {"passwordMenu", IDS_SETTINGS_PASSWORDS_MENU}, |
595 {"editPassword", IDS_SETTINGS_PASSWORDS_EDIT}, | 596 {"editPassword", IDS_SETTINGS_PASSWORDS_EDIT}, |
596 {"removePassword", IDS_SETTINGS_PASSWORDS_REMOVE}, | 597 {"removePassword", IDS_SETTINGS_PASSWORDS_REMOVE}, |
597 {"editPasswordTitle", IDS_SETTINGS_PASSWORDS_EDIT_TITLE}, | 598 {"editPasswordTitle", IDS_SETTINGS_PASSWORDS_EDIT_TITLE}, |
598 {"editPasswordWebsiteLabel", IDS_SETTINGS_PASSWORDS_WEBSITE}, | 599 {"editPasswordWebsiteLabel", IDS_SETTINGS_PASSWORDS_WEBSITE}, |
599 {"editPasswordUsernameLabel", IDS_SETTINGS_PASSWORDS_USERNAME}, | 600 {"editPasswordUsernameLabel", IDS_SETTINGS_PASSWORDS_USERNAME}, |
600 {"editPasswordPasswordLabel", IDS_SETTINGS_PASSWORDS_PASSWORD}, | 601 {"editPasswordPasswordLabel", IDS_SETTINGS_PASSWORDS_PASSWORD}, |
601 }; | 602 }; |
| 603 html_source->AddString( |
| 604 "managePasswordsLabel", |
| 605 l10n_util::GetStringFUTF16( |
| 606 IDS_SETTINGS_PASSWORDS_MANAGE_PASSWORDS, |
| 607 base::ASCIIToUTF16( |
| 608 password_manager::kPasswordManagerAccountDashboardURL))); |
602 AddLocalizedStringsBulk(html_source, localized_strings, | 609 AddLocalizedStringsBulk(html_source, localized_strings, |
603 arraysize(localized_strings)); | 610 arraysize(localized_strings)); |
604 } | 611 } |
605 | 612 |
606 void AddPeopleStrings(content::WebUIDataSource* html_source) { | 613 void AddPeopleStrings(content::WebUIDataSource* html_source) { |
607 LocalizedString localized_strings[] = { | 614 LocalizedString localized_strings[] = { |
608 {"peoplePageTitle", IDS_SETTINGS_PEOPLE}, | 615 {"peoplePageTitle", IDS_SETTINGS_PEOPLE}, |
609 {"manageOtherPeople", IDS_SETTINGS_PEOPLE_MANAGE_OTHER_PEOPLE}, | 616 {"manageOtherPeople", IDS_SETTINGS_PEOPLE_MANAGE_OTHER_PEOPLE}, |
610 #if defined(OS_CHROMEOS) | 617 #if defined(OS_CHROMEOS) |
611 {"enableScreenlock", IDS_SETTINGS_PEOPLE_ENABLE_SCREENLOCK}, | 618 {"enableScreenlock", IDS_SETTINGS_PEOPLE_ENABLE_SCREENLOCK}, |
(...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
949 #endif | 956 #endif |
950 AddUsersStrings(html_source); | 957 AddUsersStrings(html_source); |
951 AddWebContentStrings(html_source); | 958 AddWebContentStrings(html_source); |
952 | 959 |
953 policy_indicator::AddLocalizedStrings(html_source); | 960 policy_indicator::AddLocalizedStrings(html_source); |
954 | 961 |
955 html_source->SetJsonPath(kLocalizedStringsFile); | 962 html_source->SetJsonPath(kLocalizedStringsFile); |
956 } | 963 } |
957 | 964 |
958 } // namespace settings | 965 } // namespace settings |
OLD | NEW |