From bad0e640aa18bf30bcdff987246fd99bc48bbe99 Mon Sep 17 00:00:00 2001 From: Mirco Wittrien Date: Tue, 27 Sep 2022 14:54:19 +0200 Subject: [PATCH] stuff --- Library/_res/0BDFDB.data.json | 3 --- Plugins/NotificationSounds/NotificationSounds.plugin.js | 4 ++-- Plugins/ServerHider/ServerHider.plugin.js | 2 +- Plugins/SpellCheck/SpellCheck.plugin.js | 2 +- 4 files changed, 4 insertions(+), 7 deletions(-) diff --git a/Library/_res/0BDFDB.data.json b/Library/_res/0BDFDB.data.json index 53b9a09f5a..f7b5451726 100644 --- a/Library/_res/0BDFDB.data.json +++ b/Library/_res/0BDFDB.data.json @@ -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"]}, diff --git a/Plugins/NotificationSounds/NotificationSounds.plugin.js b/Plugins/NotificationSounds/NotificationSounds.plugin.js index 875b52c14d..e3a370c42b 100644 --- a/Plugins/NotificationSounds/NotificationSounds.plugin.js +++ b/Plugins/NotificationSounds/NotificationSounds.plugin.js @@ -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(); diff --git a/Plugins/ServerHider/ServerHider.plugin.js b/Plugins/ServerHider/ServerHider.plugin.js index c9e70c6fba..c5426717c5 100644 --- a/Plugins/ServerHider/ServerHider.plugin.js +++ b/Plugins/ServerHider/ServerHider.plugin.js @@ -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) { diff --git a/Plugins/SpellCheck/SpellCheck.plugin.js b/Plugins/SpellCheck/SpellCheck.plugin.js index c0fc501b8b..cefc082b7b 100644 --- a/Plugins/SpellCheck/SpellCheck.plugin.js +++ b/Plugins/SpellCheck/SpellCheck.plugin.js @@ -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);