Патч панели навигации и подписи версии в настройках
This commit is contained in:
@@ -38,4 +38,19 @@ def apply(config: dict) -> bool:
|
||||
|
||||
# Save back
|
||||
tree.write(file_path, pretty_print=True, xml_declaration=True, encoding="utf-8")
|
||||
|
||||
filepaths = [
|
||||
"./decompiled/smali_classes2/com/swiftsoft/anixartd/ui/activity/UpdateActivity.smali",
|
||||
"./decompiled/smali_classes2/com/swiftsoft/anixartd/ui/fragment/main/preference/MainPreferenceFragment.smali",
|
||||
]
|
||||
for filepath in filepaths:
|
||||
content = ""
|
||||
with open(filepath, "r", encoding="utf-8") as file:
|
||||
for line in file.readlines():
|
||||
if '"\u0412\u0435\u0440\u0441\u0438\u044f'.encode("unicode_escape").decode() in line:
|
||||
content += line[:line.rindex('"')] + config["version"] + line[line.rindex('"'):]
|
||||
else:
|
||||
content += line
|
||||
with open(filepath, "w", encoding="utf-8") as file:
|
||||
file.write(content)
|
||||
return True
|
||||
|
||||
Reference in New Issue
Block a user