summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-03-15 15:16:55 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-03-16 07:12:33 +0000
commit2b3c57887aeeaa592d693df23dbab98552434cb3 (patch)
tree8283d5bdabb792e127024b19c72eb3bd215af1cd /bin
parent51cf59ca9e45bc256222671effbcd90d88befbe8 (diff)
remove unused defines from HRC files in sd
Change-Id: I2cbb6257aa65e45f3e46b64a8f00e36aecd95564 Reviewed-on: https://gerrit.libreoffice.org/35219 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'bin')
-rwxr-xr-xbin/find-unused-defines-in-hrc-files.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/bin/find-unused-defines-in-hrc-files.py b/bin/find-unused-defines-in-hrc-files.py
index 59d917ad1dea..acf51573dd8e 100755
--- a/bin/find-unused-defines-in-hrc-files.py
+++ b/bin/find-unused-defines-in-hrc-files.py
@@ -78,6 +78,7 @@ exclusionSet = set([
"STR_UPDATE_ALL",
"STR_UPDATE_INDEX",
"STR_UPDATE_LINK",
+ "BMP_PLACEHOLDER_",
])
@@ -125,10 +126,12 @@ with a.stdout as txt:
# these are used in calculations in other .hrc files
if "sw/inc/rcid.hrc:" in line2: found_reason_to_exclude = True
# calculations
- if "sw/source/uibase/inc/ribbar.hrc:" in line2 and "ST_" in line2: found_reason_to_exclude = True
- if "sw/source/uibase/inc/ribbar.hrc:" in line2 and "STR_IMGBTN_" in line2: found_reason_to_exclude = True
+ if "sw/source/uibase/inc/ribbar.hrc:" in line2 and "ST_" in idName: found_reason_to_exclude = True
+ if "sw/source/uibase/inc/ribbar.hrc:" in line2 and "STR_IMGBTN_" in idName: found_reason_to_exclude = True
if "sw/source/core/undo/undo.hrc:" in line2: found_reason_to_exclude = True
if "sw/inc/poolfmt.hrc:" in line2: found_reason_to_exclude = True
+ # not sure about these, looks suspicious
+ if "sd/source/ui/app/strings.src:" in line2 and idName.endswith("_TOOLBOX"): found_reason_to_exclude = True
if not found_reason_to_exclude:
sys.stdout.write(idName + '\n')