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

Side by Side Diff: chrome/tools/check_grd_for_unused_strings.py

Issue 7210060: Rename app_strings to ui_strings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « chrome/tools/build/repack_locales.py ('k') | tools/grit/resource_ids » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/python 1 #!/usr/bin/python
2 2
3 # Copyright (c) 2010 The Chromium Authors. All rights reserved. 3 # Copyright (c) 2010 The Chromium Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 """Without any args, this simply loads the IDs out of a bunch of the Chrome GRD 7 """Without any args, this simply loads the IDs out of a bunch of the Chrome GRD
8 files, and then checks the subset of the code that loads the strings to try 8 files, and then checks the subset of the code that loads the strings to try
9 and figure out what isn't in use any more. 9 and figure out what isn't in use any more.
10 You can give paths to GRD files and source directories to control what is 10 You can give paths to GRD files and source directories to control what is
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after
140 os.path.join(chrome_app_res_dir, 'locale_settings_linux.grd'), 140 os.path.join(chrome_app_res_dir, 'locale_settings_linux.grd'),
141 os.path.join(chrome_app_res_dir, 'locale_settings_mac.grd'), 141 os.path.join(chrome_app_res_dir, 'locale_settings_mac.grd'),
142 os.path.join(chrome_app_res_dir, 'locale_settings_win.grd'), 142 os.path.join(chrome_app_res_dir, 'locale_settings_win.grd'),
143 os.path.join(chrome_app_dir, 'theme', 'theme_resources.grd'), 143 os.path.join(chrome_app_dir, 'theme', 'theme_resources.grd'),
144 os.path.join(chrome_dir, 'browser', 'browser_resources.grd'), 144 os.path.join(chrome_dir, 'browser', 'browser_resources.grd'),
145 os.path.join(chrome_dir, 'common', 'common_resources.grd'), 145 os.path.join(chrome_dir, 'common', 'common_resources.grd'),
146 os.path.join(chrome_dir, 'renderer', 'renderer_resources.grd'), 146 os.path.join(chrome_dir, 'renderer', 'renderer_resources.grd'),
147 os.path.join(src_dir, 'ui', 'gfx', 'gfx_resources.grd'), 147 os.path.join(src_dir, 'ui', 'gfx', 'gfx_resources.grd'),
148 os.path.join(src_dir, 'ui', 'resources', 'ui_resources.grd'), 148 os.path.join(src_dir, 'ui', 'resources', 'ui_resources.grd'),
149 os.path.join(ui_base_dir, 'app_locale_settings.grd'), 149 os.path.join(ui_base_dir, 'app_locale_settings.grd'),
150 os.path.join(ui_base_dir, 'app_strings.grd'), 150 os.path.join(ui_base_dir, 'ui_strings.grd'),
151 ] 151 ]
152 152
153 # If no source directories were given, default them: 153 # If no source directories were given, default them:
154 if len(src_dirs) == 0: 154 if len(src_dirs) == 0:
155 src_dirs = [ 155 src_dirs = [
156 os.path.join(src_dir, 'app'), 156 os.path.join(src_dir, 'app'),
157 os.path.join(src_dir, 'content'), 157 os.path.join(src_dir, 'content'),
158 os.path.join(src_dir, 'chrome'), 158 os.path.join(src_dir, 'chrome'),
159 os.path.join(src_dir, 'ui'), 159 os.path.join(src_dir, 'ui'),
160 os.path.join(src_dir, 'views'), 160 os.path.join(src_dir, 'views'),
161 # nsNSSCertHelper.cpp has a bunch of ids 161 # nsNSSCertHelper.cpp has a bunch of ids
162 os.path.join(src_dir, 'third_party', 'mozilla_security_manager'), 162 os.path.join(src_dir, 'third_party', 'mozilla_security_manager'),
163 ] 163 ]
164 164
165 sys.exit(CheckForUnusedGrdIDsInSources(grd_files, src_dirs)) 165 sys.exit(CheckForUnusedGrdIDsInSources(grd_files, src_dirs))
OLDNEW
« no previous file with comments | « chrome/tools/build/repack_locales.py ('k') | tools/grit/resource_ids » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698