summaryrefslogtreecommitdiffstats
path: root/remoting/tools
diff options
context:
space:
mode:
authorjamiewalch@chromium.org <jamiewalch@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-09-10 17:31:18 +0000
committerjamiewalch@chromium.org <jamiewalch@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-09-10 17:31:18 +0000
commit5c071edb2a53e90a7b6b12531ffe0441cd57803d (patch)
tree3c4b0b1b81a43b6bb34393c7bfc683603e9c243f /remoting/tools
parenteb8c1fd0a32f805e91bb711aa46f8108d3403c54 (diff)
downloadchromium_src-5c071edb2a53e90a7b6b12531ffe0441cd57803d.zip
chromium_src-5c071edb2a53e90a7b6b12531ffe0441cd57803d.tar.gz
chromium_src-5c071edb2a53e90a7b6b12531ffe0441cd57803d.tar.bz2
Add support for i18n-title.
Previously, we only had one tool-tip defined in the HTML markup, and its l10n was hard-coded. This CL adds a generic mechanism, uses it for the local host edit button and adds a tool-tip to the host list refresh button. Review URL: https://chromiumcodereview.appspot.com/23923009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@222295 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'remoting/tools')
-rwxr-xr-xremoting/tools/verify_resources.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/remoting/tools/verify_resources.py b/remoting/tools/verify_resources.py
index eb59b2f..5623228 100755
--- a/remoting/tools/verify_resources.py
+++ b/remoting/tools/verify_resources.py
@@ -12,8 +12,9 @@ annotated with the string "i18n-content", for example:
This script also recognises localized strings in HTML and manifest.json files:
- HTML: <span i18n-content="PRODUCT_NAME"></span>
- or ...i18n-value-name-1="BUTTON_NAME"...
+ HTML: i18n-content="PRODUCT_NAME"
+ or i18n-value-name-1="BUTTON_NAME"
+ or i18n-title="TOOLTIP_NAME"
manifest.json: __MSG_PRODUCT_NAME__
Note that these forms must be exact; extra spaces are not permitted, though
@@ -55,6 +56,9 @@ def ExtractTagFromLine(file_type, line):
# HTML-style (tags)
m = re.search('i18n-content=[\'"]([^\'"]*)[\'"]', line)
if m: return m.group(1)
+ # HTML-style (titles)
+ m = re.search('i18n-title=[\'"]([^\'"]*)[\'"]', line)
+ if m: return m.group(1)
# HTML-style (substitutions)
m = re.search('i18n-value-name-[1-9]=[\'"]([^\'"]*)[\'"]', line)
if m: return m.group(1)