This commit is contained in:
Mirco Wittrien 2022-09-27 14:54:19 +02:00
parent 5904684267
commit bad0e640aa
4 changed files with 4 additions and 7 deletions

View File

@ -74,7 +74,6 @@
"BadgeUtils": {"props": ["getBadgeCountString", "getBadgeWidthForValue"]},
"BannerUtils": {"props": ["getUserBannerURLForContext"]},
"CallUtils": {"props": ["getCalls", "isCallActive"]},
"CategoryCollapseStore": {"props": ["getCollapsedCategories", "isCollapsed"]},
"CategoryCollapseUtils": {"props": ["categoryCollapse", "categoryCollapseAll"]},
"ChannelIconUtils": {"props": ["getChannelIconComponent", "getChannelIconTooltipText"]},
"ChannelUtils": {"props": ["selectChannel", "selectPrivateChannel"]},
@ -172,7 +171,6 @@
"SoundParser": {"strings": ["discodo", "ddr-down", "mute"]},
"SoundStateUtils": {"props": ["isSoundDisabled", "getDisabledSounds"]},
"SoundUtils": {"props": ["playSound", "createSound"]},
"SpellCheckStore": {"name": "SpellcheckStore"},
"SpotifyTrackUtils": {"props": ["hasConnectedAccount", "getLastPlayedTrackId"]},
"SpotifyUtils": {"props": ["setActiveDevice", "pause"]},
"StageChannelLiveStore": {"props": ["getAllLiveStageChannels", "useAllLiveStageChannels"]},
@ -181,7 +179,6 @@
"StateStoreUtils": {"props": ["useStateFromStores", "useStateFromStoresArray"]},
"StatusMetaUtils": {"props": ["getApplicationActivity", "getStatus", "getState"]},
"StoreChangeUtils": {"props": ["get", "set", "clear", "remove"]},
"StreamerModeStore": {"name": "StreamerModeStore"},
"StreamUtils": {"props": ["getActiveStreamForUser", "getAllApplicationStreams"]},
"TimestampUtils": {"props": ["fromTimestamp", "extractTimestamp"]},
"TimeUtils": {"props": ["calendarFormat", "dateFormat"]},

View File

@ -316,7 +316,7 @@ module.exports = (_ => {
if (callListenerModule) {
callListenerModule.terminate();
BDFDB.PatchUtils.patch(this, callListenerModule, "handleRingUpdate", {instead: e => {
if (BDFDB.LibraryModules.CallUtils.getCalls().filter(call => call.ringing.length > 0 && BDFDB.LibraryModules.VoiceUtils.getCurrentClientVoiceChannelId() === call.channelId).length > 0 && !BDFDB.LibraryModules.SoundStateUtils.isSoundDisabled("call_calling") && !BDFDB.LibraryModules.StreamerModeStore.disableSounds) {
if (BDFDB.LibraryModules.CallUtils.getCalls().filter(call => call.ringing.length > 0 && BDFDB.LibraryModules.VoiceUtils.getCurrentClientVoiceChannelId() === call.channelId).length > 0 && !BDFDB.LibraryModules.SoundStateUtils.isSoundDisabled("call_calling") && !BDFDB.LibraryStores.StreamerModeStore.disableSounds) {
createdAudios["call_calling"].loop();
}
else createdAudios["call_calling"].stop();
@ -714,7 +714,7 @@ module.exports = (_ => {
}
playAudio (type) {
if (this.dontPlayAudio(type) || BDFDB.LibraryModules.StreamerModeStore.disableSounds) return;
if (this.dontPlayAudio(type) || BDFDB.LibraryStores.StreamerModeStore.disableSounds) return;
if (createdAudios[type]) createdAudios[type].stop();
createdAudios[type] = new WebAudioSound(type);
createdAudios[type].play();

View File

@ -177,7 +177,7 @@ module.exports = (_ => {
}
processGuilds (e) {
if (this.settings.general.onlyHideInStream && !BDFDB.LibraryModules.StreamerModeStore.enabled) return;
if (this.settings.general.onlyHideInStream && !BDFDB.LibraryStores.StreamerModeStore.enabled) return;
let hiddenGuildIds = hiddenEles.servers || [];
let hiddenFolderIds = hiddenEles.folders || [];
if (hiddenGuildIds.length || hiddenFolderIds.length) {

View File

@ -96,7 +96,7 @@ module.exports = (_ => {
let dictionaryLanguageIds = Array.from(BDFDB.DOMUtils.create(body).querySelectorAll(`[href*="/mwittrien/BetterDiscordAddons/blob/master/Plugins/SpellCheck/dic/"]`)).map(n => n.innerText.split(".")[0]).filter(n => n);
languages = BDFDB.ObjectUtils.filter(BDFDB.LanguageUtils.languages, langId => dictionaryLanguageIds.includes(langId), true);
if (BDFDB.LibraryModules.SpellCheckStore && BDFDB.LibraryModules.SpellCheckStore.isEnabled()) BDFDB.LibraryModules.DispatchApiUtils.dispatch({type: "SPELLCHECK_TOGGLE"});
if (BDFDB.LibraryStores.SpellCheckStore && BDFDB.LibraryStores.SpellCheckStore.isEnabled()) BDFDB.LibraryModules.DispatchApiUtils.dispatch({type: "SPELLCHECK_TOGGLE"});
BDFDB.PatchUtils.forceAllUpdates(this);