Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: packagerGecko.py

Issue 29361133: Issue 4544 - Consider platformHTMLBindings.xml when detecting available keyboard shortcuts (Closed) Base URL: https://hg.adblockplus.org/buildtools
Patch Set: Created Oct. 31, 2016, 10:02 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: packagerGecko.py
===================================================================
--- a/packagerGecko.py
+++ b/packagerGecko.py
@@ -232,33 +232,30 @@ def processJSONFiles(params, files):
del files[prefix + name]
def addMissingFiles(params, files):
templateData = {
'hasChrome': False,
'hasChromeRequires': False,
'hasShutdownHandlers': False,
- 'hasXMLHttpRequest': False,
'chromeWindows': [],
'requires': set(),
'jsonRequires': params['jsonRequires'],
'metadata': params['metadata'],
'multicompartment': params['multicompartment'],
'applications': dict((v, k) for k, v in KNOWN_APPS.iteritems()),
}
def checkScript(name):
content = files[name]
for match in re.finditer(r'(?:^|\s)require\(\s*"([\w\-]+)"\s*\)', content):
templateData['requires'].add(match.group(1))
if name.startswith('chrome/content/'):
templateData['hasChromeRequires'] = True
- if name.startswith('lib/') and re.search(r'\bXMLHttpRequest\b', content):
- templateData['hasXMLHttpRequest'] = True
if not '/' in name or name.startswith('lib/'):
if re.search(r'(?:^|\s)onShutdown\.', content):
templateData['hasShutdownHandlers'] = True
for name, content in files.iteritems():
if name == 'chrome.manifest':
templateData['hasChrome'] = True
elif name.endswith('.js'):
« no previous file with comments | « lib/keySelector.js ('k') | templates/bootstrap.js.tmpl » ('j') | templates/bootstrap.js.tmpl » ('J')

Powered by Google App Engine
This is Rietveld