Вы находитесь на странице: 1из 3

Android Development Tools

Google I/O 2011: Wednesday, May 11, 2:45 - 3:45

Speakers
Xavier Ducrochet, Tech Lead Tor Norbye, Software Engineer Google

Summary
This talk provides an in-depth look at the Android development tools, along with tips & tricks for getting the most out of them. From project support, to source editing and visual editors, to emulator execution and debugging and profiling, this talk will help you get more productive with Android development. The main focus is on Eclipse, but we will discuss other complementary tools as well. This is a demo-oriented talk, and our goal is to show the available features, and how they fit into the workflow.

Contents
Speakers Summary Contents Notes Q&A

Notes
Comments link: http://goo.gl/mod/jY8n Introduction Intro of speaker. Talk is about new tools, underused tools, etc. tools.android.com Allow working in any OS and Java environment. Eclipse is main priority.

Command line tools supported by Ant. Eclipse integration. Project, Build, Launch, Debug support Advanced editors XML content assist, quick fixes, quick assist WYSIWYG editors. Focusing on interactivity and rendering. Improved Layout Rendering Most of Android View framework is now running in Eclipse In 3.1, more advanced drawing support, better Custom View support, new API for better connectivity Will port back to 2.X Tools Walkthrough Showing new WYSIWYG UI editor. Drag and Drop. Palette shows preview of widgets and is themed. Palette contains categories. Custom and library views are supported. Control-click jumps to code. Editing code updates the UI display. If a Custom View is now running within Eclipse, what is Custom View code does "bad things" (e.g. 50 threads). Design time specification helps there. Nice layout action bar has controls for layout properties. Config chooser lets you see how layout and views look under different Android configs. Things may not work all that well yet for older Android configs. Locale chooser. Theme chooser. Screen size and orientation choosers. Tip: Resource chooser takes wildcards. Tip: Use modifier key and drag to duplicate. "Extract Include" refactoring, to create an include for reuse of layouts. It will find existing uses of the include code and replace with the new include. Tip: Double-click on included layout will edit the include code. What about inlined styles? Use "Extract Style" refactoring to create new styles and replace their uses. Better rendering for List Views. Built-in or custom layouts can be used. "Change widget type" refactoring. "Wrap in container" refactoring. "Change layout" refactoring. Coming soon: Guidelines and geometric matching for relative layouts. They show you the constraints of the relative layout and let you easily change them. Animations support to preview animation effects. Warning that new animations should go in res/animation for them to show up in new animation picker. Completion, quick fixes, refactorings available in XML editor. Hover and goto/jump to definition support available, as well. Other Design Tools

Android Asset Studio (http://j.mp/androidassetstudio) enables nice icon creation and generation. Lesser Known and Under-used Features: Logcat window in Eclipse Traceview window for tracking down CPU performance issues. "Dump HPROF' for getting heap profiling reports. Uses associated Eclipse MAT tool. Emulator Status Known Big Issue. It emulates the full ARM device, all the way down to hardware emulation. Runs ARM code, interpreted into x86. Slow, but OK Software GL renderer. Very slow in tablet screen resolutions. Team is working on hardware GL rendering. Hard problem, though. Snapshot support for fast emulator startup. Demo of prototype emulator with software vs. hardware GL emulation. Applause. Another prototype demo of game showing that ARM emulation is not really a bottleneck but the team is still studying it. The above new stuff is coming in "a few months". Link tools.android.com source.android.code

Q&A
Q: Something about the Android API. A: Talk to API team at office hours. Q: Better XML error handling. A: There is better stuff in the new tools. Even more to come. Q: Multitouch support (like capture and replay) in tools. A: Team is aware but isn't really working on it yet. Q: Can you set the default device config in Eclipse? A: Not totally. Q: Resource changes are slow because of excessive re-building. A: Working on that now to be smarter. Q: What about hand-edited XML. It gets reformatted badly. A: Working on it.

Вам также может понравиться