зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1230291. Correctly include nsContentUtils when generating a manual hasInstance with nsIDOM* stuff or when we have a JS-implemented interface with clearable cached attrs
This commit is contained in:
Родитель
279d126b1b
Коммит
affdb545dd
|
@ -1008,6 +1008,8 @@ class CGHeaders(CGWrapper):
|
|||
d.interface.hasInterfaceObject() and
|
||||
NeedsGeneratedHasInstance(d) and
|
||||
d.interface.hasInterfacePrototypeObject())
|
||||
if len(hasInstanceIncludes) > 0:
|
||||
hasInstanceIncludes.add("nsContentUtils.h")
|
||||
|
||||
# Now find all the things we'll need as arguments because we
|
||||
# need to wrap or unwrap them.
|
||||
|
@ -13120,7 +13122,11 @@ class CGBindingRoot(CGThing):
|
|||
# interface object might have a ChromeOnly constructor.
|
||||
(desc.interface.hasInterfaceObject() and
|
||||
(desc.interface.isJSImplemented() or
|
||||
(ctor and isChromeOnly(ctor)))))
|
||||
(ctor and isChromeOnly(ctor)))) or
|
||||
# JS-implemented interfaces with clearable cached
|
||||
# attrs have chromeonly _clearFoo methods.
|
||||
(desc.interface.isJSImplemented() and
|
||||
any(clearableCachedAttrs(desc))))
|
||||
|
||||
bindingHeaders["nsContentUtils.h"] = any(
|
||||
descriptorHasChromeOnly(d) for d in descriptors)
|
||||
|
|
Загрузка…
Ссылка в новой задаче