mirror of
https://github.com/servo/servo.git
synced 2025-07-25 00:00:20 +01:00
This reverts commit 7fce850cff
.
This commit is contained in:
parent
45f2433d76
commit
8bc49299c8
86 changed files with 1193 additions and 517 deletions
|
@ -2167,8 +2167,7 @@ class CGImports(CGWrapper):
|
|||
"""
|
||||
Generates the appropriate import/use statements.
|
||||
"""
|
||||
def __init__(self, child, descriptors, callbacks, dictionaries, enums, typedefs, imports, config,
|
||||
current_name=None):
|
||||
def __init__(self, child, descriptors, callbacks, dictionaries, enums, typedefs, imports, config):
|
||||
"""
|
||||
Adds a set of imports.
|
||||
"""
|
||||
|
@ -2270,8 +2269,7 @@ class CGImports(CGWrapper):
|
|||
parentName = descriptor.getParentName()
|
||||
while parentName:
|
||||
descriptor = descriptorProvider.getDescriptor(parentName)
|
||||
if current_name != descriptor.ifaceName:
|
||||
extras += [descriptor.path, descriptor.bindingPath]
|
||||
extras += [descriptor.path, descriptor.bindingPath]
|
||||
parentName = descriptor.getParentName()
|
||||
elif t.isType() and t.isRecord():
|
||||
extras += ['crate::dom::bindings::record::Record']
|
||||
|
@ -6892,7 +6890,7 @@ class CGBindingRoot(CGThing):
|
|||
DomRoot codegen class for binding generation. Instantiate the class, and call
|
||||
declare or define to generate header or cpp code (respectively).
|
||||
"""
|
||||
def __init__(self, config, prefix, webIDLFile, name):
|
||||
def __init__(self, config, prefix, webIDLFile):
|
||||
descriptors = config.getDescriptors(webIDLFile=webIDLFile,
|
||||
hasInterfaceObject=True)
|
||||
# We also want descriptors that have an interface prototype object
|
||||
|
@ -6960,7 +6958,7 @@ class CGBindingRoot(CGThing):
|
|||
# These are the global imports (outside of the generated module)
|
||||
curr = CGImports(curr, descriptors=callbackDescriptors, callbacks=mainCallbacks,
|
||||
dictionaries=dictionaries, enums=enums, typedefs=typedefs,
|
||||
imports=['crate::dom::bindings::import::base::*'], config=config, current_name=name)
|
||||
imports=['crate::dom::bindings::import::base::*'], config=config)
|
||||
|
||||
# Add the auto-generated comment.
|
||||
curr = CGWrapper(curr, pre=AUTOGENERATED_WARNING_COMMENT + ALLOWED_WARNINGS)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue