(BaseEvent, proto2)
| 10054 | }; |
| 10055 | } |
| 10056 | function defineWrapper(BaseEvent, proto2) { |
| 10057 | const keys = Object.keys(proto2); |
| 10058 | if (keys.length === 0) { |
| 10059 | return BaseEvent; |
| 10060 | } |
| 10061 | function CustomEvent(eventTarget, event) { |
| 10062 | BaseEvent.call(this, eventTarget, event); |
| 10063 | } |
| 10064 | CustomEvent.prototype = Object.create(BaseEvent.prototype, { |
| 10065 | constructor: { value: CustomEvent, configurable: true, writable: true } |
| 10066 | }); |
| 10067 | for (let i3 = 0; i3 < keys.length; ++i3) { |
| 10068 | const key = keys[i3]; |
| 10069 | if (!(key in BaseEvent.prototype)) { |
| 10070 | const descriptor = Object.getOwnPropertyDescriptor(proto2, key); |
| 10071 | const isFunc = typeof descriptor.value === "function"; |
| 10072 | Object.defineProperty( |
| 10073 | CustomEvent.prototype, |
| 10074 | key, |
| 10075 | isFunc ? defineCallDescriptor(key) : defineRedirectDescriptor(key) |
| 10076 | ); |
| 10077 | } |
| 10078 | } |
| 10079 | return CustomEvent; |
| 10080 | } |
| 10081 | function getWrapper(proto2) { |
| 10082 | if (proto2 == null || proto2 === Object.prototype) { |
| 10083 | return Event2; |
no test coverage detected
searching dependent graphs…