I have a Bottom-Navigation in portrait Mode and a Navigation-Rail-View in landscape mode.
How can I update the selected item when the device is rotated?
I tried it with savedInstanceState
, with override theonSaveInstanceState
and onRestoreInstanceState
.
But because I use savedInstanceState
for other things too, overide the two above methods cause crash.