Bug 827486, part 3 - add dependencies for CGBindingImplClass. r=bz
--- a/dom/bindings/Codegen.py
+++ b/dom/bindings/Codegen.py
@@ -7660,16 +7660,17 @@ class CGBindingImplClass(CGClass):
Common codegen for generating a C++ implementation of a WebIDL interface
"""
def __init__(self, descriptor, cgMethod, cgGetter, cgSetter):
"""
cgMethod, cgGetter and cgSetter are classes used to codegen methods,
getters and setters.
"""
self.descriptor = descriptor
+ self._deps = descriptor.interface.getDeps()
iface = descriptor.interface
self.methodDecls = []
def appendMethod(m):
sigs = m.signatures()
for s in sigs[:-1]:
# Don't put an empty line after overloads, until we
@@ -7775,16 +7776,20 @@ class CGBindingImplClass(CGClass):
def getGetParentObjectReturnType(self):
return ("// TODO: return something sensible here, and change the return type\n"
"%s*" % self.descriptor.name)
def getGetParentObjectBody(self):
return None
+ def deps(self):
+ return self._deps
+
+
class CGExampleClass(CGBindingImplClass):
"""
Codegen for the actual example class implementation for this descriptor
"""
def __init__(self, descriptor):
CGBindingImplClass.__init__(self, descriptor, CGExampleMethod, CGExampleGetter, CGExampleSetter)
extradeclarations=(