New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Kindle Scribe: Fix KindleUI L and R orientations when restarting KOReader book in landscape #11780
Kindle Scribe: Fix KindleUI L and R orientations when restarting KOReader book in landscape #11780
Conversation
Tested well in Kindle Scribe. I don't know if Kindle Oasis 1, 2, 3 are victims of the same trap. If so, let me know, and I can make another PR. Thanks! |
I'm not sure I quite understand. This means the system is transparently turning everything around and the problem lies in trying to handle it? |
I don't know exactly, but it seems system doesn't like when KOReader rotates it to 1 or 3. There are two weird things I still don't understand:
If I rotate to U/D in Kindle UI, it reports U/D respectively. So I found a very narrow use case when KOReader broke. This PR fixed it. |
Regular modes (U/D) didn't break, so all good. |
Sounds.... weird, but whatever ^^. It does make some mild sort of sense that they'd be handling the orientation swap somehow :? |
Yeah, I am still confused every time I try to implement hardware rotation as suggested in #11269 (see my comments in the end). It seems like system is trying to override the orientation at least upon exit. I'll try to iron out these issues later too |
Should I wait until #11807 and co. are merge and update my PR? Or do you guys want to merge this first? |
That shouldn't conflict, I think? |
Yes, they don't conflict. I don't know whether it needs to be rebased for this PR, for example, after applying your PRs. And vice versa |
Yep, I meant "conflict" in those very The patch hunks look separate enough that it shouldn't be a problem either way ;). (If in doubt, merge this one first, I'll rebase; the other needs a base bump anyway). |
Thanks! |
Fixes #11743
It turns out that KOReader can only digest
U
orD
orientations.These are
0
and2
in the list below:1
and3
cause the touch to be misaligned with the visible rendered UI by 90 degrees if a KOReader book has been exited in KOReader's "landscape" orientation, and I don't really know why. Probably, because KOReader "rotates" the UI (or touch layer?) by 90 degrees when it is in "landscape" mode.Having
U
/L
andD
/R
in the same groups worked well.If Kindle is started in
L
, KOREader will greet the user in the same orientation, if the KOReader book has been left in that "landscape" orientation.This change is