decord/alpha/source/stores/CollapsedVoiceChannelStore.tsx

61 lines
1.7 KiB
TypeScript
Raw Permalink Normal View History

2026-10-12 06:59:38 +00:00
// Module ID: 7250
// Function ID: 7251
// Name: CollapsedVoiceChannelStore
2026-10-10 08:08:14 +00:00
// Dependencies: [2065, 11, 504, 584, 2]
2026-07-23 10:11:24 +00:00
2026-10-12 06:59:38 +00:00
// Module 7250 (CollapsedVoiceChannelStore)
import SnowflakeUtilsDefault from "SnowflakeUtils" /* 11 */;
2026-10-03 08:58:59 +00:00
import get_initializedDefault from "get initialized" /* 504 */;
import DispatcherDefault from "Dispatcher" /* 584 */;
2026-10-10 08:08:14 +00:00
import ChannelStore from "ChannelStore" /* 2065 */;
2026-10-03 08:58:59 +00:00
import size from "module_2" /* 2 */;
2026-07-20 16:05:17 +00:00
function handleConnectionOpen() {
2026-10-03 08:58:59 +00:00
let channel;
obj = SnowflakeUtilsDefault;
2026-07-20 16:05:17 +00:00
const keys = obj.keys(obj);
const item = keys.forEach((item) => {
2026-10-03 08:58:59 +00:00
const tmp = item;
if (null == channel.getChannel(item)) {
2026-10-03 08:58:59 +00:00
delete obj[tmp];
2026-07-20 16:05:17 +00:00
}
});
}
let obj = {};
2026-10-03 08:58:59 +00:00
const PersistedStore = get_initializedDefault.PersistedStore;
2026-07-29 08:29:29 +00:00
class CollapsedVoiceChannelStore extends PersistedStore {
2026-10-03 08:58:59 +00:00
initialize(arg0) {
this.waitFor(ChannelStore);
}
getState() {
return obj;
}
getCollapsed() {
return obj;
}
isCollapsed(arg0) {
return obj[arg0] || false;
}
2026-07-29 08:29:29 +00:00
}
const prototype = CollapsedVoiceChannelStore.prototype;
CollapsedVoiceChannelStore.displayName = "CollapsedVoiceChannelStore";
CollapsedVoiceChannelStore.persistKey = "collapsedChannels";
2026-10-03 08:58:59 +00:00
const obj2 = {
2026-07-20 16:05:17 +00:00
CONNECTION_OPEN: handleConnectionOpen,
OVERLAY_INITIALIZE: handleConnectionOpen,
CHANNEL_COLLAPSE: function handleChannelCollapse(channelId) {
channelId = channelId.channelId;
if (obj[channelId]) {
2026-10-03 08:58:59 +00:00
delete obj[channelId];
2026-07-20 16:05:17 +00:00
} else {
2026-10-03 08:58:59 +00:00
obj[channelId] = true;
2026-07-20 16:05:17 +00:00
}
2026-07-23 10:11:24 +00:00
obj = {};
2026-07-20 16:05:17 +00:00
const merged = Object.assign(obj);
}
2026-10-03 08:58:59 +00:00
};
const collapsedVoiceChannelStore = new CollapsedVoiceChannelStore(DispatcherDefault, obj2);
const result = size.fileFinishedImporting("stores/CollapsedVoiceChannelStore.tsx");
2026-07-20 16:05:17 +00:00
2026-07-29 08:29:29 +00:00
export default collapsedVoiceChannelStore;