This commit is contained in:
恍兮惚兮 2024-05-20 00:40:55 +08:00
parent 57b472e9c1
commit b300b57e53
2 changed files with 13 additions and 7 deletions

View File

@ -139,13 +139,16 @@ def syncconfig(config1, default, drop=False, deep=0, skipdict=False):
elif key == "name": elif key == "name":
config1[key] = default[key] config1[key] = default[key]
if type(default[key]) != type(config1[key]) and ( elif key == "argstype":
type(default[key]) == dict or type(default[key]) == list
):
config1[key] = default[key] config1[key] = default[key]
elif type(default[key]) == dict: else:
if skipdict == False: if type(default[key]) != type(config1[key]) and (
syncconfig(config1[key], default[key], drop, deep - 1) type(default[key]) == dict or type(default[key]) == list
):
config1[key] = default[key]
elif type(default[key]) == dict:
if skipdict == False:
syncconfig(config1[key], default[key], drop, deep - 1)
if drop and deep > 0: if drop and deep > 0:
for key in list(config1.keys()): for key in list(config1.keys()):
@ -191,12 +194,15 @@ def getlanguse():
global language, languageshow global language, languageshow
return static_data["language_list_translator_inner"][language] return static_data["language_list_translator_inner"][language]
def getlangsrc(): def getlangsrc():
return static_data["language_list_translator_inner"][globalconfig["srclang3"]] return static_data["language_list_translator_inner"][globalconfig["srclang3"]]
def getlangtgt(): def getlangtgt():
return static_data["language_list_translator_inner"][globalconfig["tgtlang3"]] return static_data["language_list_translator_inner"][globalconfig["tgtlang3"]]
def setlanguage(): def setlanguage():
global language, languageshow global language, languageshow
language = globalconfig["languageuse"] language = globalconfig["languageuse"]

View File

@ -946,7 +946,7 @@
"name": "路径", "name": "路径",
"dir": false, "dir": false,
"multi": true, "multi": true,
"filter": "*.mdx|*.mdd" "filter": "*.mdx;*.mdd"
}, },
"ambiguity": { "ambiguity": {
"type": "intspin", "type": "intspin",