Can't retain SupportMapFragment inside Fragment

前端 未结 1 1626
臣服心动
臣服心动 2021-01-15 22:43

I have an app with navigation drawer with Google Maps fragment and some other fragments. I\'m creating the SupportMapFragment programmatically and putting it in

相关标签:
1条回答
  • 2021-01-15 23:08

    By default when a configuration changes, such as the orientation, the entire activity is restarted, however you can prevent it from doing so by specifying when the activity can handle itself, this means you can tell the activity to not restart and instead call onConfigurationChanged

    read more about it here : how can I save the fragment? when I rotate the screen

    0 讨论(0)
提交回复
热议问题