androidcommonsware

What emulator to use to test sw720dp-land layout


I am running some sample code to test fragments:

https://github.com/commonsguy/cw-omnibus/tree/master/LargeScreen/EU4You

I am trying to test the results with the android emulator, but none of the emulators I select seem to work (they don't use the sw720dp-land layout). I do press Ctrl F11/F12 to rotate the screen to landscape.

Can someone tell me what settings to use when I create a new AVD in the Android Virtual Device Manager. Specifically, what 'Device' and 'Target'.


Solution

  • Technically, you need an emulator with 720dp along its shortest axis.

    So, for example, an emulator based on the 10.1" WXGA (Tablet) stock device definition works, as that is an -mdpi emulator image with 1280x800 px resolution. 1dp == 1px at -mdpi density, and so that would qualify for -sw720dp resources.

    In terms of target, -sw720dp was introduced in API Level 13 (Android 3.2), so you would need that or higher.