Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to create multi-pane layout in android

I want to make screen in which I have used multi pane layout.In screen ,left side show custom list view and right hand side show detail about click item.When I have run app in protrait from that show only single screen for example list.But on lanscape mode that is show list and detail page on screen.Please suggest me what can i do or example.

like image 653
Deepak Avatar asked Feb 01 '13 10:02

Deepak


1 Answers

This is fairly easy with Fragments

And I think this is exactly what you want.

Android introduced fragments in Android 3.0 (API level 11), primarily to support more dynamic and flexible UI designs on large screens, such as tablets.

Android developer example

TIP:

If you update your SDK, and ADT plugin for Eclipse (If you are using it). You can even create a new project based on a fragment example! Which is very informative and easy to adjust. You project has to have a minimum SDK version of 11.

Normally it would check with a configuration qualifier if you have a small handset screen or a big tablet screen, this check is fairly easy to find in your example project (Sorry I don't have much time to find a good example for you). Now you can change this configuration qualifier from large to large-landscape, or whatever you want.

like image 60
Timmetje Avatar answered Sep 21 '22 19:09

Timmetje