Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit e59d85ae authored by Nick Chameyev's avatar Nick Chameyev
Browse files

Update display size before updating 'ignore orientation request'

When folding/unfolding a foldable device 'ignore orientation request'
flag might be updated in DisplayContent because different displays
might have different properties. This might result into updated
display rotation.

This flag is updated in 'applySettingsToDisplayLocked' and the new
rotation might be applied in the same method. But DisplayRotation is
not updated with the new display size when applySettingsToDisplayLocked
is invoked. This caused calculation of incorrect rotation
(using old display dimensions).

Fixed by updating display rotation settings only after
updating the size of the display.

Fixes: 203844967
Test: open portrait only app on the unfolded screen,
  fold the device => app is still in portrait orientation
Test: open rotatable app on the unfolded screen,
  fold the device => app is in portrait orientation
Test: rotate screen on inner/outer screen of a foldable device
Change-Id: Ie408ebe7e5913b4a1f97d46581d693e56efaf46c
parent f4039ba2
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment