diff options
-rw-r--r-- | chrome/app/generated_resources.grd | 18 | ||||
-rw-r--r-- | chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.cc | 13 | ||||
-rwxr-xr-x | tools/gen_keyboard_overlay_data/gen_keyboard_overlay_data.py | 16 |
3 files changed, 33 insertions, 14 deletions
diff --git a/chrome/app/generated_resources.grd b/chrome/app/generated_resources.grd index 8646e02e..72ae6e9 100644 --- a/chrome/app/generated_resources.grd +++ b/chrome/app/generated_resources.grd @@ -12060,12 +12060,18 @@ Keep your key file in a safe place. You will need it to create new versions of y <message name="IDS_KEYBOARD_OVERLAY_FIND_PREVIOUS" desc="The text in the keyboard overlay to explain the shortcut."> Find previous </message> + <message name="IDS_KEYBOARD_OVERLAY_FIND_PREVIOUS" desc="The text in the keyboard overlay to explain the shortcut."> + Find previous + </message> <message name="IDS_KEYBOARD_OVERLAY_FIND_TEXT" desc="The text in the keyboard overlay to explain the shortcut."> Find text </message> <message name="IDS_KEYBOARD_OVERLAY_FOCUS_ADDRESS_BAR" desc="The text in the keyboard overlay to explain the shortcut."> Focus address bar </message> + <message name="IDS_KEYBOARD_OVERLAY_FOCUS_ADDRESS_BAR" desc="The text in the keyboard overlay to explain the shortcut."> + Focus address bar + </message> <message name="IDS_KEYBOARD_OVERLAY_FOCUS_ADDRESS_BAR_IN_SEARCH_MODE" desc="The text in the keyboard overlay to explain the shortcut."> Focus address bar in search mode </message> @@ -12084,6 +12090,9 @@ Keep your key file in a safe place. You will need it to create new versions of y <message name="IDS_KEYBOARD_OVERLAY_FORWARD" desc="The text in the keyboard overlay to explain the shortcut."> Forward </message> + <message name="IDS_KEYBOARD_OVERLAY_FORWARD" desc="The text in the keyboard overlay to explain the shortcut."> + Forward + </message> <message name="IDS_KEYBOARD_OVERLAY_HISTORY" desc="The text in the keyboard overlay to explain the shortcut."> History </message> @@ -12117,6 +12126,9 @@ Keep your key file in a safe place. You will need it to create new versions of y <message name="IDS_KEYBOARD_OVERLAY_SELECT_WORD_AT_A_TIME" desc="The text in the keyboard overlay to explain the shortcut."> Select "word at a time" </message> + <message name="IDS_KEYBOARD_OVERLAY_SELECT_WORD_AT_A_TIME" desc="The text in the keyboard overlay to explain the shortcut."> + Select "word at a time" + </message> <message name="IDS_KEYBOARD_OVERLAY_TOGGLE_BOOKMARK_BAR" desc="The text in the keyboard overlay to explain the shortcut."> Toggle bookmark bar </message> @@ -12129,6 +12141,12 @@ Keep your key file in a safe place. You will need it to create new versions of y <message name="IDS_KEYBOARD_OVERLAY_ZOOM_OUT" desc="The text in the keyboard overlay to explain the shortcut."> Zoom out </message> + <message name="IDS_KEYBOARD_OVERLAY_RESET_ZOOM" desc="The text in the keyboard overlay to explain the shortcut."> + Reset zoom + </message> + <message name="IDS_KEYBOARD_OVERLAY_FOCUS_ADDRESS_BAR_IN_SEARCH_MODE" desc="The text in the keyboard overlay to explain the shortcut."> + Focus address bar in search mode + </message> <message name="IDS_KEYBOARD_OVERLAY_TAKE_SCREENSHOT" desc="The text in the keyboard overlay to explain the shortcut."> Take screenshot </message> diff --git a/chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.cc b/chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.cc index 99a6355..181210d 100644 --- a/chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.cc +++ b/chrome/browser/ui/webui/chromeos/keyboard_overlay_ui.cc @@ -161,10 +161,14 @@ void KeyboardOverlayUIHTMLSource::StartDataRequest(const std::string& path, l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_FIND_AGAIN)); localized_strings.SetString("keyboardOverlayFindPrevious", l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_FIND_PREVIOUS)); + localized_strings.SetString("keyboardOverlayFindPrevious", + l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_FIND_PREVIOUS)); localized_strings.SetString("keyboardOverlayFindText", l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_FIND_TEXT)); localized_strings.SetString("keyboardOverlayFocusAddressBar", l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_FOCUS_ADDRESS_BAR)); + localized_strings.SetString("keyboardOverlayFocusAddressBar", + l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_FOCUS_ADDRESS_BAR)); localized_strings.SetString("keyboardOverlayFocusAddressBarInSearchMode", l10n_util::GetStringUTF16( IDS_KEYBOARD_OVERLAY_FOCUS_ADDRESS_BAR_IN_SEARCH_MODE)); @@ -178,6 +182,8 @@ void KeyboardOverlayUIHTMLSource::StartDataRequest(const std::string& path, l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_BACK)); localized_strings.SetString("keyboardOverlayForward", l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_FORWARD)); + localized_strings.SetString("keyboardOverlayForward", + l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_FORWARD)); localized_strings.SetString("keyboardOverlayHistory", l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_HISTORY)); localized_strings.SetString("keyboardOverlayNewTab", @@ -200,6 +206,8 @@ void KeyboardOverlayUIHTMLSource::StartDataRequest(const std::string& path, l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_RESET_ZOOM)); localized_strings.SetString("keyboardOverlaySelectWordAtATime", l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_SELECT_WORD_AT_A_TIME)); + localized_strings.SetString("keyboardOverlaySelectWordAtATime", + l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_SELECT_WORD_AT_A_TIME)); localized_strings.SetString("keyboardOverlayToggleBookmarkBar", l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_TOGGLE_BOOKMARK_BAR)); localized_strings.SetString("keyboardOverlayViewSource", @@ -208,6 +216,11 @@ void KeyboardOverlayUIHTMLSource::StartDataRequest(const std::string& path, l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_ZOOM_IN)); localized_strings.SetString("keyboardOverlayZoomOut", l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_ZOOM_OUT)); + localized_strings.SetString("keyboardOverlayResetZoom", + l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_RESET_ZOOM)); + localized_strings.SetString("keyboardOverlayFocusAddressBarInSearchMode", + l10n_util::GetStringUTF16( + IDS_KEYBOARD_OVERLAY_FOCUS_ADDRESS_BAR_IN_SEARCH_MODE)); localized_strings.SetString("keyboardOverlayTakeScreenshot", l10n_util::GetStringUTF16(IDS_KEYBOARD_OVERLAY_TAKE_SCREENSHOT)); localized_strings.SetString("keyboardOverlayHome", diff --git a/tools/gen_keyboard_overlay_data/gen_keyboard_overlay_data.py b/tools/gen_keyboard_overlay_data/gen_keyboard_overlay_data.py index dd40249..18f3735 100755 --- a/tools/gen_keyboard_overlay_data/gen_keyboard_overlay_data.py +++ b/tools/gen_keyboard_overlay_data/gen_keyboard_overlay_data.py @@ -340,18 +340,6 @@ def GenerateCopyrightHeader(): return COPYRIGHT_HEADER_TEMPLATE % datetime.date.today().year -def UniqueBehaviors(hotkey_data): - """Retrieves a list of unique behaviors from |hotkey_data|.""" - behaviors = [] - added = set() - for (behavior, _) in hotkey_data: - if behavior in added: - continue - behaviors.append(behavior) - added.add(behavior) - return behaviors - - def OutputJson(keyboard_glyph_data, hotkey_data, layouts, var_name, outfile): """Outputs the keyboard overlay data as a JSON file.""" print 'Generating: %s' % outfile @@ -375,7 +363,7 @@ def OutputGrd(hotkey_data, outfile): print 'Generating: %s' % outfile desc = 'The text in the keyboard overlay to explain the shortcut.' out = file(outfile, 'w') - for behavior in UniqueBehaviors(hotkey_data): + for (behavior, _) in hotkey_data: out.write(GRD_SNIPPET_TEMPLATE % (ToMessageName(behavior), desc, behavior)) @@ -383,7 +371,7 @@ def OutputCC(hotkey_data, outfile): """Outputs a snippet used for C++ file.""" print 'Generating: %s' % outfile out = file(outfile, 'w') - for behavior in UniqueBehaviors(hotkey_data): + for (behavior, _) in hotkey_data: message_name = ToMessageName(behavior) # Indent the line if message_name is longer than 45 characters, which means # the second line in the generated code is longer than 80 characters. |