mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
cangc fixes in node.rs (#33984)
Signed-off-by: L Ashwin B <lashwinib@gmail.com>
This commit is contained in:
parent
3ed778150f
commit
bb4932026c
97 changed files with 1038 additions and 534 deletions
|
@ -66,6 +66,14 @@ DOMInterfaces = {
|
|||
'canGc': ['GetTransform','GetImageData', 'CreateImageData', 'CreateImageData_', 'SetFont', 'FillText', 'MeasureText', 'SetStrokeStyle', 'SetFillStyle', 'SetShadowColor'],
|
||||
},
|
||||
|
||||
'CharacterData': {
|
||||
'canGc': ['Before', 'After', 'ReplaceWith']
|
||||
},
|
||||
|
||||
'CSSStyleDeclaration': {
|
||||
'canGc': ['RemoveProperty', 'SetCssText']
|
||||
},
|
||||
|
||||
'CanvasGradient': {
|
||||
'canGc': ['AddColorStop'],
|
||||
},
|
||||
|
@ -76,7 +84,7 @@ DOMInterfaces = {
|
|||
},
|
||||
|
||||
'DOMImplementation': {
|
||||
'canGc': ['CreateDocument', 'CreateHTMLDocument'],
|
||||
'canGc': ['CreateDocument', 'CreateHTMLDocument', 'CreateDocumentType'],
|
||||
},
|
||||
|
||||
'DOMMatrix': {
|
||||
|
@ -104,15 +112,31 @@ DOMInterfaces = {
|
|||
},
|
||||
|
||||
'Document': {
|
||||
'canGc': ['Close', 'CreateElement', 'CreateElementNS', 'ImportNode', 'SetTitle', 'Write', 'Writeln', 'CreateEvent', 'CreateRange', 'Open', 'Open_', 'Fonts', 'ElementFromPoint', 'ElementsFromPoint', 'ExitFullscreen'],
|
||||
'canGc': ['Close', 'CreateElement', 'CreateElementNS', 'ImportNode', 'SetTitle', 'Write', 'Writeln', 'CreateEvent', 'CreateRange', 'Open', 'Open_', 'CreateComment', 'CreateAttribute', 'CreateAttributeNS', 'CreateDocumentFragment', 'CreateTextNode', 'CreateCDATASection', 'CreateProcessingInstruction', 'Prepend', 'Append', 'ReplaceChildren', 'SetBgColor', 'SetFgColor', 'Fonts', 'ElementFromPoint', 'ElementsFromPoint', 'ExitFullscreen'],
|
||||
},
|
||||
|
||||
'DynamicModuleOwner': {
|
||||
'inRealms': ['PromiseAttribute'],
|
||||
},
|
||||
|
||||
'DocumentFragment': {
|
||||
'canGc': ['Prepend', 'Append', 'ReplaceChildren']
|
||||
},
|
||||
|
||||
'DocumentType': {
|
||||
'canGc': ['Before', 'After', 'ReplaceWith']
|
||||
},
|
||||
|
||||
'DOMStringMap': {
|
||||
'canGc': ['NamedSetter']
|
||||
},
|
||||
|
||||
"DOMTokenList": {
|
||||
'canGc': ['SetValue', 'Add', 'Remove', 'Toggle', 'Replace']
|
||||
},
|
||||
|
||||
'Element': {
|
||||
'canGc': ['SetInnerHTML', 'SetOuterHTML', 'InsertAdjacentHTML', 'GetClientRects', 'GetBoundingClientRect', 'SetScrollTop', 'SetScrollLeft', 'Scroll', 'Scroll_', 'ScrollBy', 'ScrollBy_', 'ScrollWidth', 'ScrollHeight', 'ScrollTop', 'ScrollLeft', 'ClientTop', 'ClientLeft', 'ClientWidth', 'ClientHeight', 'RequestFullscreen'],
|
||||
'canGc': ['SetInnerHTML', 'SetOuterHTML', 'InsertAdjacentHTML', 'GetClientRects', 'GetBoundingClientRect', 'InsertAdjacentText', 'ToggleAttribute', 'SetAttribute', 'SetAttributeNS', "SetId","SetClassName","Prepend","Append","ReplaceChildren","Before","After","ReplaceWith", 'SetRole', 'SetAriaAtomic', 'SetAriaAutoComplete', 'SetAriaBrailleLabel', 'SetAriaBrailleRoleDescription', 'SetAriaBusy', 'SetAriaChecked', 'SetAriaColCount', 'SetAriaColIndex', 'SetAriaColIndexText', 'SetAriaColSpan', 'SetAriaCurrent', 'SetAriaDescription', 'SetAriaDisabled', 'SetAriaExpanded', 'SetAriaHasPopup', 'SetAriaHidden', 'SetAriaInvalid', 'SetAriaKeyShortcuts', 'SetAriaLabel', 'SetAriaLevel', 'SetAriaLive', 'SetAriaModal', 'SetAriaMultiLine', 'SetAriaMultiSelectable', 'SetAriaOrientation', 'SetAriaPlaceholder', 'SetAriaPosInSet', 'SetAriaPressed','SetAriaReadOnly', 'SetAriaRelevant', 'SetAriaRequired', 'SetAriaRoleDescription', 'SetAriaRowCount', 'SetAriaRowIndex', 'SetAriaRowIndexText', 'SetAriaRowSpan', 'SetAriaSelected', 'SetAriaSetSize','SetAriaSort', 'SetAriaValueMax', 'SetAriaValueMin', 'SetAriaValueNow', 'SetAriaValueText', 'SetScrollTop', 'SetScrollLeft', 'Scroll', 'Scroll_', 'ScrollBy', 'ScrollBy_', 'ScrollWidth', 'ScrollHeight', 'ScrollTop', 'ScrollLeft', 'ClientTop', 'ClientLeft', 'ClientWidth', 'ClientHeight', 'RequestFullscreen'],
|
||||
},
|
||||
|
||||
'ElementInternals': {
|
||||
|
@ -184,31 +208,47 @@ DOMInterfaces = {
|
|||
},
|
||||
|
||||
'HTMLButtonElement': {
|
||||
'canGc': ['CheckValidity', 'ReportValidity'],
|
||||
'canGc': ['CheckValidity', 'ReportValidity','SetBackground'],
|
||||
},
|
||||
|
||||
'HTMLElement': {
|
||||
'canGc': ['GetOffsetParent', 'OffsetTop', 'OffsetLeft', 'OffsetWidth', 'OffsetHeight', 'InnerText', 'GetOuterText', 'Focus', 'Blur', 'Click'],
|
||||
'canGc': ['Focus', 'Blur', 'Click', 'SetInnerText', 'SetOuterText', "SetTranslate", 'SetAutofocus', 'GetOffsetParent', 'OffsetTop', 'OffsetLeft', 'OffsetWidth', 'OffsetHeight', 'InnerText', 'GetOuterText'],
|
||||
},
|
||||
|
||||
'HTMLFieldSetElement': {
|
||||
'canGc': ['CheckValidity', 'ReportValidity'],
|
||||
},
|
||||
|
||||
'HTMLDialogElement': {
|
||||
'canGc': ['Show'],
|
||||
},
|
||||
|
||||
'HTMLFormElement': {
|
||||
'canGc': ['CheckValidity', 'RequestSubmit', 'ReportValidity', 'Submit'],
|
||||
'canGc': ['CheckValidity', 'RequestSubmit', 'ReportValidity', 'Submit', 'Reset', 'SetRel'],
|
||||
},
|
||||
|
||||
'HTMLImageElement': {
|
||||
'canGc': ['Width', 'Height', 'Decode'],
|
||||
'canGc': ['RequestSubmit', 'ReportValidity', 'Reset','SetRel', 'Width', 'Height', 'Decode', 'SetCrossOrigin', 'SetWidth', 'SetHeight', 'SetReferrerPolicy'],
|
||||
},
|
||||
|
||||
'HTMLFontElement': {
|
||||
'canGc': ['SetSize']
|
||||
},
|
||||
|
||||
'HTMLInputElement': {
|
||||
'canGc': ['CheckValidity', 'ReportValidity', 'SelectFiles'],
|
||||
'canGc': ['ReportValidity', 'SetValue', 'SetValueAsNumber', 'SetValueAsDate', 'StepUp', 'StepDown', 'CheckValidity', 'ReportValidity', 'SelectFiles'],
|
||||
},
|
||||
|
||||
"HTMLAreaElement": {
|
||||
"canGc": ["SetRel"]
|
||||
},
|
||||
|
||||
"HTMLBodyElement": {
|
||||
"canGc": ["SetBackground"]
|
||||
},
|
||||
|
||||
'HTMLMediaElement': {
|
||||
'canGc': ['Load', 'Pause', 'Play', 'SetSrcObject'],
|
||||
'canGc': ['Load', 'Pause', 'Play', 'SetSrcObject', 'SetCrossOrigin'],
|
||||
'inRealms': ['Play'],
|
||||
},
|
||||
|
||||
|
@ -217,7 +257,11 @@ DOMInterfaces = {
|
|||
},
|
||||
|
||||
'HTMLOutputElement': {
|
||||
'canGc': ['CheckValidity', 'ReportValidity'],
|
||||
'canGc': ['ReportValidity', 'SetDefaultValue', 'SetValue', 'CheckValidity'],
|
||||
},
|
||||
|
||||
'HTMLMeterElement': {
|
||||
'canGc': ['SetValue', 'SetMin', 'SetMax', 'SetLow', 'SetHigh', 'SetOptimum', 'CheckValidity', 'ReportValidity']
|
||||
},
|
||||
|
||||
'HTMLCanvasElement': {
|
||||
|
@ -225,15 +269,55 @@ DOMInterfaces = {
|
|||
},
|
||||
|
||||
'HTMLSelectElement': {
|
||||
'canGc': ['CheckValidity', 'ReportValidity'],
|
||||
'canGc': ['ReportValidity', 'SetLength', 'IndexedSetter', 'CheckValidity'],
|
||||
},
|
||||
|
||||
'HTMLTemplateElement': {
|
||||
'canGc': ['Content'],
|
||||
},
|
||||
|
||||
'HTMLTitleElement': {
|
||||
'canGc': ['SetText']
|
||||
},
|
||||
|
||||
'HTMLTextAreaElement': {
|
||||
'canGc': ['CheckValidity', 'ReportValidity'],
|
||||
'canGc': ['ReportValidity', 'SetDefaultValue', 'CheckValidity'],
|
||||
},
|
||||
|
||||
'HTMLTableElement': {
|
||||
'canGc': ['CreateCaption', 'CreateTBody', 'InsertRow', 'InsertCell', 'InsertRow', 'CreateTHead', 'CreateTFoot']
|
||||
},
|
||||
|
||||
'HTMLTableRowElement': {
|
||||
'canGc': ['InsertCell']
|
||||
},
|
||||
|
||||
'HTMLTableSectionElement': {
|
||||
'canGc': ['InsertRow']
|
||||
},
|
||||
|
||||
'HTMLOptionsCollection': {
|
||||
'canGc': ['IndexedSetter', 'SetLength']
|
||||
},
|
||||
|
||||
'HTMLOptionElement': {
|
||||
'canGc': ['SetText']
|
||||
},
|
||||
|
||||
'HTMLProgressElement': {
|
||||
'canGc': ['SetValue', 'SetMax']
|
||||
},
|
||||
|
||||
'HTMLScriptElement': {
|
||||
'canGc': ['SetAsync', 'SetCrossOrigin', 'SetText']
|
||||
},
|
||||
|
||||
"HTMLAnchorElement": {
|
||||
"canGc": ["SetText","SetRel","SetHref", 'SetHash', 'SetHost', 'SetHostname', 'SetPassword', 'SetPathname', 'SetPort', 'SetProtocol', 'SetSearch', 'SetUsername']
|
||||
},
|
||||
|
||||
'HTMLLinkElement': {
|
||||
'canGc': ['SetRel', 'SetCrossOrigin'],
|
||||
},
|
||||
|
||||
'Location': {
|
||||
|
@ -275,7 +359,7 @@ DOMInterfaces = {
|
|||
},
|
||||
|
||||
'Node': {
|
||||
'canGc': ['CloneNode'],
|
||||
'canGc': ['CloneNode', 'SetTextContent'],
|
||||
},
|
||||
|
||||
'OfflineAudioContext': {
|
||||
|
@ -313,7 +397,7 @@ DOMInterfaces = {
|
|||
},
|
||||
|
||||
'Range': {
|
||||
'canGc': ['CloneContents', 'CloneRange', 'CreateContextualFragment', 'ExtractContents', 'SurroundContents'],
|
||||
'canGc': ['CloneContents', 'CloneRange', 'CreateContextualFragment', 'ExtractContents', 'SurroundContents', 'InsertNode'],
|
||||
'weakReferenceable': True,
|
||||
},
|
||||
|
||||
|
@ -348,6 +432,10 @@ DOMInterfaces = {
|
|||
'canGc': ['Encrypt', 'Decrypt', 'GenerateKey', 'ImportKey', 'ExportKey'],
|
||||
},
|
||||
|
||||
'SVGElement': {
|
||||
'canGc': ['SetAutofocus']
|
||||
},
|
||||
|
||||
#FIXME(jdm): This should be 'register': False, but then we don't generate enum types
|
||||
'TestBinding': {
|
||||
'inRealms': ['PromiseAttribute', 'PromiseNativeHandler'],
|
||||
|
@ -359,6 +447,10 @@ DOMInterfaces = {
|
|||
'canGc': ['AddModule'],
|
||||
},
|
||||
|
||||
'Text': {
|
||||
'canGc': ['SplitText']
|
||||
},
|
||||
|
||||
'URL': {
|
||||
'weakReferenceable': True,
|
||||
'canGc': ['Parse', 'SearchParams'],
|
||||
|
|
|
@ -6239,6 +6239,7 @@ let global = GlobalScope::from_object(JS_CALLEE(*cx, vp).to_object());
|
|||
&global,
|
||||
PrototypeList::ID::{MakeNativeName(self.descriptor.name)},
|
||||
CreateInterfaceObjects,
|
||||
CanGc::note()
|
||||
)
|
||||
"""
|
||||
else:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue