2026-08-05 07:35:12 +00:00
|
|
|
// Module ID: 5535
|
|
|
|
|
// Function ID: 5536
|
2026-07-20 16:05:17 +00:00
|
|
|
// Name: _isNativeReflectConstruct
|
2026-08-05 07:35:12 +00:00
|
|
|
// Dependencies: [5505, 5506, 5524, 5526, 5527, 5529, 5531]
|
2026-07-23 10:11:24 +00:00
|
|
|
|
2026-08-05 07:35:12 +00:00
|
|
|
// Module 5535 (_isNativeReflectConstruct)
|
2026-07-29 08:29:29 +00:00
|
|
|
import RVLinearLayoutManagerImpl from "_classCallCheck";
|
2026-07-23 10:11:24 +00:00
|
|
|
import _possibleConstructorReturn from "_possibleConstructorReturn";
|
|
|
|
|
import _getPrototypeOf from "_getPrototypeOf";
|
|
|
|
|
import _get from "_get";
|
2026-07-29 08:29:29 +00:00
|
|
|
import importDefaultResult from "_createClass";
|
2026-07-20 16:05:17 +00:00
|
|
|
|
|
|
|
|
function _isNativeReflectConstruct() {
|
2026-07-29 08:29:29 +00:00
|
|
|
try {
|
|
|
|
|
const _Boolean = Boolean;
|
|
|
|
|
const call = valueOf.call;
|
|
|
|
|
const _Reflect = Reflect;
|
|
|
|
|
const _Boolean2 = Boolean;
|
|
|
|
|
if (typeof call === "unknown") {
|
|
|
|
|
let callResult = valueOf();
|
|
|
|
|
} else {
|
|
|
|
|
callResult = call(constructResult);
|
|
|
|
|
}
|
|
|
|
|
let closure_0 = !callResult;
|
|
|
|
|
function _isNativeReflectConstruct() {
|
|
|
|
|
return closure_0;
|
|
|
|
|
}
|
|
|
|
|
return _isNativeReflectConstruct();
|
|
|
|
|
} catch (err) {
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
|
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
class RVLinearLayoutManagerImpl {
|
|
|
|
|
constructor(arg0, arg1) {
|
|
|
|
|
self = this;
|
|
|
|
|
tmp = RVLinearLayoutManagerImpl(this, RVLinearLayoutManagerImpl);
|
|
|
|
|
items = [, ];
|
|
|
|
|
items[0] = global;
|
|
|
|
|
items[1] = arg1;
|
|
|
|
|
tmp2 = __esModule;
|
|
|
|
|
obj = __esModule(RVLinearLayoutManagerImpl);
|
|
|
|
|
tmp3 = __esModule;
|
|
|
|
|
if (_isNativeReflectConstruct()) {
|
|
|
|
|
tmp5 = globalThis;
|
|
|
|
|
_Reflect = Reflect;
|
|
|
|
|
constructResult = Reflect.construct(obj, items, tmp2(self).constructor);
|
|
|
|
|
} else {
|
|
|
|
|
constructResult = obj.apply(self, items);
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
tmp3Result = tmp3(self, constructResult);
|
|
|
|
|
tmp3Result.hasSize = false;
|
|
|
|
|
tmp3Result.tallestItemHeight = 0;
|
|
|
|
|
windowSize = global.windowSize;
|
|
|
|
|
tmp3Result.boundedSize = tmp3Result.horizontal ? windowSize.height : windowSize.width;
|
|
|
|
|
tmp3Result.hasSize = tmp3Result.boundedSize > 0;
|
|
|
|
|
return tmp3Result;
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
}
|
|
|
|
|
require("_inherits")(RVLinearLayoutManagerImpl, require("RVLayoutManager").RVLayoutManager);
|
|
|
|
|
let items = [
|
|
|
|
|
{
|
2026-07-20 16:05:17 +00:00
|
|
|
key: "updateLayoutParams",
|
|
|
|
|
value: function updateLayoutParams(windowSize) {
|
2026-07-29 08:29:29 +00:00
|
|
|
let self = this;
|
|
|
|
|
self = this;
|
|
|
|
|
let fn;
|
|
|
|
|
fn = callback2(callback(self.prototype), "updateLayoutParams", this);
|
2026-08-04 21:03:28 +00:00
|
|
|
if (typeof fn === "function") {
|
2026-07-29 08:29:29 +00:00
|
|
|
fn = (items) => fn.apply(self, items);
|
|
|
|
|
}
|
2026-07-20 16:05:17 +00:00
|
|
|
const items = [windowSize];
|
2026-07-29 08:29:29 +00:00
|
|
|
!fn(items);
|
2026-07-21 22:01:30 +00:00
|
|
|
windowSize = windowSize.windowSize;
|
2026-07-29 08:29:29 +00:00
|
|
|
self.boundedSize = self.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-29 08:29:29 +00:00
|
|
|
},
|
|
|
|
|
{
|
2026-07-20 16:05:17 +00:00
|
|
|
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
|
|
|
}
|
|
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
},
|
|
|
|
|
{
|
2026-07-20 16:05:17 +00:00
|
|
|
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
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
},
|
|
|
|
|
{
|
2026-07-20 16:05:17 +00:00
|
|
|
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];
|
|
|
|
|
if (self.horizontal) {
|
|
|
|
|
let boundedSize = size.x + size.width;
|
|
|
|
|
} else {
|
|
|
|
|
boundedSize = self.boundedSize;
|
|
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
const obj = { width: null, height: null };
|
|
|
|
|
obj[0] = boundedSize;
|
2026-07-21 22:01:30 +00:00
|
|
|
if (self.horizontal) {
|
|
|
|
|
const tallestItem = self.tallestItem;
|
|
|
|
|
let height;
|
2026-07-29 08:29:29 +00:00
|
|
|
if (tallestItem != null) {
|
2026-07-21 22:01:30 +00:00
|
|
|
height = tallestItem.height;
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
if (height == null) {
|
2026-07-21 22:01:30 +00:00
|
|
|
height = self.boundedSize;
|
|
|
|
|
}
|
|
|
|
|
let sum = height;
|
|
|
|
|
} else {
|
|
|
|
|
sum = size.y + size.height;
|
|
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
obj[1] = sum;
|
2026-07-21 22:01:30 +00:00
|
|
|
return obj;
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
|
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
},
|
|
|
|
|
{
|
2026-07-21 22:01:30 +00:00
|
|
|
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];
|
2026-07-29 08:29:29 +00:00
|
|
|
let num = tmp2.minHeight;
|
2026-07-21 22:01:30 +00:00
|
|
|
let tmp3 = tmp2;
|
2026-07-29 08:29:29 +00:00
|
|
|
if (num == null) {
|
|
|
|
|
num = 0;
|
2026-07-21 22:01:30 +00:00
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
let tmp4 = tmp2.height > num;
|
|
|
|
|
if (tmp4) {
|
|
|
|
|
let tmp5 = tmp2;
|
|
|
|
|
let tmp6 = tmp;
|
|
|
|
|
let num2;
|
|
|
|
|
if (tmp != null) {
|
|
|
|
|
num2 = tmp.height;
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
if (num2 == null) {
|
|
|
|
|
num2 = 0;
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
tmp4 = tmp3.height > num2;
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
if (tmp4) {
|
2026-07-21 22:01:30 +00:00
|
|
|
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;
|
2026-07-29 08:29:29 +00:00
|
|
|
for (const item10035 of layouts) {
|
|
|
|
|
let tmp10 = item10035;
|
2026-07-21 22:01:30 +00:00
|
|
|
if (num3 > 0) {
|
2026-07-29 08:29:29 +00:00
|
|
|
let tmp11 = item10035;
|
|
|
|
|
let tmp12 = tmp;
|
|
|
|
|
tmp10.height = tmp.height;
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
let tmp13 = item10035;
|
|
|
|
|
tmp10.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-29 08:29:29 +00:00
|
|
|
},
|
|
|
|
|
{
|
2026-07-21 22:01:30 +00:00
|
|
|
key: "recomputeLayouts",
|
|
|
|
|
value: function recomputeLayouts(arg0, arg1) {
|
2026-07-20 16:05:17 +00:00
|
|
|
const self = this;
|
2026-07-29 08:29:29 +00:00
|
|
|
let sum = arg0;
|
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);
|
2026-07-29 08:29:29 +00:00
|
|
|
let tmp3 = sum;
|
2026-07-21 22:01:30 +00:00
|
|
|
if (0 === sum) {
|
|
|
|
|
layout.x = 0;
|
|
|
|
|
layout.y = 0;
|
|
|
|
|
} else {
|
2026-07-29 08:29:29 +00:00
|
|
|
let size = self.getLayout(sum - 1);
|
2026-07-21 22:01:30 +00:00
|
|
|
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;
|
|
|
|
|
} while (sum <= arg1);
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
|
|
|
|
}
|
2026-07-29 08:29:29 +00:00
|
|
|
}
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
export const RVLinearLayoutManagerImpl = importDefaultResult(RVLinearLayoutManagerImpl, items);
|