2503 lines
94 KiB
React
2503 lines
94 KiB
React
/* Metro module 1097; source: unknown; dependencies: [5, 57, 29, 65, 6, 7, 826] */
|
|
function _fun12158(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#12158, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:6, offset: 0x00dc261d, size: 1153 bytes, params: 8, frame: 30
|
|
var r13;
|
|
var items;
|
|
var from;
|
|
var Proxy;
|
|
var Reflect;
|
|
var prototype;
|
|
var uint8Array;
|
|
var charCodeAt;
|
|
var value8;
|
|
var Array;
|
|
var closure;
|
|
var value11;
|
|
var property;
|
|
var value12;
|
|
var document;
|
|
var createElement;
|
|
var element;
|
|
var body;
|
|
var appendChild;
|
|
var contentWindow;
|
|
var value13;
|
|
var Array2;
|
|
var Array3;
|
|
var removeChild;
|
|
var error;
|
|
var console;
|
|
var debug;
|
|
var value14;
|
|
var value15;
|
|
var value16;
|
|
var defineIntegration;
|
|
let value = undefined;
|
|
const createMatchPredicate_12160 = function(a0, a1) {
|
|
var env0_0 = a0;
|
|
var env0_1 = a1;
|
|
return _fun12161;
|
|
};
|
|
const hookSetter_12162 = function(a0, a1, a2, a3) {
|
|
var r1;
|
|
var property;
|
|
var value = a2;
|
|
var env0_0 = a0;
|
|
var env0_1 = a1;
|
|
var env0_2 = value;
|
|
r1 = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : global.window;
|
|
var env0_3 = r1.Object.getOwnPropertyDescriptor(a0, a1);
|
|
property = r1.Object;
|
|
property.defineProperty(a0, a1, a3 ? value : {set: _fun12163});
|
|
return _fun12165;
|
|
};
|
|
const patchGLPrototype = function(a0, a1, a2, a3, a4, a5, a6, a7) {
|
|
var error;
|
|
var env0_0 = a0;
|
|
var env0_1 = a1;
|
|
var env0_2 = a2;
|
|
var env0_3 = a3;
|
|
var env0_4 = a4;
|
|
var env0_5 = a5;
|
|
var env0_6 = a7;
|
|
var items = [];
|
|
var env0_7 = items;
|
|
var Object = global.Object;
|
|
var value = Object.getOwnPropertyNames(a0);
|
|
var closure = _fun12182;
|
|
var iterator = value[Symbol.iterator]();
|
|
var iterator2 = iterator.next;
|
|
var r2 = iterator;
|
|
var item2 = Reflect.apply(iterator2, r2, []);
|
|
var item = item2.value;
|
|
item2 = item2.done ? undefined : r2;
|
|
reducibleJoin2: while (true) {
|
|
if (item2 === undefined) {
|
|
return items;
|
|
}
|
|
break reducibleJoin2;
|
|
}
|
|
reducibleLoop2: while (true) {
|
|
try {
|
|
closure(item);
|
|
} catch (error) {
|
|
try {
|
|
item2.return();
|
|
} catch {
|
|
}
|
|
throw error;
|
|
}
|
|
r2 = item2;
|
|
item2 = Reflect.apply(iterator2, r2, []);
|
|
item = item2.value;
|
|
item2 = item2.done ? undefined : r2;
|
|
if (item2 === undefined) {
|
|
break reducibleLoop2;
|
|
}
|
|
continue reducibleLoop2;
|
|
}
|
|
return items;
|
|
};
|
|
const value2 = 0;
|
|
let env0_0 = require(dependencyMap[value2]);
|
|
let env0_1 = require(57) /* metro dependency 57 */;
|
|
let env0_2 = require(29) /* metro dependency 29 */;
|
|
let env0_3 = require(65) /* metro dependency 65 */;
|
|
let env0_4 = require(6) /* metro dependency 6 */;
|
|
let env0_5 = require(7) /* metro dependency 7 */;
|
|
let env0_6 = ['type'];
|
|
let Object = global.Object;
|
|
let defineProperty = Object.defineProperty;
|
|
const Symbol = global.Symbol;
|
|
Reflect.apply(defineProperty, Object, [exports, Symbol.toStringTag, {value: 'Module'}]);
|
|
Object = global.Object;
|
|
defineProperty = Object.defineProperty;
|
|
const value3 = _fun12187();
|
|
object = {map: {}, getId: function() {
|
|
global.console.error('Please stop import mirror directly. Instead of that,\r\nnow you can use replayer.getMirror() to access the mirror instance of a replayer,\r\nor you can use record.mirror to access the mirror instance during recording.');
|
|
return -1;
|
|
}, getNode: function() {
|
|
global.console.error('Please stop import mirror directly. Instead of that,\r\nnow you can use replayer.getMirror() to access the mirror instance of a replayer,\r\nor you can use record.mirror to access the mirror instance during recording.');
|
|
return null;
|
|
}, removeNodeFromMap: function() {
|
|
global.console.error('Please stop import mirror directly. Instead of that,\r\nnow you can use replayer.getMirror() to access the mirror instance of a replayer,\r\nor you can use record.mirror to access the mirror instance during recording.');
|
|
}, has: function() {
|
|
global.console.error('Please stop import mirror directly. Instead of that,\r\nnow you can use replayer.getMirror() to access the mirror instance of a replayer,\r\nor you can use record.mirror to access the mirror instance during recording.');
|
|
return false;
|
|
}, reset: function() {
|
|
global.console.error('Please stop import mirror directly. Instead of that,\r\nnow you can use replayer.getMirror() to access the mirror instance of a replayer,\r\nor you can use record.mirror to access the mirror instance during recording.');
|
|
}};
|
|
let window = global.window;
|
|
const value4 = typeof window !== 'undefined';
|
|
reducibleJoin2: while (true) {
|
|
if (value4) {
|
|
window = global.window;
|
|
Proxy = window.Proxy;
|
|
r13 = Proxy;
|
|
break reducibleJoin2;
|
|
}
|
|
r13 = value4;
|
|
break reducibleJoin2;
|
|
}
|
|
reducibleJoin4: while (true) {
|
|
if (r13) {
|
|
window = global.window;
|
|
Reflect = window.Reflect;
|
|
r13 = Reflect;
|
|
break reducibleJoin4;
|
|
}
|
|
break reducibleJoin4;
|
|
}
|
|
reducibleJoin6: while (true) {
|
|
if (r13) {
|
|
Proxy = global.Proxy;
|
|
prototype = Proxy.prototype;
|
|
Object.create(prototype, {constructor: {value: Proxy}});
|
|
new Proxy(object, {get: function(a0, a1, a2) {
|
|
if (a1 === 'map') {
|
|
global.console.error('Please stop import mirror directly. Instead of that,\r\nnow you can use replayer.getMirror() to access the mirror instance of a replayer,\r\nor you can use record.mirror to access the mirror instance during recording.');
|
|
}
|
|
return global.Reflect.get(a0, a1, a2);
|
|
}});
|
|
break reducibleJoin6;
|
|
}
|
|
break reducibleJoin6;
|
|
}
|
|
const Date = global.Date;
|
|
Date.now().toString();
|
|
const env0_9 = {};
|
|
object = {};
|
|
object['2D'] = value2;
|
|
object[value2] = '2D';
|
|
object.WebGL = 1;
|
|
object[1] = 'WebGL';
|
|
object.WebGL2 = 2;
|
|
object[2] = 'WebGL2';
|
|
const Uint8Array = global.Uint8Array;
|
|
if (typeof Uint8Array === 'undefined') {
|
|
items = [];
|
|
} else {
|
|
uint8Array = new global.Uint8Array(256);
|
|
}
|
|
r13 = value2;
|
|
reducibleLoop10: while (true) {
|
|
charCodeAt = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'.charCodeAt;
|
|
items[Reflect.apply(charCodeAt, 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/',
|
|
[r13])] = r13;
|
|
value8 = typeof r13 === 'bigint' ? r13 + 1n : +r13 + 1;
|
|
if (value8 < 64) {
|
|
r13 = value8;
|
|
continue reducibleLoop10;
|
|
}
|
|
break reducibleLoop10;
|
|
}
|
|
const Map = global.Map;
|
|
const map = new Map();
|
|
const serializeArgs = function(a0, a1, a2) {
|
|
var env0_0 = a1;
|
|
var env0_1 = a2;
|
|
return a0.map(_fun12211);
|
|
};
|
|
const isInstanceOfWebGLObject = function(a0, a1) {
|
|
var env0_0 = a0;
|
|
var env0_1 = a1;
|
|
var value = ['WebGLActiveInfo', 'WebGLBuffer', 'WebGLFramebuffer', 'WebGLProgram', 'WebGLRenderbuffer',
|
|
'WebGLShader', 'WebGLShaderPrecisionFormat', 'WebGLTexture', 'WebGLUniformLocation',
|
|
'WebGLVertexArrayObject',
|
|
'WebGLVertexArrayObjectOES'].filter(_fun12213);
|
|
var Boolean = global.Boolean;
|
|
value = value.find(_fun12214);
|
|
return Boolean(value);
|
|
};
|
|
const env0_18 = _fun12215();
|
|
reducibleJoin13: while (true) {
|
|
reduciblePort44: while (true) {
|
|
exceptionLanding43: while (true) {
|
|
try {
|
|
Array = global.Array;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
break reducibleJoin13;
|
|
}
|
|
console = global.console;
|
|
debug = console.debug;
|
|
Reflect.apply(debug, console, ['Unable to override Array.from', error]);
|
|
break reduciblePort44;
|
|
}
|
|
prototype = value3.prototype;
|
|
value14 = Object.create(prototype, {constructor: {value: value3}});
|
|
value15 = new value3();
|
|
value15 instanceof Object ? value15 : value14;
|
|
object = {NotStarted: value2};
|
|
object[value2] = 'NotStarted';
|
|
object.Running = 1;
|
|
object[1] = 'Running';
|
|
object.Stopped = 2;
|
|
object[2] = 'Stopped';
|
|
object = {};
|
|
object.low = {sampling: {canvas: 1}, dataURLOptions: {'type': 'image/webp', 'quality': 0.25}};
|
|
object.medium = {sampling: {canvas: 2}, dataURLOptions: {'type': 'image/webp', 'quality': 0.4}};
|
|
object.high = {sampling: {canvas: 4}, dataURLOptions: {'type': 'image/webp', 'quality': 0.5}};
|
|
var env0_19 = object;
|
|
var env0_20 = 1280;
|
|
value16 = require(826) /* metro dependency 826 */;
|
|
defineIntegration = value16.defineIntegration;
|
|
exports.replayCanvasIntegration = Reflect.apply(defineIntegration, value16, [_replayCanvasIntegration]);
|
|
return value;
|
|
}
|
|
try {
|
|
from = Array.from;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
object = [1];
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
closure = function(a0) {
|
|
return 2 * a0;
|
|
};
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
value11 = Reflect.apply(from, Array, [object, closure]);
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
property = value11[value2];
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
value12 = property === 2;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
reducibleJoin44: while (true) {
|
|
if (value12) {
|
|
break reducibleJoin44;
|
|
}
|
|
try {
|
|
document = global.document;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
createElement = document.createElement;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
element = Reflect.apply(createElement, document, ['iframe']);
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
document = global.document;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
body = document.body;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
appendChild = body.appendChild;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
Reflect.apply(appendChild, body, [element]);
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
Array = global.Array;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
contentWindow = element.contentWindow;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
value13 = contentWindow == null;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
reducibleJoin35: while (true) {
|
|
if (value13) {
|
|
from = value;
|
|
break reducibleJoin35;
|
|
}
|
|
try {
|
|
Array2 = contentWindow.Array;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
from = Array2.from;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
break reducibleJoin35;
|
|
}
|
|
reducibleJoin38: while (true) {
|
|
if (from) {
|
|
r13 = from;
|
|
break reducibleJoin38;
|
|
}
|
|
try {
|
|
Array3 = global.Array;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
from = Array3.from;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
r13 = from;
|
|
break reducibleJoin38;
|
|
}
|
|
try {
|
|
Array.from = r13;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
document = global.document;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
body = document.body;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
removeChild = body.removeChild;
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
try {
|
|
Reflect.apply(removeChild, body, [element]);
|
|
} catch (error) {
|
|
break exceptionLanding43;
|
|
}
|
|
break reducibleJoin44;
|
|
}
|
|
value14 = Object.create(value3.prototype, {constructor: {value: value3}});
|
|
value15 = new value3();
|
|
value15 instanceof Object ? value15 : value14;
|
|
object = {NotStarted: value2};
|
|
object[value2] = 'NotStarted';
|
|
object.Running = 1;
|
|
object[1] = 'Running';
|
|
object.Stopped = 2;
|
|
object[2] = 'Stopped';
|
|
object = {};
|
|
object.low = {sampling: {canvas: 1}, dataURLOptions: {'type': 'image/webp', 'quality': 0.25}};
|
|
object.medium = {sampling: {canvas: 2}, dataURLOptions: {'type': 'image/webp', 'quality': 0.4}};
|
|
object.high = {sampling: {canvas: 4}, dataURLOptions: {'type': 'image/webp', 'quality': 0.5}};
|
|
exports.replayCanvasIntegration = (require(826) /* metro dependency 826 */).defineIntegration(_replayCanvasIntegration);
|
|
return value;
|
|
}
|
|
|
|
function distanceToMatch_12159(a0, a1) { // fn#12159, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:1569, offset: 0x00dc2a9e, size: 172 bytes, params: 3, frame: 21
|
|
let value = Infinity;
|
|
const r6 = arguments.length > 2 ? arguments[2] === undefined ? value : arguments[2] : value;
|
|
value = 0;
|
|
const r9 = arguments.length > 3 ? arguments[3] === undefined ? value : arguments[3] : value;
|
|
value = -1;
|
|
return a0 ? a0.nodeType !== a0.ELEMENT_NODE || r9 > r6 ? value : a1(a0) ? r9 : distanceToMatch_12159(a0.parentNode,
|
|
a1, r6, r9 + 1) : value;
|
|
}
|
|
|
|
function createMatchPredicate_12160(a0, a1) { // fn#12160, offset: 0x00dc2b4a, size: 23 bytes, params: 3, frame: 2
|
|
const env0_0 = a0;
|
|
const env0_1 = a1;
|
|
return _fun12161;
|
|
}
|
|
|
|
function hookSetter_12162(a0, a1, a2, a3) { // fn#12162, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:2656, offset: 0x00dc2b61, size: 124 bytes, params: 5, frame: 18
|
|
const value = a2;
|
|
const env0_0 = a0;
|
|
const env0_1 = a1;
|
|
const r1 = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : global.window;
|
|
let Object = r1.Object;
|
|
const env0_3 = Object.getOwnPropertyDescriptor(a0, a1);
|
|
Object = r1.Object;
|
|
Object.defineProperty(a0, a1, a3 ? value : {set: set_12163});
|
|
return _fun12165;
|
|
}
|
|
|
|
function patch_12166(a0, a1, a2) { // fn#12166, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:2987, offset: 0x00dc2c5c, size: 171 bytes, params: 4, frame: 20
|
|
var r4;
|
|
var value;
|
|
var property;
|
|
var value2;
|
|
var prototype;
|
|
var Object;
|
|
var error;
|
|
const env0_0 = a0;
|
|
const env0_1 = a1;
|
|
try {
|
|
value = a1 in a0;
|
|
} catch (error) {
|
|
return function() {
|
|
};
|
|
}
|
|
if (value) {
|
|
try {
|
|
property = a0[a1];
|
|
var env0_2 = property;
|
|
value = a2(property);
|
|
value2 = typeof value !== 'function';
|
|
if (!value2) {
|
|
prototype = value.prototype;
|
|
r4 = prototype || ({});
|
|
value.prototype = r4;
|
|
Object = global.Object;
|
|
Object.defineProperties(value, {__rrweb_original__: {enumerable: false, value: property}});
|
|
}
|
|
a0[a1] = value;
|
|
} catch (error) {
|
|
return function() {
|
|
};
|
|
}
|
|
return _fun12168;
|
|
}
|
|
return function() {
|
|
};
|
|
}
|
|
|
|
function isBlocked_12170(a0, a1, a2, a3, a4) { // fn#12170, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:3250, offset: 0x00dc2d07, size: 170 bytes, params: 6, frame: 20
|
|
var r0;
|
|
var r8;
|
|
var r2;
|
|
var r1;
|
|
var value2;
|
|
var nodeType;
|
|
var ELEMENT_NODE;
|
|
var value3;
|
|
var parentElement;
|
|
var error;
|
|
var value4;
|
|
var value5;
|
|
var value7;
|
|
const value = a0;
|
|
if (value) {
|
|
value2 = null;
|
|
if (value) {
|
|
try {
|
|
nodeType = value.nodeType;
|
|
ELEMENT_NODE = value.ELEMENT_NODE;
|
|
value3 = nodeType === ELEMENT_NODE;
|
|
if (value3) {
|
|
r0 = value;
|
|
} else {
|
|
parentElement = value.parentElement;
|
|
r0 = parentElement;
|
|
}
|
|
r8 = r0;
|
|
} catch (error) {
|
|
r8 = value2;
|
|
}
|
|
} else {
|
|
r8 = value2;
|
|
}
|
|
if (r8) {
|
|
value4 = distanceToMatch_12159(r8, createMatchPredicate_12160(a1, a2));
|
|
value5 = value4 < 0;
|
|
if (value5) {
|
|
r0 = !value5;
|
|
} else {
|
|
value7 = -1;
|
|
r2 = a3 ? distanceToMatch_12159(r8, createMatchPredicate_12160(value2, a3)) : value7;
|
|
r1 = value4 > value7 && r2 < 0;
|
|
r1 = !r1 ? value4 < r2 : r1;
|
|
r0 = r1;
|
|
}
|
|
return r0;
|
|
}
|
|
}
|
|
return false;
|
|
}
|
|
|
|
function getImplementation_12171(a0) { // fn#12171, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:3831, offset: 0x00dc2db1, size: 223 bytes, params: 2, frame: 19
|
|
var r8;
|
|
var r4;
|
|
var createElement;
|
|
var element;
|
|
var head;
|
|
var appendChild;
|
|
var contentWindow;
|
|
var property2;
|
|
var removeChild;
|
|
var error;
|
|
var binding;
|
|
var bind;
|
|
let value = environment;
|
|
let property = env0_9[a0];
|
|
if (property) {
|
|
return property;
|
|
}
|
|
let window = global.window;
|
|
const document = window.document;
|
|
property = global.window[a0];
|
|
if (document) {
|
|
createElement = document.createElement;
|
|
if (typeof createElement !== 'function') {
|
|
r4 = property;
|
|
} else {
|
|
try {
|
|
createElement = document.createElement;
|
|
} catch (error) {
|
|
r4 = property;
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
element = Reflect.apply(createElement, document, ['iframe']);
|
|
} catch (error) {
|
|
r4 = property;
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
element.hidden = true;
|
|
} catch (error) {
|
|
r4 = property;
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
head = document.head;
|
|
} catch (error) {
|
|
r4 = property;
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
appendChild = head.appendChild;
|
|
} catch (error) {
|
|
r4 = property;
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
Reflect.apply(appendChild, head, [element]);
|
|
} catch (error) {
|
|
r4 = property;
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
contentWindow = element.contentWindow;
|
|
} catch (error) {
|
|
r4 = property;
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
if (contentWindow) {
|
|
try {
|
|
property2 = contentWindow[a0];
|
|
r8 = property2;
|
|
} catch (error) {
|
|
r4 = property;
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
if (r8) {
|
|
try {
|
|
property = contentWindow[a0];
|
|
r4 = property;
|
|
} catch (error) {
|
|
r4 = property;
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
head = document.head;
|
|
} catch (error) {
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
removeChild = head.removeChild;
|
|
} catch (error) {
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
Reflect.apply(removeChild, head, [element]);
|
|
} catch (error) {
|
|
}
|
|
} else {
|
|
r4 = property;
|
|
try {
|
|
head = document.head;
|
|
} catch (error) {
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
removeChild = head.removeChild;
|
|
} catch (error) {
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
Reflect.apply(removeChild, head, [element]);
|
|
} catch (error) {
|
|
}
|
|
}
|
|
} else if (contentWindow) {
|
|
try {
|
|
property = contentWindow[a0];
|
|
r4 = property;
|
|
} catch (error) {
|
|
r4 = property;
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
head = document.head;
|
|
} catch (error) {
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
removeChild = head.removeChild;
|
|
} catch (error) {
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
Reflect.apply(removeChild, head, [element]);
|
|
} catch (error) {
|
|
}
|
|
} else {
|
|
r4 = property;
|
|
try {
|
|
head = document.head;
|
|
} catch (error) {
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
removeChild = head.removeChild;
|
|
} catch (error) {
|
|
binding = env0_9;
|
|
bind = r4.bind;
|
|
window = global.window;
|
|
value = Reflect.apply(bind, r4, [window]);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
try {
|
|
Reflect.apply(removeChild, head, [element]);
|
|
} catch (error) {
|
|
}
|
|
}
|
|
}
|
|
} else {
|
|
r4 = property;
|
|
}
|
|
binding = env0_9;
|
|
value = r4.bind(global.window);
|
|
binding[a0] = value;
|
|
return value;
|
|
}
|
|
|
|
function onRequestAnimationFrame() { // fn#12172, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:4130, offset: 0x00dc2e90, size: 35 bytes, params: 1, frame: 14
|
|
return getImplementation_12171('requestAnimationFrame').apply(undefined, arguments);
|
|
}
|
|
|
|
function setTimeout$1_12173() { // fn#12173, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:4239, offset: 0x00dc2eb3, size: 35 bytes, params: 1, frame: 14
|
|
return getImplementation_12171('setTimeout').apply(undefined, arguments);
|
|
}
|
|
|
|
function serializeArg(a0, a1, a2) { // fn#12174, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:5042, offset: 0x00dc2ed6, size: 925 bytes, params: 4, frame: 33
|
|
var environment;
|
|
var r1;
|
|
var r6;
|
|
var r11;
|
|
var r7;
|
|
var r4;
|
|
var Int32Array;
|
|
var Uint32Array;
|
|
var Uint8Array;
|
|
var Uint16Array;
|
|
var Int16Array;
|
|
var Int8Array;
|
|
var Uint8ClampedArray;
|
|
var ArrayBuffer;
|
|
var DataView;
|
|
var HTMLImageElement;
|
|
var HTMLCanvasElement;
|
|
var ImageData;
|
|
var value2;
|
|
var object2;
|
|
var constructor;
|
|
var name;
|
|
var serializeArgBinding;
|
|
var data;
|
|
var value3;
|
|
var width;
|
|
var height;
|
|
var value4;
|
|
var items2;
|
|
var prototype;
|
|
var value6;
|
|
var uint8Array;
|
|
var length;
|
|
var value7;
|
|
var value8;
|
|
var value9;
|
|
var binding;
|
|
var value10;
|
|
var value11;
|
|
var value12;
|
|
var value13;
|
|
var value14;
|
|
var value15;
|
|
var value16;
|
|
var value17;
|
|
var value18;
|
|
var value19;
|
|
var value20;
|
|
var substring;
|
|
let value = a0;
|
|
const env0_0 = a1;
|
|
const env0_1 = a2;
|
|
const Array = global.Array;
|
|
if (value instanceof Array) {
|
|
return value.map(function(a0) {
|
|
return serializeArg(a0, require, importDefault);
|
|
});
|
|
}
|
|
if (value === null) {
|
|
return value;
|
|
}
|
|
const Float32Array = global.Float32Array;
|
|
if (!(value instanceof Float32Array)) {
|
|
reducibleJoin32: while (true) {
|
|
if (value instanceof global.Float64Array) {
|
|
break reducibleJoin32;
|
|
}
|
|
Int32Array = global.Int32Array;
|
|
if (value instanceof Int32Array) {
|
|
break reducibleJoin32;
|
|
}
|
|
Uint32Array = global.Uint32Array;
|
|
if (value instanceof Uint32Array) {
|
|
break reducibleJoin32;
|
|
}
|
|
Uint8Array = global.Uint8Array;
|
|
if (value instanceof Uint8Array) {
|
|
break reducibleJoin32;
|
|
}
|
|
Uint16Array = global.Uint16Array;
|
|
if (value instanceof Uint16Array) {
|
|
break reducibleJoin32;
|
|
}
|
|
Int16Array = global.Int16Array;
|
|
if (value instanceof Int16Array) {
|
|
break reducibleJoin32;
|
|
}
|
|
Int8Array = global.Int8Array;
|
|
if (value instanceof Int8Array) {
|
|
break reducibleJoin32;
|
|
}
|
|
Uint8ClampedArray = global.Uint8ClampedArray;
|
|
if (!(value instanceof Uint8ClampedArray)) {
|
|
ArrayBuffer = global.ArrayBuffer;
|
|
if (value instanceof ArrayBuffer) {
|
|
object2 = {};
|
|
constructor = value.constructor;
|
|
name = constructor.name;
|
|
object2.rr_type = name;
|
|
Uint8Array = global.Uint8Array;
|
|
prototype = Uint8Array.prototype;
|
|
value6 = Object.create(prototype, {constructor: {value: Uint8Array}});
|
|
uint8Array = new Uint8Array(value);
|
|
value = uint8Array instanceof Object ? uint8Array : value6;
|
|
length = value.length;
|
|
value7 = 0;
|
|
value8 = '';
|
|
value9 = environment;
|
|
if (value7 < length) {
|
|
r6 = value8;
|
|
r11 = value7;
|
|
reducibleLoop26: while (true) {
|
|
binding = env0_13;
|
|
value10 = r6 + binding[value[r11] >> 2];
|
|
binding = env0_13;
|
|
value11 = 3 & value[r11];
|
|
value12 = r11 + 1;
|
|
value13 = value[value12] >> 4;
|
|
value14 = value10 + binding[value11 << 4 | value13];
|
|
binding = env0_13;
|
|
value15 = 15 & value[value12];
|
|
value16 = r11 + 2;
|
|
value17 = value[value16] >> 6;
|
|
value18 = value14 + binding[value15 << 2 | value17];
|
|
binding = env0_13;
|
|
value19 = value18 + binding[63 & value[value16]];
|
|
value20 = r11 + 3;
|
|
if (value20 < length) {
|
|
r6 = value19;
|
|
r11 = value20;
|
|
continue reducibleLoop26;
|
|
}
|
|
r7 = value19;
|
|
break reducibleLoop26;
|
|
}
|
|
} else {
|
|
r7 = value8;
|
|
}
|
|
if (length % 3 === 2) {
|
|
substring = r7.substring;
|
|
length = r7.length;
|
|
value = Reflect.apply(substring, r7, [value7, length - 1]);
|
|
value += '=';
|
|
r4 = value;
|
|
} else {
|
|
reducibleJoin31: while (true) {
|
|
if (length % 3 !== 1) {
|
|
r4 = r7;
|
|
break reducibleJoin31;
|
|
}
|
|
substring = r7.substring;
|
|
length = r7.length;
|
|
value = Reflect.apply(substring, r7, [value7, length - 2]);
|
|
value += '==';
|
|
r4 = value;
|
|
break reducibleJoin31;
|
|
}
|
|
}
|
|
object2.base64 = r4;
|
|
return object2;
|
|
}
|
|
DataView = global.DataView;
|
|
if (value instanceof DataView) {
|
|
object2 = {};
|
|
object2.rr_type = value.constructor.name;
|
|
value4 = environment;
|
|
items2 = [serializeArg(value.buffer, a1, a2)];
|
|
items2[1] = value.byteOffset;
|
|
items2[2] = value.byteLength;
|
|
object2.args = items2;
|
|
return object2;
|
|
}
|
|
HTMLImageElement = global.HTMLImageElement;
|
|
if (value instanceof HTMLImageElement) {
|
|
return {rr_type: value.constructor.name, src: value.src};
|
|
}
|
|
HTMLCanvasElement = global.HTMLCanvasElement;
|
|
if (value instanceof HTMLCanvasElement) {
|
|
return {rr_type: 'HTMLImageElement', src: value.toDataURL()};
|
|
}
|
|
ImageData = global.ImageData;
|
|
value2 = environment;
|
|
if (value instanceof ImageData) {
|
|
object2 = {};
|
|
constructor = value.constructor;
|
|
name = constructor.name;
|
|
object2.rr_type = name;
|
|
serializeArgBinding = serializeArg;
|
|
data = value.data;
|
|
value3 = serializeArgBinding(data, a1, a2);
|
|
width = value.width;
|
|
height = value.height;
|
|
object2.args = [value3, width, height];
|
|
r1 = object2;
|
|
} else {
|
|
reducibleJoin19: while (true) {
|
|
reducibleJoin18: while (true) {
|
|
if (isInstanceOfWebGLObject(value, a1)) {
|
|
break reducibleJoin18;
|
|
}
|
|
if (typeof value !== 'object') {
|
|
r1 = value;
|
|
break reducibleJoin19;
|
|
}
|
|
break reducibleJoin18;
|
|
}
|
|
object2 = {};
|
|
constructor = value.constructor;
|
|
name = constructor.name;
|
|
object2.rr_type = name;
|
|
object2.index = saveWebGLVar(value, a1, a2);
|
|
r1 = object2;
|
|
break reducibleJoin19;
|
|
}
|
|
}
|
|
return r1;
|
|
}
|
|
break reducibleJoin32;
|
|
}
|
|
}
|
|
object2 = {};
|
|
object2.rr_type = value.constructor.name;
|
|
const Object = global.Object;
|
|
value = Object.values(value);
|
|
object2.args = [value];
|
|
return object2;
|
|
}
|
|
|
|
function initCanvasContextObserver(a0, a1, a2, a3, a4) { // fn#12176, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:6746, offset: 0x00dc3293, size: 128 bytes, params: 6, frame: 17
|
|
var environment;
|
|
var value;
|
|
var patch_12166Binding;
|
|
var HTMLCanvasElement;
|
|
var prototype;
|
|
var closure;
|
|
var error;
|
|
var console;
|
|
let env0_0 = a1;
|
|
const env0_1 = a2;
|
|
const env0_2 = a3;
|
|
const env0_3 = a4;
|
|
try {
|
|
value = environment;
|
|
patch_12166Binding = patch_12166;
|
|
HTMLCanvasElement = a0.HTMLCanvasElement;
|
|
prototype = HTMLCanvasElement.prototype;
|
|
closure = function(a0) {
|
|
var env0_0 = a0;
|
|
return _fun12178;
|
|
};
|
|
value = patch_12166Binding(prototype, 'getContext', closure);
|
|
[].push(value);
|
|
} catch (error) {
|
|
console = global.console;
|
|
console.error('failed to patch HTMLCanvasElement.prototype.getContext');
|
|
}
|
|
return _fun12179;
|
|
}
|
|
|
|
function patchGLPrototype(a0, a1, a2, a3, a4, a5, a6, a7) { // fn#12181, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:7497, offset: 0x00dc3467, size: 123 bytes, params: 9, frame: 15
|
|
var error;
|
|
const env0_0 = a0;
|
|
const env0_1 = a1;
|
|
const env0_2 = a2;
|
|
const env0_3 = a3;
|
|
const env0_4 = a4;
|
|
const env0_5 = a5;
|
|
const env0_6 = a7;
|
|
const items2 = [];
|
|
const Object = global.Object;
|
|
const ownPropertyNames = Object.getOwnPropertyNames(a0);
|
|
const closure = patchGLPrototype_loop2;
|
|
const iterator = ownPropertyNames[Symbol.iterator]();
|
|
const iterator2 = iterator.next;
|
|
let r2 = iterator;
|
|
let item2 = Reflect.apply(iterator2, r2, []);
|
|
let item = item2.value;
|
|
item2 = item2.done ? undefined : r2;
|
|
reducibleJoin2: while (true) {
|
|
if (item2 === undefined) {
|
|
return items2;
|
|
}
|
|
break reducibleJoin2;
|
|
}
|
|
reducibleLoop2: while (true) {
|
|
try {
|
|
closure(item);
|
|
} catch (error) {
|
|
try {
|
|
item2.return();
|
|
} catch {
|
|
}
|
|
throw error;
|
|
}
|
|
r2 = item2;
|
|
item2 = Reflect.apply(iterator2, r2, []);
|
|
item = item2.value;
|
|
item2 = item2.done ? undefined : r2;
|
|
if (item2 === undefined) {
|
|
break reducibleLoop2;
|
|
}
|
|
continue reducibleLoop2;
|
|
}
|
|
return items2;
|
|
}
|
|
|
|
function __publicField$1_12186(a0, a1, a2) { // fn#12186, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:203, offset: 0x00dc36b9, size: 74 bytes, params: 4, frame: 16
|
|
var r4;
|
|
var r0;
|
|
let value = a1;
|
|
const value2 = a2;
|
|
if (typeof value === 'symbol') {
|
|
r4 = value;
|
|
} else {
|
|
value = String(value);
|
|
r4 = value;
|
|
}
|
|
if (r4 in a0) {
|
|
r0 = defineProperty(a0, r4, {'enumerable': true, 'configurable': true, 'writable': true, value: value2});
|
|
} else {
|
|
a0[r4] = value2;
|
|
r0 = value2;
|
|
}
|
|
return r0;
|
|
}
|
|
|
|
function _fun12187() { // fn#12187, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:391, offset: 0x00dc3703, size: 264 bytes, params: 1, frame: 15
|
|
return env0_5(Mirror_12188, [{key: 'getId', value: function(a0) {
|
|
var r1;
|
|
var value;
|
|
if (a0) {
|
|
value = this.getMeta(a0);
|
|
r1 = value?.id;
|
|
value = -1;
|
|
return r1 ?? value;
|
|
}
|
|
return -1;
|
|
}}, {key: 'getNode', value: function(a0) {
|
|
return this.idNodeMap.get(a0) || null;
|
|
}}, {key: 'getIds', value: function() {
|
|
var Array = global.Array;
|
|
return Array.from(this.idNodeMap.keys());
|
|
}}, {key: 'getMeta', value: function(a0) {
|
|
return this.nodeMetaMap.get(a0) || null;
|
|
}}, {key: 'removeNodeFromMap', value: function(a0) {
|
|
var env0_0 = this;
|
|
this.idNodeMap.delete(this.getId(a0));
|
|
if (a0.childNodes) {
|
|
a0.childNodes.forEach(_fun12194);
|
|
}
|
|
}}, {key: 'has', value: function(a0) {
|
|
return this.idNodeMap.has(a0);
|
|
}}, {key: 'hasNode', value: function(a0) {
|
|
return this.nodeMetaMap.has(a0);
|
|
}}, {key: 'add', value: function(a0, a1) {
|
|
this.idNodeMap.set(a1.id, a0);
|
|
this.nodeMetaMap.set(a0, a1);
|
|
}}, {key: 'replace', value: function(a0, a1) {
|
|
var value = this.getNode(a0);
|
|
if (value) {
|
|
value = this.nodeMetaMap.get(value);
|
|
if (value) {
|
|
this.nodeMetaMap.set(a1, value);
|
|
}
|
|
}
|
|
this.idNodeMap.set(a0, a1);
|
|
}}, {key: 'reset', value: function() {
|
|
this.idNodeMap = new global.Map();
|
|
this.nodeMetaMap = new global.WeakMap();
|
|
}}]);
|
|
}
|
|
|
|
function callbackWrapper_12206(a0) { // fn#12206, offset: 0x00dc3972, size: 28 bytes, params: 2, frame: 3
|
|
const env0_0 = a0;
|
|
if (env0_10) {
|
|
return callbackWrapper_12206RrwebWrapped;
|
|
}
|
|
return a0;
|
|
}
|
|
|
|
function saveWebGLVar(a0, a1, a2) { // fn#12209, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:4781, offset: 0x00dc39d1, size: 194 bytes, params: 4, frame: 16
|
|
var r1;
|
|
var r0;
|
|
var value;
|
|
var name;
|
|
var value2;
|
|
var map;
|
|
var value5;
|
|
var length;
|
|
if (a0) {
|
|
if (isInstanceOfWebGLObject(a0, a1)) {
|
|
name = a0.constructor.name;
|
|
value2 = env0_14.get(a2);
|
|
if (value2) {
|
|
r1 = value2;
|
|
} else {
|
|
map = new global.Map();
|
|
env0_14.set(a2, map);
|
|
r1 = map;
|
|
}
|
|
if (!r1.has(name)) {
|
|
r1.set(name, []);
|
|
}
|
|
value = r1.get(name);
|
|
value5 = value.indexOf(a0);
|
|
if (value5 !== -1) {
|
|
r0 = value5;
|
|
} else {
|
|
length = value.length;
|
|
value.push(a0);
|
|
r0 = length;
|
|
}
|
|
return r0;
|
|
}
|
|
if (typeof a0 === 'object') {
|
|
name = a0.constructor.name;
|
|
value2 = env0_14.get(a2);
|
|
if (value2) {
|
|
r1 = value2;
|
|
} else {
|
|
map = new global.Map();
|
|
env0_14.set(a2, map);
|
|
r1 = map;
|
|
}
|
|
if (!r1.has(name)) {
|
|
r1.set(name, []);
|
|
}
|
|
value = r1.get(name);
|
|
value5 = value.indexOf(a0);
|
|
if (value5 !== -1) {
|
|
r0 = value5;
|
|
} else {
|
|
length = value.length;
|
|
value.push(a0);
|
|
r0 = length;
|
|
}
|
|
return r0;
|
|
}
|
|
}
|
|
}
|
|
|
|
function serializeArgs(a0, a1, a2) { // fn#12210, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:6273, offset: 0x00dc3a93, size: 36 bytes, params: 4, frame: 11
|
|
const env0_0 = a1;
|
|
const env0_1 = a2;
|
|
return a0.map(function(a0) {
|
|
return serializeArg(a0, require, importDefault);
|
|
});
|
|
}
|
|
|
|
function isInstanceOfWebGLObject(a0, a1) { // fn#12212, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:6362, offset: 0x00dc3ab7, size: 74 bytes, params: 3, frame: 12
|
|
const env0_0 = a0;
|
|
const env0_1 = a1;
|
|
let value = ['WebGLActiveInfo', 'WebGLBuffer', 'WebGLFramebuffer', 'WebGLProgram', 'WebGLRenderbuffer',
|
|
'WebGLShader', 'WebGLShaderPrecisionFormat', 'WebGLTexture', 'WebGLUniformLocation', 'WebGLVertexArrayObject',
|
|
'WebGLVertexArrayObjectOES'].filter(function(a0) {
|
|
return typeof require[a0] === 'function';
|
|
});
|
|
const Boolean = global.Boolean;
|
|
value = value.find(_fun12214);
|
|
return Boolean(value);
|
|
}
|
|
|
|
function _fun12215() { // fn#12215, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:8197, offset: 0x00dc3b34, size: 462 bytes, params: 1, frame: 15
|
|
return env0_5(CanvasManager, [{key: 'reset', value: value_12219}, {key: 'freeze', value: function() {
|
|
this.frozen = true;
|
|
}}, {key: 'unfreeze', value: function() {
|
|
this.frozen = false;
|
|
}}, {key: 'lock', value: function() {
|
|
this.locked = true;
|
|
}}, {key: 'unlock', value: function() {
|
|
this.locked = false;
|
|
}}, {key: 'addWindow', value: value_12225}, {key: 'addShadowRoot', value: function(a0) {
|
|
var shadowDoms = this.shadowDoms;
|
|
var WeakRef = global.WeakRef;
|
|
shadowDoms.add(new WeakRef(a0));
|
|
}}, {key: 'resetShadowRoots', value: function() {
|
|
var Set = global.Set;
|
|
this.shadowDoms = new Set();
|
|
}}, {key: 'snapshot', value: value_12230}, {key: 'initFPSWorker', value: function() {
|
|
var env0_0 = this;
|
|
var Worker = global.Worker;
|
|
var Blob = global.Blob;
|
|
var value2 = new Blob(['for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",t="undefined"==typeof Uint8Array?[]:new Uint8Array(256),a=0;a<64;a++)t[e.charCodeAt(a)]=a;var n=function(t){var a,n=new Uint8Array(t),r=n.length,s="";for(a=0;a<r;a+=3)s+=e[n[a]>>2],s+=e[(3&n[a])<<4|n[a+1]>>4],s+=e[(15&n[a+1])<<2|n[a+2]>>6],s+=e[63&n[a+2]];return r%3==2?s=s.substring(0,s.length-1)+"=":r%3==1&&(s=s.substring(0,s.length-2)+"=="),s};const r=new Map,s=new Map;const i=self;i.onmessage=async function(e){if(!("OffscreenCanvas"in globalThis))return i.postMessage({id:e.data.id});{const{id:t,bitmap:a,width:o,height:f,maxCanvasSize:c,dataURLOptions:g}=e.data,u=async function(e,t,a){const r=e+"-"+t;if("OffscreenCanvas"in globalThis){if(s.has(r))return s.get(r);const i=new OffscreenCanvas(e,t);i.getContext("2d");const o=await i.convertToBlob(a),f=await o.arrayBuffer(),c=n(f);return s.set(r,c),c}return""}(o,f,g),[h,d]=function(e,t,a){if(!a)return[e,t];const[n,r]=a;if(e<=n&&t<=r)return[e,t];let s=e,i=t;return s>n&&(i=Math.floor(n*t/e),s=n),i>r&&(s=Math.floor(r*e/t),i=r),[s,i]}(o,f,c),l=new OffscreenCanvas(h,d),w=l.getContext("bitmaprenderer"),p=h===o&&d===f?a:await createImageBitmap(a,{resizeWidth:h,resizeHeight:d,resizeQuality:"low"});w?.transferFromImageBitmap(p),a.close();const y=await l.convertToBlob(g),v=y.type,b=await y.arrayBuffer(),m=n(b);if(p.close(),!r.has(t)&&await u===m)return r.set(t,m),i.postMessage({id:t});if(r.get(t)===m)return i.postMessage({id:t});i.postMessage({id:t,type:v,base64:m,width:o,height:f}),r.set(t,m)}};']);
|
|
var URL = global.URL;
|
|
value2 = URL.createObjectURL(value2);
|
|
value2 = new Worker(value2);
|
|
value2.onmessage = _fun12233;
|
|
return value2;
|
|
}}, {key: 'initCanvasFPSObserver', value: value_12234}, {key: 'initCanvasMutationObserver', value: value_12237},
|
|
{key: 'getCanvasElements', value: value_12250}, {key: 'takeSnapshot', value: value_12253},
|
|
{key: 'startPendingCanvasMutationFlusher', value: function() {
|
|
var env0_0 = this;
|
|
onRequestAnimationFrame(_fun12259);
|
|
}}, {key: 'startRAFTimestamping', value: function() {
|
|
var env0_0 = this;
|
|
var closure = _fun12261;
|
|
var env0_1 = closure;
|
|
onRequestAnimationFrame(closure);
|
|
}}, {key: 'flushPendingCanvasMutations', value: function() {
|
|
var env0_0 = this;
|
|
this.pendingCanvasMutations.forEach(_fun12263);
|
|
onRequestAnimationFrame(_fun12264);
|
|
}}, {key: 'flushPendingCanvasMutationFor', value: value_12265}]);
|
|
}
|
|
|
|
function _replayCanvasIntegration() { // fn#12268, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:17492, offset: 0x00dc4ed2, size: 276 bytes, params: 1, frame: 19
|
|
const r3 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
const value2 = env0_1(r3.maxCanvasSize || [], 2);
|
|
const property = value2[0];
|
|
const property2 = value2[1];
|
|
let object2 = {};
|
|
let quality = r3.quality;
|
|
quality = !quality ? 'medium' : quality;
|
|
object2.quality = quality;
|
|
object2.enableManualSnapshot = r3.enableManualSnapshot;
|
|
const items2 = [property ? global.Math.min(property, env0_20) : env0_20];
|
|
items2[1] = property2 ? global.Math.min(property2, env0_20) : env0_20;
|
|
object2.maxCanvasSize = items2;
|
|
const Promise = global.Promise;
|
|
const promise = new Promise(function(a0) {
|
|
env0_1 = a0;
|
|
return a0;
|
|
});
|
|
object2 = {name: 'ReplayCanvas', getOptions: getOptions_12270};
|
|
const env0_2 = env0_0(_fun12274);
|
|
object2.snapshot = snapshot_12275;
|
|
return object2;
|
|
}
|
|
|
|
function hookSetter_12162Set(a0) { // fn#12163, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:2838, owner: hookSetter_12162.set, offset: 0x00dc2bdd, size: 81 bytes, params: 2, frame: 15
|
|
const env0_0 = a0;
|
|
setTimeout$1_12173(_fun12164, 0);
|
|
if (env0_3 && env0_3.set) {
|
|
env0_3.set.call(this, a0);
|
|
}
|
|
}
|
|
|
|
function _fun12165() { // fn#12165, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:2943, offset: 0x00dc2c2e, size: 46 bytes, params: 1, frame: 17
|
|
return hookSetter_12162(env0_0, require, env0_3 || ({}), true);
|
|
}
|
|
|
|
function _fun12177(a0) { // fn#12177, offset: 0x00dc3313, size: 16 bytes, params: 2, frame: 2
|
|
const env0_0 = a0;
|
|
return _fun12178;
|
|
}
|
|
|
|
function _fun12179() { // fn#12179, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:7448, offset: 0x00dc344b, size: 28 bytes, params: 1, frame: 11
|
|
env0_4.forEach(function(a0) {
|
|
return a0();
|
|
});
|
|
}
|
|
|
|
function patchGLPrototype_loop2(a0) { // fn#12182, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:7583, owner: patchGLPrototype._loop2, offset: 0x00dc34e2, size: 172 bytes, params: 2, frame: 18
|
|
var environment;
|
|
var binding;
|
|
var property;
|
|
var value2;
|
|
var patch_12166Binding;
|
|
var closure;
|
|
var value4;
|
|
var push;
|
|
var error;
|
|
var value5;
|
|
var hookSetter_12162Binding;
|
|
var value6;
|
|
let env0_0 = a0;
|
|
const items = ['isContextLost', 'canvas', 'drawingBufferWidth', 'drawingBufferHeight'];
|
|
if (items.includes(a0)) {
|
|
return 0;
|
|
}
|
|
reducibleJoin3: while (true) {
|
|
reduciblePort18: while (true) {
|
|
exceptionLanding17: while (true) {
|
|
try {
|
|
binding = env0_0;
|
|
} catch (error) {
|
|
break exceptionLanding17;
|
|
}
|
|
break reducibleJoin3;
|
|
}
|
|
value5 = environment.__proto__;
|
|
hookSetter_12162Binding = hookSetter_12162;
|
|
binding = env0_0;
|
|
value6 = hookSetter_12162Binding(binding, a0, {set: set_12185});
|
|
binding = env0_7;
|
|
push = binding.push;
|
|
Reflect.apply(push, binding, [value6]);
|
|
break reduciblePort18;
|
|
}
|
|
return undefined;
|
|
}
|
|
try {
|
|
property = binding[a0];
|
|
} catch (error) {
|
|
break exceptionLanding17;
|
|
}
|
|
try {
|
|
value2 = typeof property !== 'function';
|
|
} catch (error) {
|
|
break exceptionLanding17;
|
|
}
|
|
if (value2) {
|
|
return 0;
|
|
}
|
|
try {
|
|
patch_12166Binding = patch_12166;
|
|
} catch (error) {
|
|
break exceptionLanding17;
|
|
}
|
|
try {
|
|
binding = env0_0;
|
|
} catch (error) {
|
|
break exceptionLanding17;
|
|
}
|
|
try {
|
|
closure = function(a0) {
|
|
var env0_0 = a0;
|
|
return _fun12184;
|
|
};
|
|
} catch (error) {
|
|
break exceptionLanding17;
|
|
}
|
|
try {
|
|
value4 = patch_12166Binding(binding, a0, closure);
|
|
} catch (error) {
|
|
break exceptionLanding17;
|
|
}
|
|
try {
|
|
binding = env0_7;
|
|
} catch (error) {
|
|
break exceptionLanding17;
|
|
}
|
|
try {
|
|
push = binding.push;
|
|
} catch (error) {
|
|
break exceptionLanding17;
|
|
}
|
|
try {
|
|
Reflect.apply(push, binding, [value4]);
|
|
} catch (error) {
|
|
break exceptionLanding17;
|
|
}
|
|
}
|
|
|
|
function Mirror_12188() { // fn#12188, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:425, offset: 0x00dc380b, size: 107 bytes, params: 1, frame: 16
|
|
const value = environment.__proto__;
|
|
env1_4(this, Mirror_12188);
|
|
const __publicField$1_12186Binding = __publicField$1_12186;
|
|
const Map = global.Map;
|
|
__publicField$1_12186Binding(this, 'idNodeMap', new Map());
|
|
const WeakMap = global.WeakMap;
|
|
__publicField$1_12186Binding(this, 'nodeMetaMap', new WeakMap());
|
|
}
|
|
|
|
function value_12193(a0) { // fn#12193, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:917, offset: 0x00dc3876, size: 73 bytes, params: 2, frame: 13
|
|
this.idNodeMap.delete(this.getId(a0));
|
|
if (a0.childNodes) {
|
|
a0.childNodes.forEach(_fun12194);
|
|
}
|
|
}
|
|
|
|
function callbackWrapper_12206RrwebWrapped() { // fn#12207, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:4485, owner: callbackWrapper_12206.rrwebWrapped, offset: 0x00dc398e, size: 67 bytes, params: 1, frame: 15
|
|
var environment;
|
|
var value;
|
|
var binding;
|
|
var error;
|
|
try {
|
|
value = environment;
|
|
binding = env0_0;
|
|
value = binding.apply(undefined, arguments);
|
|
} catch (error) {
|
|
value = environment.__proto__;
|
|
if (env1_10) {
|
|
value = env1_10(error);
|
|
if (value === true) {
|
|
return function() {
|
|
};
|
|
}
|
|
throw error;
|
|
}
|
|
throw error;
|
|
}
|
|
return value;
|
|
}
|
|
|
|
function _fun12214(a0) { // fn#12214, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:6704, offset: 0x00dc3b1c, size: 24 bytes, params: 2, frame: 3
|
|
return env0_0 instanceof require[a0];
|
|
}
|
|
|
|
function CanvasManager(a0) { // fn#12216, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:8231, offset: 0x00dc3d02, size: 408 bytes, params: 2, frame: 20
|
|
env1_4(this, CanvasManager);
|
|
let Map = global.Map;
|
|
const value3 = Object.create(Map.prototype, {constructor: {value: Map}});
|
|
let map = new Map();
|
|
this.pendingCanvasMutations = map instanceof Object ? map : value3;
|
|
this.rafStamps = {'latestId': 0, 'invokeId': null};
|
|
const Set = global.Set;
|
|
const value5 = Object.create(Set.prototype, {constructor: {value: Set}});
|
|
const set = new Set();
|
|
this.shadowDoms = set instanceof Object ? set : value5;
|
|
const WeakSet = global.WeakSet;
|
|
const value7 = Object.create(WeakSet.prototype, {constructor: {value: WeakSet}});
|
|
const weakSet = new WeakSet();
|
|
this.windowsSet = weakSet instanceof Object ? weakSet : value7;
|
|
this.windows = [];
|
|
this.restoreHandlers = [];
|
|
this.frozen = false;
|
|
this.locked = false;
|
|
Map = global.Map;
|
|
const value9 = Object.create(Map.prototype, {constructor: {value: Map}});
|
|
map = new Map();
|
|
this.snapshotInProgressMap = map instanceof Object ? map : value9;
|
|
this.worker = null;
|
|
this.lastSnapshotTime = 0;
|
|
this.processMutation = processMutation;
|
|
const enableManualSnapshot = a0.enableManualSnapshot;
|
|
const sampling = a0.sampling;
|
|
const r7 = sampling === undefined ? 'all' : sampling;
|
|
const win = a0.win;
|
|
const recordCanvas = a0.recordCanvas;
|
|
const errorHandler = a0.errorHandler;
|
|
a0.sampling = r7;
|
|
this.mutationCb = a0.mutationCb;
|
|
this.mirror = a0.mirror;
|
|
this.options = a0;
|
|
if (errorHandler) {
|
|
}
|
|
let r4 = recordCanvas && typeof r7 === 'number';
|
|
r4 = !r4 ? enableManualSnapshot : r4;
|
|
if (r4) {
|
|
this.worker = this.initFPSWorker();
|
|
}
|
|
this.addWindow(win);
|
|
if (!enableManualSnapshot) {
|
|
callbackWrapper_12206(_fun12218)();
|
|
}
|
|
}
|
|
|
|
function value_12219() { // fn#12219, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:9326, offset: 0x00dc3fbf, size: 192 bytes, params: 1, frame: 13
|
|
this.pendingCanvasMutations.clear();
|
|
this.restoreHandlers.forEach(function(a0) {
|
|
var error;
|
|
try {
|
|
a0();
|
|
} catch (error) {
|
|
}
|
|
});
|
|
this.restoreHandlers = [];
|
|
const WeakSet = global.WeakSet;
|
|
this.windowsSet = new WeakSet();
|
|
this.windows = [];
|
|
const Set = global.Set;
|
|
this.shadowDoms = new Set();
|
|
const worker = this.worker;
|
|
if (worker != null) {
|
|
worker.terminate();
|
|
}
|
|
this.worker = null;
|
|
const Map = global.Map;
|
|
this.snapshotInProgressMap = new Map();
|
|
}
|
|
|
|
function value_12225(a0) { // fn#12225, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:9875, offset: 0x00dc40bb, size: 270 bytes, params: 2, frame: 16
|
|
var environment;
|
|
var windows;
|
|
const env0_0 = a0;
|
|
const options = this.options;
|
|
const sampling = options.sampling;
|
|
const env0_2 = sampling === undefined ? 'all' : sampling;
|
|
const env0_3 = options.blockClass;
|
|
const env0_4 = options.blockSelector;
|
|
const env0_5 = options.unblockSelector;
|
|
const env0_6 = options.recordCanvas;
|
|
const enableManualSnapshot = options.enableManualSnapshot;
|
|
const windowsSet = this.windowsSet;
|
|
if (!windowsSet.has(a0)) {
|
|
if (enableManualSnapshot) {
|
|
this.windowsSet.add(a0);
|
|
windows = this.windows;
|
|
windows.push(new global.WeakRef(a0));
|
|
return undefined;
|
|
}
|
|
value = environment.__proto__;
|
|
callbackWrapper_12206(_fun12226)();
|
|
this.windowsSet.add(a0);
|
|
windows = this.windows;
|
|
windows.push(new global.WeakRef(a0));
|
|
}
|
|
}
|
|
|
|
function value_12230(a0, a1) { // fn#12230, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:10595, offset: 0x00dc42bc, size: 93 bytes, params: 3, frame: 15
|
|
var environment;
|
|
var value;
|
|
const env0_0 = a0;
|
|
if (a1 == null) {
|
|
value = environment.__proto__;
|
|
onRequestAnimationFrame(_fun12231);
|
|
} else if (a1.skipRequestAnimationFrame) {
|
|
this.takeSnapshot(global.performance.now(), true, a0);
|
|
} else {
|
|
value = environment.__proto__;
|
|
onRequestAnimationFrame(_fun12231);
|
|
}
|
|
}
|
|
|
|
function value_12232() { // fn#12232, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:10807, offset: 0x00dc4338, size: 103 bytes, params: 1, frame: 14
|
|
const Worker = global.Worker;
|
|
const Blob = global.Blob;
|
|
let blob = new Blob(['for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",t="undefined"==typeof Uint8Array?[]:new Uint8Array(256),a=0;a<64;a++)t[e.charCodeAt(a)]=a;var n=function(t){var a,n=new Uint8Array(t),r=n.length,s="";for(a=0;a<r;a+=3)s+=e[n[a]>>2],s+=e[(3&n[a])<<4|n[a+1]>>4],s+=e[(15&n[a+1])<<2|n[a+2]>>6],s+=e[63&n[a+2]];return r%3==2?s=s.substring(0,s.length-1)+"=":r%3==1&&(s=s.substring(0,s.length-2)+"=="),s};const r=new Map,s=new Map;const i=self;i.onmessage=async function(e){if(!("OffscreenCanvas"in globalThis))return i.postMessage({id:e.data.id});{const{id:t,bitmap:a,width:o,height:f,maxCanvasSize:c,dataURLOptions:g}=e.data,u=async function(e,t,a){const r=e+"-"+t;if("OffscreenCanvas"in globalThis){if(s.has(r))return s.get(r);const i=new OffscreenCanvas(e,t);i.getContext("2d");const o=await i.convertToBlob(a),f=await o.arrayBuffer(),c=n(f);return s.set(r,c),c}return""}(o,f,g),[h,d]=function(e,t,a){if(!a)return[e,t];const[n,r]=a;if(e<=n&&t<=r)return[e,t];let s=e,i=t;return s>n&&(i=Math.floor(n*t/e),s=n),i>r&&(s=Math.floor(r*e/t),i=r),[s,i]}(o,f,c),l=new OffscreenCanvas(h,d),w=l.getContext("bitmaprenderer"),p=h===o&&d===f?a:await createImageBitmap(a,{resizeWidth:h,resizeHeight:d,resizeQuality:"low"});w?.transferFromImageBitmap(p),a.close();const y=await l.convertToBlob(g),v=y.type,b=await y.arrayBuffer(),m=n(b);if(p.close(),!r.has(t)&&await u===m)return r.set(t,m),i.postMessage({id:t});if(r.get(t)===m)return i.postMessage({id:t});i.postMessage({id:t,type:v,base64:m,width:o,height:f}),r.set(t,m)}};']);
|
|
const URL = global.URL;
|
|
blob = URL.createObjectURL(blob);
|
|
const worker = new Worker(blob);
|
|
worker.onmessage = onmessage_12233;
|
|
return worker;
|
|
}
|
|
|
|
function value_12234() { // fn#12234, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:12864, offset: 0x00dc44b5, size: 89 bytes, params: 1, frame: 13
|
|
var environment;
|
|
var closure;
|
|
var value;
|
|
if (this.windows.length) {
|
|
closure = rafCallback;
|
|
value = environment.__proto__;
|
|
var env0_0 = onRequestAnimationFrame(closure);
|
|
this.restoreHandlers.push(_fun12236);
|
|
} else if (this.shadowDoms.size) {
|
|
closure = rafCallback;
|
|
value = environment.__proto__;
|
|
var env0_0 = onRequestAnimationFrame(closure);
|
|
this.restoreHandlers.push(_fun12236);
|
|
}
|
|
}
|
|
|
|
function value_12237(a0, a1, a2, a3) { // fn#12237, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:13177, offset: 0x00dc455f, size: 167 bytes, params: 5, frame: 22
|
|
var environment;
|
|
let value = environment.__proto__;
|
|
let env0_0 = initCanvasContextObserver(a0, a1, a2, a3, false);
|
|
let env0_1 = ((a0, a1, a2, a3, a4) => {
|
|
var error;
|
|
var env0_0 = a0;
|
|
var env0_1 = a1;
|
|
var env0_2 = a2;
|
|
var env0_3 = a3;
|
|
var env0_4 = a4;
|
|
var env0_5 = [];
|
|
var Object = global.Object;
|
|
var value = Object.getOwnPropertyNames(a1.CanvasRenderingContext2D.prototype);
|
|
var closure = _fun12239;
|
|
var iterator = value[Symbol.iterator]();
|
|
var iterator2 = iterator.next;
|
|
var r2 = iterator;
|
|
var item2 = Reflect.apply(iterator2, r2, []);
|
|
var item = item2.value;
|
|
item2 = item2.done ? undefined : r2;
|
|
reducibleJoin2: while (true) {
|
|
if (item2 === undefined) {
|
|
return _fun12244;
|
|
}
|
|
break reducibleJoin2;
|
|
}
|
|
reducibleLoop2: while (true) {
|
|
try {
|
|
closure(item);
|
|
} catch (error) {
|
|
try {
|
|
item2.return();
|
|
} catch {
|
|
}
|
|
throw error;
|
|
}
|
|
r2 = item2;
|
|
item2 = Reflect.apply(iterator2, r2, []);
|
|
item = item2.value;
|
|
item2 = item2.done ? undefined : r2;
|
|
if (item2 === undefined) {
|
|
break reducibleLoop2;
|
|
}
|
|
continue reducibleLoop2;
|
|
}
|
|
return _fun12244;
|
|
})(this.processMutation.bind(this), a0, a1, a2, a3);
|
|
value = this.processMutation.bind(this);
|
|
this.mirror;
|
|
let env0_2 = initCanvasWebGLMutationObserver(value, a0, a1, a2, a3, undefined);
|
|
this.restoreHandlers.push(_fun12249);
|
|
}
|
|
|
|
function value_12250(a0, a1, a2) { // fn#12250, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:14568, offset: 0x00dc4999, size: 194 bytes, params: 4, frame: 20
|
|
var r6;
|
|
var r9;
|
|
var r8;
|
|
var r2;
|
|
var value;
|
|
var closure;
|
|
var windows;
|
|
var iterator;
|
|
var iterator2;
|
|
var item;
|
|
var item2;
|
|
var deref;
|
|
var value2;
|
|
var document;
|
|
var error;
|
|
var shadowDoms;
|
|
var iterator3;
|
|
var item3;
|
|
var value3;
|
|
exceptionLanding22: while (true) {
|
|
exceptionLanding14: while (true) {
|
|
var env0_0 = a0;
|
|
var env0_1 = a1;
|
|
var env0_2 = a2;
|
|
value = undefined;
|
|
closure = function(a0) {
|
|
a0.querySelectorAll('canvas').forEach(_fun12252);
|
|
};
|
|
windows = this.windows;
|
|
iterator = windows[Symbol.iterator]();
|
|
iterator2 = iterator.next;
|
|
r6 = iterator;
|
|
reducibleLoop1: while (true) {
|
|
item2 = Reflect.apply(iterator2, r6, []);
|
|
item = item2.value;
|
|
item2 = item2.done ? undefined : r6;
|
|
if (item2 === value) {
|
|
break reducibleLoop1;
|
|
}
|
|
try {
|
|
deref = item.deref;
|
|
} catch (error) {
|
|
break exceptionLanding14;
|
|
}
|
|
try {
|
|
value2 = Reflect.apply(deref, item, []);
|
|
} catch (error) {
|
|
break exceptionLanding14;
|
|
}
|
|
reducibleJoin8: while (true) {
|
|
reduciblePort11: while (true) {
|
|
exceptionLanding10: while (true) {
|
|
if (value2) {
|
|
try {
|
|
try {
|
|
document = value2.document;
|
|
} catch (error) {
|
|
break exceptionLanding10;
|
|
}
|
|
} catch (error) {
|
|
break exceptionLanding14;
|
|
}
|
|
r9 = document;
|
|
break reducibleJoin8;
|
|
}
|
|
r9 = value2;
|
|
break reducibleJoin8;
|
|
}
|
|
r8 = value;
|
|
break reduciblePort11;
|
|
}
|
|
if (r8) {
|
|
try {
|
|
closure(r8);
|
|
} catch (error) {
|
|
break exceptionLanding14;
|
|
}
|
|
r6 = item2;
|
|
continue reducibleLoop1;
|
|
}
|
|
r6 = item2;
|
|
continue reducibleLoop1;
|
|
}
|
|
r8 = r9;
|
|
if (r8) {
|
|
try {
|
|
closure(r8);
|
|
} catch (error) {
|
|
break exceptionLanding14;
|
|
}
|
|
r6 = item2;
|
|
continue reducibleLoop1;
|
|
}
|
|
r6 = item2;
|
|
continue reducibleLoop1;
|
|
}
|
|
shadowDoms = this.shadowDoms;
|
|
iterator = shadowDoms[Symbol.iterator]();
|
|
iterator3 = iterator.next;
|
|
r2 = iterator;
|
|
reducibleLoop16: while (true) {
|
|
item3 = Reflect.apply(iterator3, r2, []);
|
|
item = item3.value;
|
|
item3 = item3.done ? undefined : r2;
|
|
if (item3 === value) {
|
|
break reducibleLoop16;
|
|
}
|
|
try {
|
|
deref = item.deref;
|
|
} catch (error) {
|
|
break exceptionLanding22;
|
|
}
|
|
try {
|
|
value3 = Reflect.apply(deref, item, []);
|
|
} catch (error) {
|
|
break exceptionLanding22;
|
|
}
|
|
if (value3) {
|
|
try {
|
|
closure(value3);
|
|
} catch (error) {
|
|
break exceptionLanding22;
|
|
}
|
|
r2 = item3;
|
|
continue reducibleLoop16;
|
|
}
|
|
r2 = item3;
|
|
continue reducibleLoop16;
|
|
}
|
|
return [];
|
|
}
|
|
try {
|
|
item2.return();
|
|
} catch {
|
|
}
|
|
throw error;
|
|
}
|
|
try {
|
|
item3.return();
|
|
} catch {
|
|
}
|
|
throw error;
|
|
}
|
|
|
|
function value_12253(a0, a1, a2) { // fn#12253, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:14906, offset: 0x00dc4abb, size: 189 bytes, params: 4, frame: 21
|
|
const env0_0 = a1;
|
|
const options = this.options;
|
|
const sampling = options.sampling;
|
|
const blockClass = options.blockClass;
|
|
const blockSelector = options.blockSelector;
|
|
const unblockSelector = options.unblockSelector;
|
|
const env0_2 = options.dataURLOptions;
|
|
const env0_3 = options.maxCanvasSize;
|
|
let value = 2;
|
|
value = 1000 / (sampling === 'all' ? value : sampling || value);
|
|
let r0 = this.lastSnapshotTime && a0 - this.lastSnapshotTime < value;
|
|
if (r0) {
|
|
r0 = !r0;
|
|
} else {
|
|
this.lastSnapshotTime = a0;
|
|
(a2 ? [a2] : this.getCanvasElements(blockClass, blockSelector, unblockSelector)).forEach(_fun12254);
|
|
r0 = true;
|
|
}
|
|
return r0;
|
|
}
|
|
|
|
function value_12258() { // fn#12258, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:15866, offset: 0x00dc4d56, size: 30 bytes, params: 1, frame: 11
|
|
onRequestAnimationFrame(_fun12259);
|
|
}
|
|
|
|
function value_12260() { // fn#12260, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:16036, offset: 0x00dc4d87, size: 34 bytes, params: 1, frame: 11
|
|
onRequestAnimationFrame(setLatestRAFTimestamp);
|
|
}
|
|
|
|
function value_12262() { // fn#12262, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:16236, offset: 0x00dc4dd3, size: 51 bytes, params: 1, frame: 12
|
|
this.pendingCanvasMutations.forEach(_fun12263);
|
|
onRequestAnimationFrame(_fun12264);
|
|
}
|
|
|
|
function value_12265(a0, a1) { // fn#12265, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:16524, offset: 0x00dc4e33, size: 130 bytes, params: 3, frame: 15
|
|
var value;
|
|
if (!this.frozen) {
|
|
if (!this.locked) {
|
|
value = this.pendingCanvasMutations.get(a0);
|
|
if (value) {
|
|
if (a1 !== -1) {
|
|
this.mutationCb({id: a1, type: value[0].type, commands: value.map(_fun12266)});
|
|
this.pendingCanvasMutations.delete(a0);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
function _replayCanvasIntegrationGetOptions() { // fn#12270, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:17850, owner: _replayCanvasIntegration.getOptions, offset: 0x00dc4ff2, size: 112 bytes, params: 1, frame: 15
|
|
const quality = env0_3.quality;
|
|
const enableManualSnapshot = env0_3.enableManualSnapshot;
|
|
const env0_1 = env0_3.maxCanvasSize;
|
|
const Object = global.Object;
|
|
return Object.assign({enableManualSnapshot: enableManualSnapshot, recordCanvas: true,
|
|
getCanvasManager: getCanvasManager}, env1_19[quality] || env1_19.medium);
|
|
}
|
|
|
|
function* _fun12274(a0, a1) { // fn#12274, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:18255, offset: 0x00dc50fa, size: 63 bytes, params: 3, frame: 14
|
|
if (true) {
|
|
value = environment.__proto__;
|
|
var binding = env1_0;
|
|
if (binding) {
|
|
binding.snapshot(a0, a1);
|
|
} else {
|
|
yield env1_4;
|
|
value = undefined;
|
|
if (false) {
|
|
return value;
|
|
}
|
|
value.snapshot(a0, a1);
|
|
}
|
|
}
|
|
}
|
|
|
|
function _replayCanvasIntegrationSnapshot(a0, a1) { // fn#12275, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:18302, owner: _replayCanvasIntegration.snapshot, offset: 0x00dc5139, size: 29 bytes, params: 3, frame: 13
|
|
return env0_2.apply(this, arguments);
|
|
}
|
|
|
|
function _fun12178(a0) { // fn#12178, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:6880, offset: 0x00dc3323, size: 296 bytes, params: 2, frame: 24
|
|
var r2;
|
|
var r8;
|
|
var value5;
|
|
var value8;
|
|
var value9;
|
|
var value12;
|
|
var items;
|
|
var includes;
|
|
var splice;
|
|
var property;
|
|
var preserveDrawingBuffer;
|
|
const value = a0;
|
|
const length = arguments.length;
|
|
const Array = global.Array;
|
|
const value3 = 1;
|
|
const value4 = 0;
|
|
reducibleJoin2: while (true) {
|
|
if (length > value3) {
|
|
value5 = length - value3;
|
|
r2 = value5;
|
|
break reducibleJoin2;
|
|
}
|
|
r2 = value4;
|
|
break reducibleJoin2;
|
|
}
|
|
const array = new Array();
|
|
if (value3 < length) {
|
|
r2 = value3;
|
|
reducibleLoop3: while (true) {
|
|
value8 = r2 - value3;
|
|
array[value8] = arguments[r2];
|
|
value9 = typeof r2 === 'bigint' ? r2 + 1n : +r2 + 1;
|
|
if (value9 < length) {
|
|
r2 = value9;
|
|
continue reducibleLoop3;
|
|
}
|
|
break reducibleLoop3;
|
|
}
|
|
}
|
|
reducibleJoin15: while (true) {
|
|
if (isBlocked_12170(this, require, importDefault, importAll, true)) {
|
|
break reducibleJoin15;
|
|
}
|
|
value12 = 'webgl';
|
|
r8 = value === 'experimental-webgl' ? value12 : value;
|
|
reducibleJoin8: while (true) {
|
|
if ('__context' in this) {
|
|
break reducibleJoin8;
|
|
}
|
|
this.__context = r8;
|
|
break reducibleJoin8;
|
|
}
|
|
if (env1_3) {
|
|
items = ['webgl', 'webgl2'];
|
|
includes = items.includes;
|
|
if (Reflect.apply(includes, items, [r8])) {
|
|
if (array[value4]) {
|
|
if (typeof array[value4] === 'object') {
|
|
property = array[value4];
|
|
preserveDrawingBuffer = property.preserveDrawingBuffer;
|
|
if (preserveDrawingBuffer) {
|
|
break reducibleJoin15;
|
|
}
|
|
property.preserveDrawingBuffer = true;
|
|
break reducibleJoin15;
|
|
}
|
|
}
|
|
splice = array.splice;
|
|
Reflect.apply(splice, array, [value4, value3, {preserveDrawingBuffer: true}]);
|
|
break reducibleJoin15;
|
|
}
|
|
break reducibleJoin15;
|
|
}
|
|
break reducibleJoin15;
|
|
}
|
|
const binding = env0_0;
|
|
const apply = binding.apply;
|
|
items = [value];
|
|
return Reflect.apply(apply, binding, [this, items.concat(array)]);
|
|
}
|
|
|
|
function _fun12183(a0) { // fn#12183, offset: 0x00dc358e, size: 16 bytes, params: 2, frame: 2
|
|
const env0_0 = a0;
|
|
return _fun12184;
|
|
}
|
|
|
|
function _loop2Set(a0) { // fn#12185, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:8073, owner: patchGLPrototype._loop2.set, offset: 0x00dc3673, size: 70 bytes, params: 2, frame: 14
|
|
importDefault(this.canvas, {type: require, property: env0_0, args: [a0], setter: true});
|
|
}
|
|
|
|
function CanvasManagerProcessMutation(a0, a1) { // fn#12217, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:8587, owner: CanvasManager.processMutation, offset: 0x00dc3e9a, size: 195 bytes, params: 3, frame: 14
|
|
var r1;
|
|
var binding;
|
|
var latestId;
|
|
let rafStamps = env0_0.rafStamps;
|
|
const invokeId = rafStamps.invokeId;
|
|
if (invokeId) {
|
|
binding = env0_0;
|
|
rafStamps = binding.rafStamps;
|
|
latestId = rafStamps.latestId;
|
|
rafStamps = binding.rafStamps;
|
|
r1 = latestId !== rafStamps.invokeId;
|
|
} else {
|
|
r1 = invokeId;
|
|
}
|
|
r1 = !r1 && env0_0.rafStamps.invokeId;
|
|
if (!r1) {
|
|
binding = env0_0;
|
|
binding.rafStamps.invokeId = binding.rafStamps.latestId;
|
|
}
|
|
const pendingCanvasMutations = env0_0.pendingCanvasMutations;
|
|
if (!pendingCanvasMutations.has(a0)) {
|
|
env0_0.pendingCanvasMutations.set(a0, []);
|
|
}
|
|
env0_0.pendingCanvasMutations.get(a0).push(a1);
|
|
}
|
|
|
|
function _fun12218() { // fn#12218, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:9160, offset: 0x00dc3f5d, size: 98 bytes, params: 1, frame: 11
|
|
var binding;
|
|
if (recordCanvas && env0_1 === 'all') {
|
|
binding = env0_0;
|
|
binding.startRAFTimestamping();
|
|
binding.startPendingCanvasMutationFlusher();
|
|
}
|
|
if (recordCanvas && typeof env0_1 === 'number') {
|
|
env0_0.initCanvasFPSObserver();
|
|
}
|
|
}
|
|
|
|
function _fun12226() { // fn#12226, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:10157, offset: 0x00dc41c9, size: 148 bytes, params: 1, frame: 21
|
|
var environment;
|
|
var binding;
|
|
var value3;
|
|
if (recordCanvas && env0_2 === 'all') {
|
|
binding = env0_1;
|
|
binding.initCanvasMutationObserver(env0_0Binding, blockClass, blockSelector, unblockSelector);
|
|
}
|
|
if (recordCanvas) {
|
|
if (typeof env0_2 === 'number') {
|
|
value3 = environment.__proto__.__proto__;
|
|
var env0_0Binding = initCanvasContextObserver(env0_0, blockClass, blockSelector, unblockSelector, true);
|
|
env0_1.restoreHandlers.push(_fun12227);
|
|
}
|
|
}
|
|
}
|
|
|
|
function _fun12231(a0) { // fn#12231, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:10733, offset: 0x00dc4319, size: 31 bytes, params: 2, frame: 15
|
|
return env0_1.takeSnapshot(a0, true, env0_0);
|
|
}
|
|
|
|
function value_12232Onmessage({data}) { // fn#12233, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:12479, owner: value_12232.onmessage, offset: 0x00dc439f, size: 278 bytes, params: 2, frame: 22
|
|
var base64;
|
|
var type;
|
|
var width;
|
|
var height;
|
|
var binding;
|
|
var mutationCb;
|
|
const id = data.id;
|
|
env0_0.snapshotInProgressMap.set(id, false);
|
|
if ('base64' in data) {
|
|
base64 = data.base64;
|
|
type = data.type;
|
|
width = data.width;
|
|
height = data.height;
|
|
binding = env0_0;
|
|
mutationCb = binding.mutationCb;
|
|
value = environment.__proto__.__proto__;
|
|
Reflect.apply(mutationCb, binding, [{id: id, type: env2_11['2D'], commands: [{property: 'clearRect', args: [0,
|
|
0,
|
|
width, height]}, {property: 'drawImage', args: [{rr_type: 'ImageBitmap', args: [{rr_type: 'Blob',
|
|
data: [{rr_type: 'ArrayBuffer', base64: base64}], type: type}]}, 0, 0, width, height]}]}]);
|
|
}
|
|
}
|
|
|
|
function rafCallback(a0) { // fn#12235, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:12962, owner: value_12234.rafCallback, offset: 0x00dc450e, size: 48 bytes, params: 2, frame: 14
|
|
env0_1.takeSnapshot(a0, false);
|
|
env0_0 = onRequestAnimationFrame(rafCallback);
|
|
}
|
|
|
|
function _fun12236() { // fn#12236, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:13093, offset: 0x00dc453e, size: 33 bytes, params: 1, frame: 11
|
|
if (env0_0) {
|
|
global.cancelAnimationFrame(env0_0);
|
|
}
|
|
}
|
|
|
|
function initCanvas2DMutationObserver(a0, a1, a2, a3, a4) { // fn#12238, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:13268, owner: value_12237.initCanvas2DMutationObserver, offset: 0x00dc4606, size: 125 bytes, params: 6, frame: 15
|
|
var error;
|
|
const env0_0 = a0;
|
|
const env0_1 = a1;
|
|
const env0_2 = a2;
|
|
const env0_3 = a3;
|
|
const env0_4 = a4;
|
|
const env0_5 = [];
|
|
const Object = global.Object;
|
|
const getOwnPropertyNames = Object.getOwnPropertyNames;
|
|
const CanvasRenderingContext2D = a1.CanvasRenderingContext2D;
|
|
const value = Reflect.apply(getOwnPropertyNames, Object, [CanvasRenderingContext2D.prototype]);
|
|
const closure = initCanvas2DMutationObserver_loop;
|
|
const iterator = value[Symbol.iterator]();
|
|
const iterator2 = iterator.next;
|
|
let r2 = iterator;
|
|
let item2 = Reflect.apply(iterator2, r2, []);
|
|
let item = item2.value;
|
|
item2 = item2.done ? undefined : r2;
|
|
reducibleJoin2: while (true) {
|
|
if (item2 === undefined) {
|
|
return _fun12244;
|
|
}
|
|
break reducibleJoin2;
|
|
}
|
|
reducibleLoop2: while (true) {
|
|
try {
|
|
closure(item);
|
|
} catch (error) {
|
|
try {
|
|
item2.return();
|
|
} catch {
|
|
}
|
|
throw error;
|
|
}
|
|
r2 = item2;
|
|
item2 = Reflect.apply(iterator2, r2, []);
|
|
item = item2.value;
|
|
item2 = item2.done ? undefined : r2;
|
|
if (item2 === undefined) {
|
|
break reducibleLoop2;
|
|
}
|
|
continue reducibleLoop2;
|
|
}
|
|
return _fun12244;
|
|
}
|
|
|
|
function initCanvasWebGLMutationObserver(a0, a1, a2, a3, a4, a5) { // fn#12246, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:14090, owner: value_12237.initCanvasWebGLMutationObserver, offset: 0x00dc489b, size: 195 bytes, params: 7, frame: 30
|
|
const items2 = [];
|
|
let push = items2.push;
|
|
const apply = push.apply;
|
|
const binding = env2_3;
|
|
const patchGLPrototypeBinding = patchGLPrototype;
|
|
const WebGLRenderingContext = a1.WebGLRenderingContext;
|
|
const prototype = WebGLRenderingContext.prototype;
|
|
const WebGL = env2_11.WebGL;
|
|
Reflect.apply(apply, push, [items2, binding(patchGLPrototypeBinding(prototype, WebGL, a0, a2, a3, a4, undefined,
|
|
a1))]);
|
|
const WebGL2RenderingContext = a1.WebGL2RenderingContext;
|
|
if (WebGL2RenderingContext !== undefined) {
|
|
push = items2.push;
|
|
push.apply(items2, env2_3(patchGLPrototype(a1.WebGL2RenderingContext.prototype, env2_11.WebGL2, a0, a2, a3, a4,
|
|
undefined, a1)));
|
|
}
|
|
return _fun12247;
|
|
}
|
|
|
|
function _fun12249() { // fn#12249, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:14509, offset: 0x00dc497a, size: 31 bytes, params: 1, frame: 10
|
|
env0_0();
|
|
env0_1();
|
|
env0_2();
|
|
}
|
|
|
|
function searchCanvas(a0) { // fn#12251, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:14613, owner: value_12250.searchCanvas, offset: 0x00dc4a5b, size: 39 bytes, params: 2, frame: 11
|
|
a0.querySelectorAll('canvas').forEach(_fun12252);
|
|
}
|
|
|
|
function _fun12254(a0) { // fn#12254, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:15220, offset: 0x00dc4b78, size: 299 bytes, params: 2, frame: 16
|
|
var preserveDrawingBuffer;
|
|
var snapshotInProgressMap;
|
|
var items2;
|
|
var value3;
|
|
var contextAttributes;
|
|
let env0_0 = a0;
|
|
var value;
|
|
const binding = env0_1;
|
|
let mirror = binding.mirror;
|
|
const id = mirror.getId(a0);
|
|
var env0_1 = id;
|
|
mirror = binding.mirror;
|
|
if (mirror.hasNode(a0)) {
|
|
if (a0.width) {
|
|
if (a0.height) {
|
|
snapshotInProgressMap = env0_1.snapshotInProgressMap;
|
|
if (!snapshotInProgressMap.get(id)) {
|
|
env0_1.snapshotInProgressMap.set(id, true);
|
|
if (!require) {
|
|
items2 = ['webgl', 'webgl2'];
|
|
if (items2.includes(a0.__context)) {
|
|
value = a0.getContext(a0.__context);
|
|
value3 = undefined;
|
|
if (value == null) {
|
|
preserveDrawingBuffer = value3;
|
|
} else {
|
|
contextAttributes = value.getContextAttributes();
|
|
preserveDrawingBuffer = contextAttributes == null ? value3 : contextAttributes.preserveDrawingBuffer;
|
|
}
|
|
if (preserveDrawingBuffer === false) {
|
|
value.clear(value.COLOR_BUFFER_BIT);
|
|
}
|
|
}
|
|
}
|
|
value = global.createImageBitmap(a0);
|
|
value = value.then(_fun12255);
|
|
value.catch(function(a0) {
|
|
var env0_0 = a0;
|
|
callbackWrapper_12206(_fun12257)();
|
|
});
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
function _fun12259() { // fn#12259, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:15947, offset: 0x00dc4d74, size: 19 bytes, params: 1, frame: 9
|
|
return env0_0.flushPendingCanvasMutations();
|
|
}
|
|
|
|
function setLatestRAFTimestamp(a0) { // fn#12261, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:16081, owner: value_12260.setLatestRAFTimestamp, offset: 0x00dc4da9, size: 42 bytes, params: 2, frame: 11
|
|
env0_0.rafStamps.latestId = a0;
|
|
onRequestAnimationFrame(setLatestRAFTimestamp);
|
|
}
|
|
|
|
function _fun12263(a0, a1) { // fn#12263, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:16323, offset: 0x00dc4e06, size: 45 bytes, params: 3, frame: 13
|
|
const binding = env0_0;
|
|
binding.flushPendingCanvasMutationFor(a1, binding.mirror.getId(a1));
|
|
}
|
|
|
|
function _fun12266(a0) { // fn#12266, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:16667, offset: 0x00dc4eb5, size: 29 bytes, params: 2, frame: 13
|
|
a0.type;
|
|
return env2_2(a0, env2_6);
|
|
}
|
|
|
|
function getCanvasManager(a0) { // fn#12271, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:18009, owner: _replayCanvasIntegration.getOptions.getCanvasManager, offset: 0x00dc5062, size: 107 bytes, params: 2, frame: 16
|
|
var environment;
|
|
let value = environment.__proto__.__proto__;
|
|
const binding = env2_18;
|
|
const Object = global.Object;
|
|
value = Object.assign({}, a0, {enableManualSnapshot: enableManualSnapshot, maxCanvasSize: maxCanvasSize,
|
|
errorHandler: function(a0) {
|
|
var value;
|
|
var error;
|
|
try {
|
|
value = typeof a0 !== 'object';
|
|
if (!value) {
|
|
a0.__rrweb__ = true;
|
|
}
|
|
} catch (error) {
|
|
}
|
|
}});
|
|
value = new binding(value);
|
|
env1_1(value);
|
|
return value;
|
|
}
|
|
|
|
function _fun12184() { // fn#12184, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:7772, offset: 0x00dc359e, size: 213 bytes, params: 1, frame: 24
|
|
var r0;
|
|
var value5;
|
|
var isBlocked_12170Binding;
|
|
var value8;
|
|
var value9;
|
|
let value = arguments.length;
|
|
const Array = global.Array;
|
|
const array = new Array(value);
|
|
const value4 = 0;
|
|
if (value4 < value) {
|
|
r0 = value4;
|
|
reducibleLoop1: while (true) {
|
|
array[r0] = arguments[r0];
|
|
value5 = typeof r0 === 'bigint' ? r0 + 1n : +r0 + 1;
|
|
if (value5 < value) {
|
|
r0 = value5;
|
|
continue reducibleLoop1;
|
|
}
|
|
break reducibleLoop1;
|
|
}
|
|
}
|
|
let binding = env0_0;
|
|
value = binding.apply(this, array);
|
|
saveWebGLVar(value, env2_6, this);
|
|
let canvas = this.canvas;
|
|
reducibleJoin5: while (true) {
|
|
if ('tagName' in canvas) {
|
|
isBlocked_12170Binding = isBlocked_12170;
|
|
canvas = this.canvas;
|
|
binding = env2_4;
|
|
if (isBlocked_12170Binding(canvas, importAll, binding, env2_5, true)) {
|
|
break reducibleJoin5;
|
|
}
|
|
value8 = serializeArgs(array, env2_6, this);
|
|
value9 = environment.__proto__;
|
|
canvas = this.canvas;
|
|
importDefault(canvas, {type: require, property: env1_0, args: value8});
|
|
break reducibleJoin5;
|
|
}
|
|
break reducibleJoin5;
|
|
}
|
|
return value;
|
|
}
|
|
|
|
function initCanvas2DMutationObserver_loop(a0) { // fn#12239, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:13395, owner: value_12237.initCanvas2DMutationObserver._loop, offset: 0x00dc4683, size: 176 bytes, params: 2, frame: 18
|
|
var environment;
|
|
var CanvasRenderingContext2D;
|
|
var prototype;
|
|
var property;
|
|
var value2;
|
|
var patch_12166Binding;
|
|
var closure;
|
|
var value4;
|
|
var binding;
|
|
var push;
|
|
var error;
|
|
var value5;
|
|
var hookSetter_12162Binding;
|
|
var value6;
|
|
let env0_0 = a0;
|
|
reducibleJoin3: while (true) {
|
|
reduciblePort22: while (true) {
|
|
exceptionLanding21: while (true) {
|
|
try {
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
break reducibleJoin3;
|
|
}
|
|
value5 = environment.__proto__.__proto__.__proto__;
|
|
hookSetter_12162Binding = hookSetter_12162;
|
|
CanvasRenderingContext2D = require.CanvasRenderingContext2D;
|
|
prototype = CanvasRenderingContext2D.prototype;
|
|
value6 = hookSetter_12162Binding(prototype, a0, {set: set_12243});
|
|
binding = env0_5;
|
|
push = binding.push;
|
|
Reflect.apply(push, binding, [value6]);
|
|
break reduciblePort22;
|
|
}
|
|
return undefined;
|
|
}
|
|
try {
|
|
CanvasRenderingContext2D = require.CanvasRenderingContext2D;
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
try {
|
|
prototype = CanvasRenderingContext2D.prototype;
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
try {
|
|
property = prototype[a0];
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
try {
|
|
value2 = typeof property !== 'function';
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
if (value2) {
|
|
return 1;
|
|
}
|
|
try {
|
|
patch_12166Binding = patch_12166;
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
try {
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
try {
|
|
CanvasRenderingContext2D = require.CanvasRenderingContext2D;
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
try {
|
|
prototype = CanvasRenderingContext2D.prototype;
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
try {
|
|
closure = function(a0) {
|
|
var env0_0 = a0;
|
|
return _fun12241;
|
|
};
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
try {
|
|
value4 = patch_12166Binding(prototype, a0, closure);
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
try {
|
|
binding = env0_5;
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
try {
|
|
push = binding.push;
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
try {
|
|
Reflect.apply(push, binding, [value4]);
|
|
} catch (error) {
|
|
break exceptionLanding21;
|
|
}
|
|
}
|
|
|
|
function _fun12244() { // fn#12244, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:13997, offset: 0x00dc487f, size: 28 bytes, params: 1, frame: 11
|
|
env0_5.forEach(function(a0) {
|
|
return a0();
|
|
});
|
|
}
|
|
|
|
function _fun12247() { // fn#12247, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:14379, offset: 0x00dc495e, size: 28 bytes, params: 1, frame: 11
|
|
env0_0.forEach(function(a0) {
|
|
return a0();
|
|
});
|
|
}
|
|
|
|
function _fun12252(a0) { // fn#12252, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:14676, offset: 0x00dc4a82, size: 57 bytes, params: 2, frame: 20
|
|
if (!isBlocked_12170(a0, env1_0, require, importDefault, true)) {
|
|
env1_3.push(a0);
|
|
}
|
|
}
|
|
|
|
function _fun12255(a0) { // fn#12255, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:15587, offset: 0x00dc4ca3, size: 106 bytes, params: 2, frame: 16
|
|
var postMessage;
|
|
var binding;
|
|
const worker = env1_1.worker;
|
|
if (worker != null) {
|
|
postMessage = worker.postMessage;
|
|
binding = env0_0;
|
|
Reflect.apply(postMessage, worker, [{id: env0_1, bitmap: a0, width: binding.width, height: binding.height,
|
|
dataURLOptions: dataURLOptions, maxCanvasSize: maxCanvasSize}, [a0]]);
|
|
}
|
|
}
|
|
|
|
function _fun12256(a0) { // fn#12256, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:15733, offset: 0x00dc4d0d, size: 34 bytes, params: 2, frame: 11
|
|
const env0_0 = a0;
|
|
callbackWrapper_12206(_fun12257)();
|
|
}
|
|
|
|
function _fun12240(a0) { // fn#12240, offset: 0x00dc4733, size: 16 bytes, params: 2, frame: 2
|
|
const env0_0 = a0;
|
|
return _fun12241;
|
|
}
|
|
|
|
function _loopSet(a0) { // fn#12243, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:13879, owner: value_12237.initCanvas2DMutationObserver._loop.set, offset: 0x00dc482f, size: 80 bytes, params: 2, frame: 14
|
|
env1_0(this.canvas, {type: env4_11['2D'], property: env0_0, args: [a0], setter: true});
|
|
}
|
|
|
|
function _fun12257() { // fn#12257, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:15748, offset: 0x00dc4d2f, size: 39 bytes, params: 1, frame: 11
|
|
env2_1.snapshotInProgressMap.delete(env1_1);
|
|
throw env0_0;
|
|
}
|
|
|
|
function _fun12241() { // fn#12241, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:13559, offset: 0x00dc4743, size: 151 bytes, params: 1, frame: 24
|
|
var environment;
|
|
var r1;
|
|
var value5;
|
|
const env0_0 = this;
|
|
let value = arguments.length;
|
|
const Array = global.Array;
|
|
const array = new Array(value);
|
|
const value4 = 0;
|
|
if (value4 < value) {
|
|
r1 = value4;
|
|
reducibleLoop1: while (true) {
|
|
array[r1] = arguments[r1];
|
|
value5 = typeof r1 === 'bigint' ? r1 + 1n : +r1 + 1;
|
|
if (value5 < value) {
|
|
r1 = value5;
|
|
continue reducibleLoop1;
|
|
}
|
|
break reducibleLoop1;
|
|
}
|
|
}
|
|
value = environment.__proto__.__proto__.__proto__.__proto__.__proto__;
|
|
reducibleJoin4: while (true) {
|
|
if (isBlocked_12170(this.canvas, importDefault, importAll, env2_4, true)) {
|
|
break reducibleJoin4;
|
|
}
|
|
setTimeout$1_12173(_fun12242, value4);
|
|
break reducibleJoin4;
|
|
}
|
|
return env0_0.apply(this, array);
|
|
}
|
|
|
|
function _fun12242() { // fn#12242, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1224:13703, offset: 0x00dc47da, size: 85 bytes, params: 1, frame: 17
|
|
const serializeArgsBinding = serializeArgs;
|
|
const binding = env0_1;
|
|
const binding2 = env0_0;
|
|
env3_0(binding2.canvas, {type: env6_11['2D'], property: env2_0, args: serializeArgsBinding(binding, require,
|
|
binding2)});
|
|
}
|
|
|