Files
discord-decomp/_bundle/LegacySyntheticEvent.js
T
2026-11-01 12:12:55 +02:00

96 lines
2.7 KiB
JavaScript

// Metro module 286 (f287).
import _classCallCheck from "./_classCallCheck";
import _createClass from "./_createClass";
import _possibleConstructorReturn from "./_possibleConstructorReturn";
import _getPrototypeOf from "./_getPrototypeOf";
import _get from "./_get";
import _inherits from "./_inherits";
import Event2 from "./Event";
function $mk65898($env) {
return function(a0) {
const r0 = $env;
return r0[1].apply(r0[0], a0);
};
}
let LegacySyntheticEvent;
let env296 = {};
env296[4] = function _isNativeReflectConstruct() {
let c12229_0;
try {
c12229_0 = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
} catch ($e) {}
const _isNativeReflectConstruct2 = function _isNativeReflectConstruct() {
return !!c12229_0;
};
env296[4] = _isNativeReflectConstruct2;
return _isNativeReflectConstruct2();
};
LegacySyntheticEvent = function LegacySyntheticEvent(a0, a1, a2, a3) {
_classCallCheck(this, LegacySyntheticEvent);
const r8 = [a0, a1];
const r7 = _getPrototypeOf(LegacySyntheticEvent);
const r17 = (0, env296[4])() ? Reflect.construct(r7, r8, _getPrototypeOf(this).constructor) : r7.apply(this, r8);
let _dispatchConfig = a3;
const r24 = _possibleConstructorReturn(this, r17);
r24._nativeEvent = a2;
r24._propagationStopped = false;
if (a3 == null) {
_dispatchConfig = null;
}
r24._dispatchConfig = _dispatchConfig;
return r24;
};
_inherits(LegacySyntheticEvent, Event2);
export default _createClass(LegacySyntheticEvent, [{
key: "nativeEvent",
get: function get() {
return this._nativeEvent;
}
}, {
key: "dispatchConfig",
get: function get() {
return this._dispatchConfig;
}
}, {
key: "stopPropagation",
value: function stopPropagation() {
let env23630;
const r7 = env23630 = {};
env23630[0] = this;
let r12 = _get(_getPrototypeOf(LegacySyntheticEvent.prototype), "stopPropagation", this);
env23630[1] = r12;
if (typeof r12 === "function") {
r12 = $mk65898(r7);
}
r12([]);
this._propagationStopped = true;
}
}, {
key: "stopImmediatePropagation",
value: function stopImmediatePropagation() {
let env23631;
const r7 = env23631 = {};
env23631[0] = this;
let r12 = _get(_getPrototypeOf(LegacySyntheticEvent.prototype), "stopImmediatePropagation", this);
env23631[1] = r12;
if (typeof r12 === "function") {
r12 = $mk65898(r7);
}
r12([]);
this._propagationStopped = true;
}
}, {
key: "persist",
value: function persist() {}
}, {
key: "isDefaultPrevented",
value: function isDefaultPrevented() {
return this.defaultPrevented;
}
}, {
key: "isPropagationStopped",
value: function isPropagationStopped() {
return this._propagationStopped;
}
}]);