decord/source/modules/video_calls/native/useIsPrivateAudioOnlyCall.tsx

62 lines
2.1 KiB
TypeScript
Raw Normal View History

2026-07-29 08:29:29 +00:00
// Module ID: 10237
// Function ID: 10238
2026-07-20 16:05:17 +00:00
// Name: areParticipantStatesEqual
2026-07-29 08:29:29 +00:00
// Dependencies: [32, 1371, 4202, 4208, 4236, 4205, 4207, 589, 2]
2026-07-20 16:05:17 +00:00
// Exports: default
2026-07-29 08:29:29 +00:00
// Module 10237 (areParticipantStatesEqual)
2026-07-23 10:11:24 +00:00
import _slicedToArray from "_slicedToArray";
2026-07-29 08:29:29 +00:00
import participantFromServer from "participantFromServer";
import getParticipants from "getParticipants";
import reset from "reset";
import _detectH265HardwareDecode from "_detectH265HardwareDecode";
import updateVoiceState from "updateVoiceState";
2026-07-23 10:11:24 +00:00
import { isActivityParticipant } from "ParticipantTypes";
const require = arg1;
2026-07-20 16:05:17 +00:00
function areParticipantStatesEqual(arg0, arg1) {
let tmp;
let tmp2;
[, tmp] = arg0;
[, tmp2] = arg1;
return tmp === tmp2;
}
2026-07-29 08:29:29 +00:00
const result = require("getParticipants").fileFinishedImporting("modules/video_calls/native/useIsPrivateAudioOnlyCall.tsx");
2026-07-20 16:05:17 +00:00
export default function useIsPrivateAudioOnlyCall(id) {
2026-07-23 10:11:24 +00:00
const _require = id;
2026-07-29 08:29:29 +00:00
let items = [getParticipants];
2026-07-20 16:05:17 +00:00
const items1 = [id];
2026-07-29 08:29:29 +00:00
let tmp3 = embeddedActivitiesForChannel.getEmbeddedActivitiesForChannel(id.id).length > 0;
if (!tmp3) {
tmp3 = isActivityParticipant(callback(obj.useStateFromStores(items, () => {
2026-07-23 10:11:24 +00:00
const items = [outer1_4.getSelectedParticipant(_private.id), outer1_4.getParticipantsVersion(_private.id)];
2026-07-20 16:05:17 +00:00
return items;
}, items1, areParticipantStatesEqual), 1)[0]);
}
2026-07-29 08:29:29 +00:00
const dependencyMap = tmp3;
obj = _require(589);
const tmp = _require;
const items2 = [updateVoiceState, _detectH265HardwareDecode, reset];
const items3 = [id, tmp3];
return _require(589).useStateFromStores(items2, () => {
2026-07-23 10:11:24 +00:00
let isPrivateResult = _private.isPrivate();
2026-07-20 16:05:17 +00:00
if (isPrivateResult) {
2026-07-29 08:29:29 +00:00
isPrivateResult = !outer1_7.hasVideo(tmp.id);
2026-07-20 16:05:17 +00:00
}
if (isPrivateResult) {
2026-07-23 10:11:24 +00:00
isPrivateResult = !closure_1;
2026-07-20 16:05:17 +00:00
}
if (isPrivateResult) {
2026-07-29 08:29:29 +00:00
isPrivateResult = 0 === outer1_5.getAllApplicationStreamsForChannel(tmp.id).length;
2026-07-20 16:05:17 +00:00
}
if (isPrivateResult) {
2026-07-29 08:29:29 +00:00
isPrivateResult = 0 === outer1_5.getAllActiveStreamsForChannel(tmp.id).length;
2026-07-20 16:05:17 +00:00
}
if (isPrivateResult) {
2026-07-23 10:11:24 +00:00
isPrivateResult = !outer1_6.isVideoEnabled();
2026-07-20 16:05:17 +00:00
}
return isPrivateResult;
}, items3);
};