decord/source/5402__isNativeReflectConstruct.js

269 lines
7.9 KiB
JavaScript
Raw Normal View History

2026-07-23 10:11:24 +00:00
// Module ID: 5402
2026-07-24 07:16:23 +00:00
// Function ID: 46302
2026-07-20 16:05:17 +00:00
// Name: _isNativeReflectConstruct
2026-07-23 10:11:24 +00:00
// Dependencies: [5368, 5369, 5391, 5393, 5394, 5396, 5398]
// Module 5402 (_isNativeReflectConstruct)
import _classCallCheck from "_classCallCheck";
import _defineProperties from "_defineProperties";
import _possibleConstructorReturn from "_possibleConstructorReturn";
import _getPrototypeOf from "_getPrototypeOf";
import _get from "_get";
import _inherits from "_inherits";
2026-07-20 16:05:17 +00:00
function _isNativeReflectConstruct() {
2026-07-23 10:11:24 +00:00
let _classCallCheck = !valueOf.call(Reflect.construct(Boolean, [], () => {
2026-07-20 16:05:17 +00:00
}));
function _isNativeReflectConstruct() {
2026-07-23 10:11:24 +00:00
return _classCallCheck;
2026-07-20 16:05:17 +00:00
}
const result = _isNativeReflectConstruct();
}
2026-07-23 10:11:24 +00:00
export const RVLinearLayoutManagerImpl = ((RVLayoutManager) => {
2026-07-21 22:01:30 +00:00
class RVLinearLayoutManagerImpl {
2026-07-20 16:05:17 +00:00
constructor(arg0, arg1) {
self = this;
2026-07-21 22:01:30 +00:00
tmp = RVLinearLayoutManagerImpl(this, RVLinearLayoutManagerImpl);
2026-07-20 16:05:17 +00:00
items = [, ];
items[0] = RVLayoutManager;
items[1] = arg1;
2026-07-23 10:11:24 +00:00
obj = outer1_3(RVLinearLayoutManagerImpl);
tmp2 = outer1_2;
if (outer1_6()) {
2026-07-20 16:05:17 +00:00
tmp4 = globalThis;
_Reflect = Reflect;
2026-07-23 10:11:24 +00:00
tmp5 = outer1_3;
constructResult = Reflect.construct(obj, items, outer1_3(self).constructor);
2026-07-20 16:05:17 +00:00
} else {
constructResult = obj.apply(self, items);
}
tmp2Result = tmp2(self, constructResult);
2026-07-21 22:01:30 +00:00
tmp2Result.hasSize = false;
tmp2Result.tallestItemHeight = 0;
windowSize = RVLayoutManager.windowSize;
tmp2Result.boundedSize = tmp2Result.horizontal ? windowSize.height : windowSize.width;
tmp2Result.hasSize = tmp2Result.boundedSize > 0;
2026-07-20 16:05:17 +00:00
return tmp2Result;
}
}
2026-07-21 22:01:30 +00:00
callback2(RVLinearLayoutManagerImpl, RVLayoutManager);
2026-07-20 16:05:17 +00:00
let obj = {
key: "updateLayoutParams",
value: function updateLayoutParams(windowSize) {
const self = this;
const items = [windowSize];
2026-07-23 10:11:24 +00:00
!(function _superPropGet(RVLinearLayoutManagerImpl, updateLayoutParams, arg2, arg3) {
let _classCallCheck = arg2;
2026-07-21 22:01:30 +00:00
let prototype = RVLinearLayoutManagerImpl;
2026-07-20 16:05:17 +00:00
if (1) {
2026-07-21 22:01:30 +00:00
prototype = RVLinearLayoutManagerImpl.prototype;
2026-07-20 16:05:17 +00:00
}
2026-07-23 10:11:24 +00:00
const tmpResult = outer2_4(outer2_3(prototype), "updateLayoutParams", arg2);
let _defineProperties = tmpResult;
2026-07-20 16:05:17 +00:00
let fn = tmpResult;
if (2) {
fn = tmpResult;
if ("function" === typeof tmpResult) {
2026-07-23 10:11:24 +00:00
fn = (arg0) => tmpResult.apply(_classCallCheck, arg0);
2026-07-20 16:05:17 +00:00
}
}
return fn;
2026-07-23 10:11:24 +00:00
})(RVLinearLayoutManagerImpl, "updateLayoutParams", this, 3)(items);
2026-07-21 22:01:30 +00:00
windowSize = windowSize.windowSize;
self.boundedSize = this.horizontal ? windowSize.height : windowSize.width;
2026-07-20 16:05:17 +00:00
if (!tmp2) {
if (self.layouts.length > 0) {
self.recomputeLayouts(0, self.layouts.length - 1);
self.requiresRepaint = true;
}
}
}
};
2026-07-23 10:11:24 +00:00
let items = [obj, , , , , ];
2026-07-20 16:05:17 +00:00
obj = {
key: "processLayoutInfo",
value: function processLayoutInfo(arg0, arg1) {
const self = this;
const iter = arg0[Symbol.iterator]();
const nextResult = iter.next();
while (iter !== undefined) {
2026-07-21 22:01:30 +00:00
let dimensions = nextResult.dimensions;
2026-07-20 16:05:17 +00:00
let tmp2 = self.layouts[nextResult.index];
2026-07-21 22:01:30 +00:00
let tmp3 = tmp2;
if (self.horizontal) {
let tmp4 = dimensions;
let boundedSize = dimensions.width;
} else {
boundedSize = self.boundedSize;
}
tmp2.width = boundedSize;
let tmp5 = tmp2;
tmp3.isHeightMeasured = true;
tmp3.isWidthMeasured = true;
let tmp6 = dimensions;
tmp3.height = dimensions.height;
2026-07-23 10:11:24 +00:00
continue;
2026-07-20 16:05:17 +00:00
}
2026-07-21 22:01:30 +00:00
if (tmp7) {
const result = self.normalizeLayoutHeights(arg0);
2026-07-20 16:05:17 +00:00
}
}
};
items[1] = obj;
obj = {
key: "estimateLayout",
value: function estimateLayout(arg0) {
2026-07-21 22:01:30 +00:00
const self = this;
if (this.horizontal) {
let boundedSize = self.getEstimatedWidth(arg0);
} else {
boundedSize = self.boundedSize;
}
2026-07-23 10:11:24 +00:00
this.layouts[arg0].width = boundedSize;
this.layouts[arg0].height = self.getEstimatedHeight(arg0);
this.layouts[arg0].isWidthMeasured = !self.horizontal;
this.layouts[arg0].enforcedWidth = !self.horizontal;
2026-07-20 16:05:17 +00:00
}
};
items[2] = obj;
items[3] = {
key: "getLayoutSize",
value: function getLayoutSize() {
const self = this;
if (0 === this.layouts.length) {
2026-07-23 10:11:24 +00:00
return { width: 0, height: 0 };
2026-07-20 16:05:17 +00:00
} else {
2026-07-21 22:01:30 +00:00
const size = self.layouts[self.layouts.length - 1];
const obj = {};
if (self.horizontal) {
let boundedSize = size.x + size.width;
} else {
boundedSize = self.boundedSize;
}
obj.width = boundedSize;
if (self.horizontal) {
const tallestItem = self.tallestItem;
let height;
if (null != tallestItem) {
height = tallestItem.height;
2026-07-20 16:05:17 +00:00
}
2026-07-21 22:01:30 +00:00
if (null == height) {
height = self.boundedSize;
}
let sum = height;
} else {
sum = size.y + size.height;
}
obj.height = sum;
return obj;
2026-07-20 16:05:17 +00:00
}
}
};
2026-07-21 22:01:30 +00:00
items[4] = {
key: "normalizeLayoutHeights",
value: function normalizeLayoutHeights(arg0) {
2026-07-20 16:05:17 +00:00
const self = this;
2026-07-21 22:01:30 +00:00
let tmp;
const iter = arg0[Symbol.iterator]();
while (iter !== undefined) {
let tmp2 = self.layouts[iter.next().index];
let minHeight = tmp2.minHeight;
let tmp4 = minHeight;
let num = 0;
let tmp3 = tmp2;
if (null != minHeight) {
num = minHeight;
}
let tmp5 = tmp2.height > num;
let tmp6 = tmp5;
if (tmp5) {
let tmp7 = tmp2;
let height;
if (null != tmp) {
let tmp10 = tmp;
height = tmp8.height;
2026-07-20 16:05:17 +00:00
}
2026-07-21 22:01:30 +00:00
let tmp11 = height;
let num2 = 0;
if (null != height) {
num2 = height;
2026-07-20 16:05:17 +00:00
}
2026-07-21 22:01:30 +00:00
tmp6 = tmp3.height > num2;
2026-07-20 16:05:17 +00:00
}
2026-07-21 22:01:30 +00:00
if (tmp6) {
tmp = tmp2;
}
2026-07-23 10:11:24 +00:00
continue;
2026-07-20 16:05:17 +00:00
}
2026-07-21 22:01:30 +00:00
if (tmp) {
if (tmp.height !== self.tallestItemHeight) {
let num3 = tmp.height;
if (tmp.height < self.tallestItemHeight) {
2026-07-20 16:05:17 +00:00
self.requiresRepaint = true;
2026-07-21 22:01:30 +00:00
num3 = 0;
2026-07-20 16:05:17 +00:00
}
2026-07-21 22:01:30 +00:00
const layouts = self.layouts;
for (const item10046 of layouts) {
let tmp14 = item10046;
let tmp15 = num3;
if (num3 > 0) {
let tmp16 = item10046;
let tmp17 = tmp;
tmp14.height = tmp.height;
2026-07-20 16:05:17 +00:00
}
2026-07-21 22:01:30 +00:00
let tmp18 = item10046;
let tmp19 = num3;
tmp14.minHeight = num3;
2026-07-23 10:11:24 +00:00
continue;
2026-07-20 16:05:17 +00:00
}
2026-07-21 22:01:30 +00:00
tmp.minHeight = 0;
self.tallestItem = tmp;
self.tallestItemHeight = tmp.height;
2026-07-20 16:05:17 +00:00
}
}
}
};
2026-07-21 22:01:30 +00:00
items[5] = {
key: "recomputeLayouts",
value: function recomputeLayouts(arg0, arg1) {
let sum = arg0;
2026-07-20 16:05:17 +00:00
const self = this;
2026-07-21 22:01:30 +00:00
if (arg0 <= arg1) {
2026-07-20 16:05:17 +00:00
do {
2026-07-21 22:01:30 +00:00
let layout = self.getLayout(sum);
let tmp4 = sum;
if (0 === sum) {
layout.x = 0;
layout.y = 0;
let size = tmp2;
} else {
size = self.getLayout(sum - 1);
let num = 0;
if (self.horizontal) {
num = size.x + size.width;
2026-07-20 16:05:17 +00:00
}
2026-07-21 22:01:30 +00:00
layout.x = num;
let num2 = 0;
if (!self.horizontal) {
num2 = size.y + size.height;
}
layout.y = num2;
2026-07-20 16:05:17 +00:00
}
2026-07-21 22:01:30 +00:00
if (self.horizontal) {
if (self.hasSize) {
layout.minHeight = self.boundedSize;
}
} else {
layout.width = self.boundedSize;
2026-07-20 16:05:17 +00:00
}
2026-07-21 22:01:30 +00:00
sum = sum + 1;
2026-07-23 10:11:24 +00:00
tmp2 = size;
2026-07-21 22:01:30 +00:00
} while (sum <= arg1);
2026-07-20 16:05:17 +00:00
}
}
};
2026-07-21 22:01:30 +00:00
return callback(RVLinearLayoutManagerImpl, items);
2026-07-23 10:11:24 +00:00
})(require("RVLayoutManager").RVLayoutManager);