Only toggle nightmode via the grayscale fb info flag on Kindle (#8931)

* Only toggle nightmode via the grayscale fb info flag on Kindle

Most NTX boards require elaborate trickery (see fbdepth) to actually
send a vput ioctl without the driver screwing with the rotation behind
your back.

This was causing spurious hardware rotations on exit on most Kobo
devices, something which might have gone mostly unnoticed, as current
Nickel versions will sanitize it on startup.
A simple repro was instead to start an USBMS session, as that exits
KOReader and restarts it without going through fbdepth again ;).
This commit is contained in:
NiLuJe
2022-03-21 03:59:24 +01:00
committed by GitHub
parent 3c21770d94
commit 044341875f
3 changed files with 8 additions and 1 deletions

View File

@@ -53,6 +53,7 @@ local Device = {
hasExternalSD = no, -- or other storage volume that cannot be accessed using the File Manager
canHWDither = no,
canHWInvert = no,
canModifyFBInfo = no, -- some NTX boards do wonky things with the rotate flag after a FBIOPUT_VSCREENINFO ioctl
canUseCBB = yes, -- The C BB maintains a 1:1 feature parity with the Lua BB, except that is has NO support for BB4, and limited support for BBRGB24
hasColorScreen = no,
hasBGRFrameBuffer = no,