Search code examples
androidlayoutandroid-4.0-ice-cream-sandwichandroid-2.3-gingerbread

Test a Gingerbread layout on Ice Cream Sandwich


I'm creating an application which works on Froyo until Jelly Beans. I have two layouts on for ICS and above and one for Gingerbread and Froyo.

I test my application on a device which it is on ICS so I see the ICS layout but I would like to test my other layout.

How I can do that ? I think I have to add an option in style.xml or androidManifest but I' not sure.

Thanks.


Solution

  • If you want to test your gingerbread layout but only have an ICS device, you can simply rename your layout folders so it will pick the gingerbread layouts on ICS. Switch the names of the layout-v10 and layout-v15 folders and it will load your v10 layout on your v15 device.

    Also, you could use an emulator (running 2.3.3) to test your gingerbread layout. This would allow you to make several emulators with different screen sizes and see how your app would look on different devices. You can also test other things with this like SD-card status, hardware keyboards vs soft keyboards, etc. to ensure your app works with different hardware configurations.