Implementing multiple layout for multiple screen support is not working

后端 未结 2 424
孤独总比滥情好
孤独总比滥情好 2021-01-29 11:16

I have read many things about supporting multiple devices. Right now I have implemented it in my application, I have made following folders as shown below :

  1. layout
2条回答
  •  深忆病人
    2021-01-29 12:08

    The way you are using is deprecated from android 3.1. Read the MulitScreen Support

    Your layout folder must be as this

    res/layout/main_activity.xml           # For handsets (smaller than 600dp available width)
    res/layout-sw600dp/main_activity.xml   # For 7” tablets (600dp wide and bigger)
    res/layout-sw720dp/main_activity.xml   # For 10” tablets (720dp wide and bigger)
    

    Read the document thoroughly.

提交回复
热议问题