How can I detect which layout is selected by Android in my application?

前端 未结 8 1981
孤街浪徒
孤街浪徒 2020-12-12 10:35

Assume I have an activity with three different layouts in different resource folders. For example:

layout-land/my_act.xml
lay

8条回答
  •  心在旅途
    2020-12-12 11:19

    You can try to repeat this algorithm "How Android Finds the Best-matching Resource" - it's quite simple, especially if you have different layouts only for different screens.

提交回复
热议问题