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

Side by Side Diff: chrome/browser/ui/webui/settings/md_settings_localized_strings_provider.cc

Issue 1785833002: Add 5 experimental accessibility features on Chrome OS. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Ported to md-settings too Created 4 years, 9 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
OLDNEW
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/strings/utf_string_conversions.h" 9 #include "base/strings/utf_string_conversions.h"
10 #include "build/build_config.h" 10 #include "build/build_config.h"
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 {"clickOnStopLabel", IDS_SETTINGS_CLICK_ON_STOP_LABEL}, 84 {"clickOnStopLabel", IDS_SETTINGS_CLICK_ON_STOP_LABEL},
85 {"delayBeforeClickLabel", IDS_SETTINGS_DELAY_BEFORE_CLICK_LABEL}, 85 {"delayBeforeClickLabel", IDS_SETTINGS_DELAY_BEFORE_CLICK_LABEL},
86 {"delayBeforeClickExtremelyShort", 86 {"delayBeforeClickExtremelyShort",
87 IDS_SETTINGS_DELAY_BEFORE_CLICK_EXTREMELY_SHORT}, 87 IDS_SETTINGS_DELAY_BEFORE_CLICK_EXTREMELY_SHORT},
88 {"delayBeforeClickVeryShort", IDS_SETTINGS_DELAY_BEFORE_CLICK_VERY_SHORT}, 88 {"delayBeforeClickVeryShort", IDS_SETTINGS_DELAY_BEFORE_CLICK_VERY_SHORT},
89 {"delayBeforeClickShort", IDS_SETTINGS_DELAY_BEFORE_CLICK_SHORT}, 89 {"delayBeforeClickShort", IDS_SETTINGS_DELAY_BEFORE_CLICK_SHORT},
90 {"delayBeforeClickLong", IDS_SETTINGS_DELAY_BEFORE_CLICK_LONG}, 90 {"delayBeforeClickLong", IDS_SETTINGS_DELAY_BEFORE_CLICK_LONG},
91 {"delayBeforeClickVeryLong", IDS_SETTINGS_DELAY_BEFORE_CLICK_VERY_LONG}, 91 {"delayBeforeClickVeryLong", IDS_SETTINGS_DELAY_BEFORE_CLICK_VERY_LONG},
92 {"onScreenKeyboardLabel", IDS_SETTINGS_ON_SCREEN_KEYBOARD_LABEL}, 92 {"onScreenKeyboardLabel", IDS_SETTINGS_ON_SCREEN_KEYBOARD_LABEL},
93 {"a11yExplanation", IDS_SETTINGS_ACCESSIBILITY_EXPLANATION}, 93 {"a11yExplanation", IDS_SETTINGS_ACCESSIBILITY_EXPLANATION},
94 {"caretHighlightLabel",
95 IDS_OPTIONS_SETTINGS_ACCESSIBILITY_CARET_HIGHLIGHT_DESCRIPTION },
96 {"cursorHighlightLabel",
97 IDS_OPTIONS_SETTINGS_ACCESSIBILITY_CURSOR_HIGHLIGHT_DESCRIPTION },
98 {"focusHighlightLabel",
99 IDS_OPTIONS_SETTINGS_ACCESSIBILITY_FOCUS_HIGHLIGHT_DESCRIPTION },
100 {"selectToSpeakLabel",
101 IDS_OPTIONS_SETTINGS_ACCESSIBILITY_SELECT_TO_SPEAK_DESCRIPTION },
102 {"switchAccessLabel",
103 IDS_OPTIONS_SETTINGS_ACCESSIBILITY_SWITCH_ACCESS_DESCRIPTION },
94 }; 104 };
95 AddLocalizedStringsBulk(html_source, localized_strings, 105 AddLocalizedStringsBulk(html_source, localized_strings,
96 arraysize(localized_strings)); 106 arraysize(localized_strings));
97 107
98 html_source->AddString("a11yLearnMoreUrl", 108 html_source->AddString("a11yLearnMoreUrl",
99 chrome::kChromeAccessibilityHelpURL); 109 chrome::kChromeAccessibilityHelpURL);
Dan Beam 2016/03/11 22:07:20 I think rather than making an A11yHandler, you sho
100 } 110 }
101 #endif 111 #endif
102 112
103 #if defined(OS_CHROMEOS) 113 #if defined(OS_CHROMEOS)
104 void AddAccountUITweaksStrings(content::WebUIDataSource* html_source, 114 void AddAccountUITweaksStrings(content::WebUIDataSource* html_source,
105 Profile* profile) { 115 Profile* profile) {
106 base::DictionaryValue localized_values; 116 base::DictionaryValue localized_values;
107 chromeos::AddAccountUITweaksLocalizedValues(&localized_values, profile); 117 chromeos::AddAccountUITweaksLocalizedValues(&localized_values, profile);
108 html_source->AddLocalizedStrings(localized_values); 118 html_source->AddLocalizedStrings(localized_values);
109 } 119 }
(...skipping 687 matching lines...) Expand 10 before | Expand all | Expand 10 after
797 #endif 807 #endif
798 AddUsersStrings(html_source); 808 AddUsersStrings(html_source);
799 AddWebContentStrings(html_source); 809 AddWebContentStrings(html_source);
800 810
801 policy_indicator::AddLocalizedStrings(html_source); 811 policy_indicator::AddLocalizedStrings(html_source);
802 812
803 html_source->SetJsonPath(kLocalizedStringsFile); 813 html_source->SetJsonPath(kLocalizedStringsFile);
804 } 814 }
805 815
806 } // namespace settings 816 } // namespace settings
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698