Misc: Get rid of the legacy defaults.lua globals (#9546)

* This removes support for the following deprecated constants: `DTAP_ZONE_FLIPPING`, `DTAP_ZONE_BOOKMARK`, `DCREREADER_CONFIG_DEFAULT_FONT_GAMMA`
* The "Advanced settings" panel now highlights modified values in bold (think about:config in Firefox ;)).
* LuaData: Isolate global table lookup shenanigans, and fix a few issues in unused-in-prod codepaths.
* CodeStyle: Require module locals for Lua/C modules, too.
* ScreenSaver: Actually garbage collect our widget on close (ScreenSaver itself is not an instantiated object).
* DateTimeWidget: Code cleanups to ensure child widgets can be GC'ed.
This commit is contained in:
NiLuJe
2022-09-28 01:10:50 +02:00
committed by GitHub
parent 46f729c248
commit 62059f8d68
74 changed files with 1030 additions and 1050 deletions

View File

@@ -74,8 +74,8 @@ function PdfDocument:convertKoptToReflowableFontSize(font_size)
return size * default_font_size
elseif G_reader_settings:readSetting("kopt_font_size") then
return G_reader_settings:readSetting("kopt_font_size") * default_font_size
elseif DKOPTREADER_CONFIG_FONT_SIZE then
return DKOPTREADER_CONFIG_FONT_SIZE * default_font_size
elseif G_defaults:readSetting("DKOPTREADER_CONFIG_FONT_SIZE") then
return G_defaults:readSetting("DKOPTREADER_CONFIG_FONT_SIZE") * default_font_size
else
return default_font_size
end