Android - Manage layouts landscape

后端 未结 1 943
长发绾君心
长发绾君心 2021-01-25 04:23

I need an activity load different fragments depending orientation:

Activity-> (portrait) Fragment Portrait

Activity-> (landscape) Fragment Landscape

this

相关标签:
1条回答
  • 2021-01-25 05:13

    Create two folder in res with name layout-land or layout-port

    Place Portrait xml file in layout-port:

    and

    Place landscape xml file in layout-land:

    Keep that in mind file both file will have same name

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