修复翻译设置的读取问题

This commit is contained in:
lyswhut 2021-08-16 16:57:43 +08:00
parent d3caf5eb76
commit 7742f23f6d
3 changed files with 4 additions and 4 deletions

View File

@ -42,7 +42,7 @@ const init = () => {
registerPlaybackService(),
]).then(() => {
let setting = store.getState().common.setting
toggleTranslation(setting.player.isShowTranslation)
toggleTranslation(setting.player.isShowLyricTranslation)
if (setting.sync.enable) {
connect().catch(err => {
if (err.message == SYNC_CODE.unknownServiceAddress) {

View File

@ -50,7 +50,7 @@ export const desktopLyricTextPosition = state => state.common.setting.desktopLyr
export const timeoutExit = state => state.common.setting.player.timeoutExit
export const timeoutExitPlayed = state => state.common.setting.player.timeoutExitPlayed
export const isShowLyricTranslation = state => state.common.setting.player.isShowTranslation
export const isShowLyricTranslation = state => state.common.setting.player.isShowLyricTranslation
export const activeApiSourceId = state => state.common.setting.apiSource

View File

@ -278,14 +278,14 @@ const mutations = {
},
}
},
[TYPES.setIsShowLyricTranslation](state, isShowTranslation) {
[TYPES.setIsShowLyricTranslation](state, isShowLyricTranslation) {
return {
...state,
setting: {
...state.setting,
player: {
...state.setting.player,
isShowTranslation,
isShowLyricTranslation,
},
},
}