decord/alpha/source/modules/voice_panel/VoicePanelManager.native.tsx
github-actions 72019a2d0c chore: update source for alpha 348.4
Skipped 1 file(s) >100MB (GitHub limit): source/__polyfill/05xxx/module_5014.js (118.4 MB)
2026-09-25 08:38:05 +00:00

62 lines
2 KiB
TypeScript

// Module ID: 17595
// Function ID: 17596
// Name: VoicePanelManager
// Dependencies: [2044, 4852, 5037, 6534, 2]
// Module 17595 (VoicePanelManager)
import ChannelStore from "ChannelStore" /* 2044 */;
import RTCConnectionStore from "RTCConnectionStore" /* 4852 */;
import VoicePanelStore from "VoicePanelStore" /* 5037 */;
import AutomaticLifecycleManager from "AutomaticLifecycleManager" /* 6534 */;
const prototype = function VoicePanelManager() {
const applyArgumentsResult = HermesBuiltin.applyArguments(new.target, new.target);
applyArgumentsResult.actions = {
VOICE_CHANNEL_SELECT() {
const channelId = RTCConnectionStore.getChannelId();
if (null != channelId) {
const state = VoicePanelStore.getState();
const channel = ChannelStore.getChannel(channelId);
let isGuildStageVoiceResult;
if (channel != null) {
isGuildStageVoiceResult = channel.isGuildStageVoice();
}
if (isGuildStageVoiceResult) {
state.closeChannel(channelId);
} else {
const channels = state.channels;
if (!channels.has(channelId)) {
state.openChannel(channelId);
}
}
}
},
RTC_CONNECTION_STATE() {
const channelId = RTCConnectionStore.getChannelId();
if (null != channelId) {
const state = VoicePanelStore.getState();
const channel = ChannelStore.getChannel(channelId);
let isGuildStageVoiceResult;
if (channel != null) {
isGuildStageVoiceResult = channel.isGuildStageVoice();
}
if (isGuildStageVoiceResult) {
state.closeChannel(channelId);
} else {
const channels = state.channels;
if (!channels.has(channelId)) {
state.openChannel(channelId);
}
}
}
}
};
return applyArgumentsResult;
}.prototype;
class prototype extends tmp2 {
}
const prototype1 = new prototype();
const size = fn(2);
const result = size.fileFinishedImporting("modules/voice_panel/VoicePanelManager.native.tsx");
export default prototype1;