decord/source/stores/views/ActivityLauncherStore.tsx

215 lines
6.2 KiB
TypeScript
Raw Normal View History

2026-07-24 07:16:23 +00:00
// Module ID: 10472
// Function ID: 80709
2026-07-20 16:05:17 +00:00
// Name: _isNativeReflectConstruct
2026-07-24 07:16:23 +00:00
// Dependencies: [6, 7, 15, 17, 18, 10473, 4810, 653, 4015, 686, 566, 2]
2026-07-20 16:05:17 +00:00
2026-07-24 07:16:23 +00:00
// Module 10472 (_isNativeReflectConstruct)
2026-07-23 10:11:24 +00:00
import _isNativeReflectConstruct from "_isNativeReflectConstruct";
import closure_4 from "ME";
import _possibleConstructorReturn from "_possibleConstructorReturn";
import _getPrototypeOf from "_getPrototypeOf";
import _inherits from "_inherits";
import closure_8 from "_isNativeReflectConstruct";
import closure_9 from "_isNativeReflectConstruct";
import ME from "ME";
let closure_10;
let closure_11;
const require = arg1;
2026-07-20 16:05:17 +00:00
function _isNativeReflectConstruct() {
let closure_0 = !valueOf.call(Reflect.construct(Boolean, [], () => {
}));
function _isNativeReflectConstruct() {
return closure_0;
}
const result = _isNativeReflectConstruct();
}
2026-07-23 10:11:24 +00:00
function startActivityLaunchTimeout(applicationId, JOIN, c14) {
const _require = applicationId;
let closure_1 = JOIN;
if (null != dependencyMap2[applicationId]) {
dependencyMap2[applicationId].stop();
let obj = dependencyMap2[applicationId];
2026-07-20 16:05:17 +00:00
}
2026-07-23 10:11:24 +00:00
const timeout = new _require(4015).Timeout();
timeout.start(c14, () => {
let obj = JOIN(outer1_2[9]);
obj = { type: "ACTIVITY_LAUNCH_FAIL", applicationId: closure_0, activityType: JOIN };
2026-07-20 16:05:17 +00:00
return obj.dispatch(obj);
});
2026-07-23 10:11:24 +00:00
dependencyMap2[applicationId] = timeout;
2026-07-20 16:05:17 +00:00
}
function handleActivityStateChanged(COMPLETE, JOIN, type) {
let applicationId;
let remotePartyId;
({ applicationId, remotePartyId } = type);
if (COMPLETE === constants.COMPLETE) {
2026-07-23 10:11:24 +00:00
if (null != dependencyMap[applicationId]) {
delete tmp[tmp4];
2026-07-20 16:05:17 +00:00
}
2026-07-23 10:11:24 +00:00
if (null != dependencyMap2[applicationId]) {
dependencyMap2[applicationId].stop();
delete tmp2[tmp3];
const obj3 = dependencyMap2[applicationId];
2026-07-20 16:05:17 +00:00
}
} else {
2026-07-23 10:11:24 +00:00
let obj = dependencyMap[applicationId];
2026-07-20 16:05:17 +00:00
if (null == obj) {
obj = {};
}
obj = { state: COMPLETE, remotePartyId };
obj[JOIN] = obj;
2026-07-23 10:11:24 +00:00
dependencyMap[applicationId] = obj;
2026-07-20 16:05:17 +00:00
if (COMPLETE === constants.FAILED) {
2026-07-23 10:11:24 +00:00
startActivityLaunchTimeout(applicationId, JOIN, c14);
2026-07-20 16:05:17 +00:00
} else if (COMPLETE === constants.LOADING) {
let num = 15000;
if (null == remotePartyId) {
2026-07-23 10:11:24 +00:00
num = c14;
2026-07-20 16:05:17 +00:00
}
startActivityLaunchTimeout(applicationId, JOIN, num);
2026-07-23 10:11:24 +00:00
const tmp10 = startActivityLaunchTimeout;
2026-07-20 16:05:17 +00:00
}
}
}
function handleActivityComplete(type) {
let tmp = "ACTIVITY_JOIN" !== type.type;
if (!tmp) {
tmp = null == type.parentApplicationId;
}
if (tmp) {
tmp = handleActivityStateChanged(constants.COMPLETE, constants2.JOIN, type);
}
return tmp;
}
function handleActivityUpdate() {
const entries = Object.entries(closure_12);
const mapped = entries.map((arg0) => {
let tmp;
let tmp2;
[tmp, tmp2] = arg0;
const obj = { applicationId: tmp };
let remotePartyId;
2026-07-23 10:11:24 +00:00
if (null != tmp2[outer1_11.JOIN]) {
2026-07-20 16:05:17 +00:00
remotePartyId = tmp3.remotePartyId;
}
obj.remotePartyId = remotePartyId;
return obj;
});
const found = mapped.filter((remotePartyId) => null != remotePartyId.remotePartyId);
2026-07-23 10:11:24 +00:00
let c0 = false;
2026-07-20 16:05:17 +00:00
const item = found.forEach((arg0) => {
let applicationId;
let remotePartyId;
({ applicationId, remotePartyId } = arg0);
2026-07-23 10:11:24 +00:00
const applicationActivity = outer1_8.getApplicationActivity(applicationId);
const applicationActivity1 = outer1_9.getApplicationActivity(applicationId);
2026-07-20 16:05:17 +00:00
let id;
if (null != applicationActivity) {
const party = applicationActivity.party;
if (null != party) {
id = party.id;
}
}
let tmp4 = id !== remotePartyId;
if (tmp4) {
let id1;
if (null != applicationActivity1) {
const party2 = applicationActivity1.party;
if (null != party2) {
id1 = party2.id;
}
}
tmp4 = id1 !== remotePartyId;
}
if (!tmp4) {
const obj = { applicationId, remotePartyId };
2026-07-23 10:11:24 +00:00
outer1_17(outer1_10.COMPLETE, outer1_11.JOIN, obj);
let c0 = true;
2026-07-20 16:05:17 +00:00
}
});
2026-07-23 10:11:24 +00:00
return c0;
2026-07-20 16:05:17 +00:00
}
2026-07-23 10:11:24 +00:00
({ ActivityActionStates: closure_10, ActivityActionTypes: closure_11 } = ME);
2026-07-20 16:05:17 +00:00
let closure_12 = {};
let closure_13 = {};
2026-07-23 10:11:24 +00:00
let c14 = 120000;
let tmp3 = ((Store) => {
2026-07-20 16:05:17 +00:00
class ActivityLauncherStore {
constructor() {
self = this;
2026-07-23 10:11:24 +00:00
tmp = outer1_3(this, ActivityLauncherStore);
obj = outer1_6(ActivityLauncherStore);
tmp2 = outer1_5;
if (outer1_15()) {
2026-07-20 16:05:17 +00:00
tmp6 = globalThis;
_Reflect = Reflect;
2026-07-23 10:11:24 +00:00
tmp7 = outer1_6;
2026-07-20 16:05:17 +00:00
tmp8 = arguments;
2026-07-23 10:11:24 +00:00
constructResult = Reflect.construct(obj, arguments, outer1_6(self).constructor);
2026-07-20 16:05:17 +00:00
} else {
tmp3 = arguments;
tmp4 = arguments;
constructResult = obj(...arguments);
}
return tmp2(self, constructResult);
}
}
callback2(ActivityLauncherStore, Store);
let obj = {
key: "initialize",
value() {
2026-07-23 10:11:24 +00:00
const items = [outer1_8, outer1_9];
this.syncWith(items, outer1_18);
2026-07-20 16:05:17 +00:00
}
};
2026-07-23 10:11:24 +00:00
let items = [obj, , ];
2026-07-20 16:05:17 +00:00
obj = {
key: "getState",
value(arg0, arg1) {
let state;
2026-07-23 10:11:24 +00:00
if (null != outer1_12[arg0]) {
2026-07-20 16:05:17 +00:00
if (null != tmp[arg1]) {
state = tmp4.state;
}
}
return state;
}
};
items[1] = obj;
obj = {
key: "getStates",
value() {
2026-07-23 10:11:24 +00:00
return outer1_12;
2026-07-20 16:05:17 +00:00
}
};
items[2] = obj;
return callback(ActivityLauncherStore, items);
2026-07-23 10:11:24 +00:00
})(require("initialize").Store);
2026-07-20 16:05:17 +00:00
tmp3.displayName = "ActivityLauncherStore";
2026-07-23 10:11:24 +00:00
tmp3 = new tmp3(require("dispatcher"), {
2026-07-20 16:05:17 +00:00
OVERLAY_INITIALIZE: function handleOverlayInitialize(activityLauncherStates) {
2026-07-23 10:11:24 +00:00
const obj = {};
2026-07-20 16:05:17 +00:00
const merged = Object.assign(activityLauncherStates.activityLauncherStates);
},
ACTIVITY_JOIN_LOADING(type) {
return handleActivityStateChanged(constants.LOADING, constants2.JOIN, type);
},
ACTIVITY_JOIN_FAILED(type) {
return handleActivityStateChanged(constants.FAILED, constants2.JOIN, type);
},
ACTIVITY_JOIN: handleActivityComplete,
EMBEDDED_ACTIVITY_CLOSE: handleActivityComplete,
ACTIVITY_LAUNCH_FAIL: function handleActivityLaunchFail(arg0) {
2026-07-23 10:11:24 +00:00
if (null == dependencyMap[arg0.applicationId]) {
2026-07-20 16:05:17 +00:00
return false;
} else {
2026-07-23 10:11:24 +00:00
delete tmp[tmp2];
2026-07-20 16:05:17 +00:00
}
}
});
2026-07-23 10:11:24 +00:00
let result = require("_possibleConstructorReturn").fileFinishedImporting("stores/views/ActivityLauncherStore.tsx");
2026-07-20 16:05:17 +00:00
export default tmp3;