fix: remove bookerlyStyle from SettingsList patch to prevent compile error when bookerly not installed

This commit is contained in:
Justin Oros
2026-04-22 16:06:27 -07:00
parent 191728edd1
commit d3d443ce7f
+1 -11
View File
@@ -238,7 +238,7 @@ def patch_settings_list_h(repo_dir):
path = find_first("SettingsList.h", repo_dir) path = find_first("SettingsList.h", repo_dir)
content = read_file(path) content = read_file(path)
if "Bookerly" in content or "bookerlyStyle" in content: if 'STR_NONE_OPT}, "fontFamily"' in content:
print(" SettingsList.h already patched, skipping.") print(" SettingsList.h already patched, skipping.")
return return
@@ -247,16 +247,6 @@ def patch_settings_list_h(repo_dir):
'{StrId::STR_NOTO_SERIF, StrId::STR_NOTO_SANS, StrId::STR_OPEN_DYSLEXIC, StrId::STR_NONE_OPT}, "fontFamily"' '{StrId::STR_NOTO_SERIF, StrId::STR_NOTO_SANS, StrId::STR_OPEN_DYSLEXIC, StrId::STR_NONE_OPT}, "fontFamily"'
) )
entry = (
' SettingInfo::Enum(StrId::STR_NONE_OPT, &CrossPointSettings::bookerlyStyle,\n'
' {StrId::STR_NONE_OPT, StrId::STR_NONE_OPT, StrId::STR_NONE_OPT, StrId::STR_NONE_OPT}, "bookerlyStyle"),\n'
)
content = content.replace(
' };\n return list;\n}\n',
entry + ' };\n return list;\n}\n'
)
write_file(path, content) write_file(path, content)
print(" SettingsList.h patched.") print(" SettingsList.h patched.")