LibWeb: Remove the NoInstanceWrapper extended IDL attribute
No interfaces require wrappers anymore, so we can just make this the default mode.
This commit is contained in:
parent
1bd4ad8b6d
commit
8f110e0fb1
Notes:
sideshowbarker
2024-07-17 07:23:51 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/8f110e0fb1 Pull-request: https://github.com/SerenityOS/serenity/pull/14816 Reviewed-by: https://github.com/ADKaster Reviewed-by: https://github.com/linusg ✅
31 changed files with 32 additions and 35 deletions
|
@ -570,11 +570,8 @@ void Parser::parse_interface(Interface& interface)
|
|||
parse_function(extended_attributes, interface);
|
||||
}
|
||||
|
||||
if (interface.extended_attributes.contains("NoInstanceWrapper")) {
|
||||
interface.wrapper_class = interface.name;
|
||||
} else {
|
||||
interface.wrapper_class = String::formatted("{}Wrapper", interface.name);
|
||||
}
|
||||
interface.wrapper_class = interface.name;
|
||||
|
||||
interface.wrapper_base_class = String::formatted("{}Wrapper", interface.parent_name.is_empty() ? String::empty() : interface.parent_name);
|
||||
interface.constructor_class = String::formatted("{}Constructor", interface.name);
|
||||
interface.prototype_class = String::formatted("{}Prototype", interface.name);
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <CSS/CSSGroupingRule.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface CSSConditionRule : CSSGroupingRule {
|
||||
attribute CSSOMString conditionText;
|
||||
};
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#import <CSS/CSSRule.idl>
|
||||
#import <CSS/CSSStyleDeclaration.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface CSSFontFaceRule : CSSRule {
|
||||
readonly attribute CSSStyleDeclaration style;
|
||||
};
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#import <CSS/CSSRule.idl>
|
||||
#import <CSS/CSSRuleList.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface CSSGroupingRule : CSSRule {
|
||||
[SameObject, ImplementedAs=css_rules_for_bindings] readonly attribute CSSRuleList cssRules;
|
||||
unsigned long insertRule(CSSOMString rule, optional unsigned long index = 0);
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
#import <CSS/CSSStyleSheet.idl>
|
||||
#import <CSS/MediaList.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface CSSImportRule : CSSRule {
|
||||
readonly attribute USVString href;
|
||||
// [SameObject, PutForwards=mediaText] readonly attribute MediaList media;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#import <CSS/CSSConditionRule.idl>
|
||||
#import <CSS/MediaList.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface CSSMediaRule : CSSConditionRule {
|
||||
[SameObject, PutForwards=mediaText] readonly attribute MediaList media;
|
||||
};
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <CSS/CSSStyleSheet.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface CSSRule {
|
||||
|
||||
attribute CSSOMString cssText;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <CSS/CSSRule.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface CSSRuleList {
|
||||
|
||||
getter CSSRule? item(unsigned long index);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
[NoInstanceWrapper]
|
||||
[]
|
||||
interface CSSStyleDeclaration {
|
||||
|
||||
readonly attribute unsigned long length;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#import <CSS/CSSRule.idl>
|
||||
#import <CSS/CSSStyleDeclaration.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface CSSStyleRule : CSSRule {
|
||||
|
||||
attribute CSSOMString selectorText;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#import <CSS/CSSConditionRule.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface CSSSupportsRule : CSSConditionRule {
|
||||
};
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface MediaList {
|
||||
[LegacyNullToEmptyString] stringifier attribute CSSOMString mediaText;
|
||||
readonly attribute unsigned long length;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <DOM/Event.idl>
|
||||
|
||||
[NoInstanceWrapper]
|
||||
[]
|
||||
interface MediaQueryListEvent : Event {
|
||||
constructor(CSSOMString type, optional MediaQueryListEventInit eventInitDict = {});
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <CSS/CSSStyleSheet.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface StyleSheetList {
|
||||
getter CSSStyleSheet? item(unsigned long index);
|
||||
readonly attribute unsigned long length;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface AbstractRange {
|
||||
readonly attribute Node startContainer;
|
||||
readonly attribute unsigned long startOffset;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <DOM/Event.idl>
|
||||
|
||||
[Exposed=(Window,Worker), NoInstanceWrapper]
|
||||
[Exposed=(Window,Worker)]
|
||||
interface CustomEvent : Event {
|
||||
constructor(DOMString type, optional CustomEventInit eventInitDict = {});
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
[NoInstanceWrapper]
|
||||
[]
|
||||
interface DOMTokenList {
|
||||
readonly attribute unsigned long length;
|
||||
getter DOMString? item(unsigned long index);
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <DOM/EventTarget.idl>
|
||||
|
||||
[NoInstanceWrapper]
|
||||
[]
|
||||
interface Event {
|
||||
|
||||
constructor(DOMString type, optional EventInit eventInitDict = {});
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <DOM/Attribute.idl>
|
||||
|
||||
[Exposed=Window, LegacyUnenumerableNamedProperties, NoInstanceWrapper]
|
||||
[Exposed=Window, LegacyUnenumerableNamedProperties]
|
||||
interface NamedNodeMap {
|
||||
readonly attribute unsigned long length;
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#import <DOM/Node.idl>
|
||||
#import <DOM/NodeFilter.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface NodeIterator {
|
||||
|
||||
[SameObject] readonly attribute Node root;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#import <DOM/Node.idl>
|
||||
#import <DOM/AbstractRange.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface Range : AbstractRange {
|
||||
|
||||
constructor();
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#import <DOM/Node.idl>
|
||||
#import <DOM/AbstractRange.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface StaticRange : AbstractRange {
|
||||
constructor(StaticRangeInit init);
|
||||
};
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#import <DOM/Node.idl>
|
||||
#import <DOM/NodeFilter.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface TreeWalker {
|
||||
|
||||
[SameObject] readonly attribute Node root;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <DOM/Event.idl>
|
||||
|
||||
[NoInstanceWrapper]
|
||||
[]
|
||||
interface CloseEvent : Event {
|
||||
constructor(DOMString type, optional CloseEventInit eventInitDict = {});
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <DOM/Event.idl>
|
||||
|
||||
[NoInstanceWrapper]
|
||||
[]
|
||||
interface MessageEvent : Event {
|
||||
constructor(DOMString type, optional MessageEventInit eventInitDict = {});
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <DOM/Event.idl>
|
||||
|
||||
[Exposed=(Window,Worker), NoInstanceWrapper]
|
||||
[Exposed=(Window,Worker)]
|
||||
interface PromiseRejectionEvent : Event {
|
||||
constructor(DOMString type, PromiseRejectionEventInit eventInitDict);
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#import <DOM/Event.idl>
|
||||
#import <HTML/HTMLElement.idl>
|
||||
|
||||
[NoInstanceWrapper]
|
||||
[]
|
||||
interface SubmitEvent : Event {
|
||||
constructor(DOMString type, optional SubmitEventInit eventInitDict = {});
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <UIEvents/UIEvent.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface FocusEvent : UIEvent {
|
||||
|
||||
constructor(DOMString type, optional FocusEventInit eventInitDict = {});
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <UIEvents/EventModifier.idl>
|
||||
|
||||
[Exposed=Window, NoInstanceWrapper]
|
||||
[Exposed=Window]
|
||||
interface KeyboardEvent : UIEvent {
|
||||
|
||||
constructor(DOMString type, optional KeyboardEventInit eventInitDict = {});
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <DOM/Event.idl>
|
||||
|
||||
[NoInstanceWrapper]
|
||||
[]
|
||||
interface UIEvent : Event {
|
||||
constructor(DOMString type, optional UIEventInit eventInitDict = {});
|
||||
readonly attribute Window? view;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#import <DOM/Event.idl>
|
||||
|
||||
[NoInstanceWrapper]
|
||||
[]
|
||||
interface ProgressEvent : Event {
|
||||
constructor(DOMString type, optional ProgressEventInit eventInitDict = {});
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue