107 lines
4.3 KiB
React
107 lines
4.3 KiB
React
/* Metro module 4749; source: unknown; dependencies: [4748] */
|
|
function _fun40972(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#40972, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4927:6, offset: 0x0111196f, size: 118 bytes, params: 8, frame: 16
|
|
const getResolutionUnit = function(a0, a1, a2) {
|
|
if (10 > a2) {
|
|
return undefined;
|
|
}
|
|
var value2 = importDefault(dependencyMap[0]).getByteAt(a0, a1 + 9);
|
|
var object = {value: value2};
|
|
object.description = getResolutionUnitDescription(value2);
|
|
return object;
|
|
};
|
|
const getResolutionUnitDescription = function(a0) {
|
|
return a0 === 0 ? 'None' : a0 === 1 ? 'inches' : a0 !== 2 ? 'Unknown' : 'cm';
|
|
};
|
|
const Object = global.Object;
|
|
Object.defineProperty(exports, '__esModule', {value: true});
|
|
exports.default = {read: read_40978};
|
|
}
|
|
|
|
function getVersion(a0, a1, a2) { // fn#40973, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4927:950, offset: 0x011119e5, size: 133 bytes, params: 4, frame: 19
|
|
if (9 > a2) {
|
|
return undefined;
|
|
}
|
|
let value = importDefault(4748) /* metro dependency 4748 */;
|
|
value = value.getByteAt(a0, a1 + 7);
|
|
const byteAt = (importDefault(4748) /* metro dependency 4748 */).getByteAt(a0, a1 + 7 + 1);
|
|
return {value: 256 * value + byteAt, description: value + '.' + byteAt};
|
|
}
|
|
|
|
function getXResolution(a0, a1, a2) { // fn#40976, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4927:1326, offset: 0x01111aef, size: 78 bytes, params: 4, frame: 13
|
|
if (12 > a2) {
|
|
return undefined;
|
|
}
|
|
let value = importDefault(4748) /* metro dependency 4748 */;
|
|
value = value.getShortAt(a0, a1 + 10);
|
|
return {value: value, description: String(value)};
|
|
}
|
|
|
|
function getYResolution(a0, a1, a2) { // fn#40977, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4927:1436, offset: 0x01111b3d, size: 78 bytes, params: 4, frame: 13
|
|
if (14 > a2) {
|
|
return undefined;
|
|
}
|
|
let value = importDefault(4748) /* metro dependency 4748 */;
|
|
value = value.getShortAt(a0, a1 + 12);
|
|
return {value: value, description: String(value)};
|
|
}
|
|
|
|
function read_40978(a0, a1) { // fn#40978, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4927:104, offset: 0x01111b8b, size: 445 bytes, params: 3, frame: 24
|
|
var r7;
|
|
var r1;
|
|
var r3;
|
|
var byteAt;
|
|
var byteAt2;
|
|
var propertyName;
|
|
var propertyName2;
|
|
var value;
|
|
const value2 = undefined;
|
|
const shortAt = (importDefault(4748) /* metro dependency 4748 */).getShortAt(a0, a1);
|
|
if (15 > shortAt) {
|
|
r7 = value2;
|
|
} else {
|
|
byteAt = (importDefault(4748) /* metro dependency 4748 */).getByteAt(a0, a1 + 14);
|
|
r7 = {value: byteAt, description: '' + byteAt + 'px'};
|
|
}
|
|
if (16 > shortAt) {
|
|
r1 = value2;
|
|
} else {
|
|
byteAt2 = (importDefault(4748) /* metro dependency 4748 */).getByteAt(a0, a1 + 15);
|
|
r1 = {value: byteAt2, description: '' + byteAt2 + 'px'};
|
|
}
|
|
const object2 = {};
|
|
object2['JFIF Version'] = getVersion(a0, a1, shortAt);
|
|
object2['Resolution Unit'] = getResolutionUnit(a0, a1, shortAt);
|
|
object2.XResolution = getXResolution(a0, a1, shortAt);
|
|
object2.YResolution = getYResolution(a0, a1, shortAt);
|
|
object2['JFIF Thumbnail Width'] = r7;
|
|
object2['JFIF Thumbnail Height'] = r1;
|
|
if (value2 !== r7) {
|
|
if (value2 !== r1) {
|
|
value = r7.value;
|
|
value = 3 * value;
|
|
value *= r1.value;
|
|
if (value === 0) {
|
|
r1 = value2;
|
|
} else if (16 + value > shortAt) {
|
|
r1 = value2;
|
|
} else {
|
|
value = a0.buffer.slice(a1 + 16, a1 + 16 + value);
|
|
r1 = {value: value, description: '<24-bit RGB pixel data>'};
|
|
}
|
|
if (r1) {
|
|
object2['JFIF Thumbnail'] = r1;
|
|
}
|
|
}
|
|
}
|
|
for (propertyName in object2) {
|
|
if (value2 !== object2[propertyName]) {
|
|
r3 = propertyName2;
|
|
continue;
|
|
}
|
|
delete object2[propertyName];
|
|
r3 = propertyName2;
|
|
}
|
|
return object2;
|
|
}
|
|
|