Working with Multiple Android Screens
Are you building an Android™ application? Do you want to make the user interface work seamlessly across multiple devices? Of course, everyone does.
The good news is that the Android SDK offers many techniques that are simple to use. You can start with those, and then customize your code for best quality and performance.
This mini-course with hands-on coding demos shows you how. The devices used as examples are DROID X, DROID PRO, and FLIPOUT™, but you can adapt the techniques to DROID 2, MILESTONE™, or other Android devices.
The presentation covers topics such as:
- Choosing your target devices
- Setting up your AndroidManifest to work across multiple screen sizes and Android versions
- Creating layouts that scale well and handle orientation changes
- Sampling images dynamically at runtime for best memory usage and performance
- Creating buttons with touch areas that are comfortable across multiple devices
Now go ahead—watch the presentation and listen to the audio narration, or go straight to the videos and code samples.
Videos and samples
Dialing Wand
Why size matters in Android UI controls.
Photo Demo (02:48)
Running a simple Android UI across multiple device emulators.
Relative layout (04:13)
Creating a simple relative layout that works well across many screens.
Loading images (02:08)
Sampling images as you load them dynamically at runtime, to save memory.
Detecting device density (01:30)
Checking density dynamically at runtime using the DisplayMetrics class.
Buttons (04:57)
Creating buttons with comfortable touch areas across multiple devices.
ECCN 5D992.a: In accordance with United States Export Administration Regulations (EAR), and specifically the Commerce Control List (CCL), this item has been classified 5D992.a. Export or re-export of this commodity and compliance with the U.S. Export Administration Regulations is ultimately the responsibility of the exporter. For more detailed information related to export or re-export of this item, please consult the EAR at http://www.access.gpo.gov/bis/ear/ear_data.html.