|
【文件名】:10110@52RD_AndroidEssentials.pdf
【格 式】:pdf
【大 小】:1144K
【简 介】:
【目 录】:
Chapter 1: Introduction...............................................................1
What You Need to Know to Start............................................................1
How to Best Use This Book ....................................................................2
Getting Started.........................................................................................2
Installing Eclipse ........................................................................................... 3
Getting the Android SDK.............................................................................. 3
Installing the Eclipse Plug-In ........................................................................ 4
The Android Project................................................................................5
Running, Debugging, and Causing General Mayhem..........................8
Chapter 2: The Application ..........................................................9
Getting Active ..........................................................................................9
Getting Splashy ........................................................................................... 10
Creating the Intent Receiver.................................................................19
Setting It Up ................................................................................................ 19
Seeing the Intent Receiver in Action........................................................... 23
Triggering the Activity................................................................................ 26
Who Do You Want to Humiliate Today? .............................................29
Nervous with the Service ............................................................................ 29
Zen and the Art of Getting Even ................................................................. 33
Moving Data in Android .......................................................................34
Shameless Self-Promotion .......................................................................... 36
Adding Evil Corporate URLS with a Content Resolver ............................. 38
Part of This Balanced Breakfast ..........................................................39
Chapter 3: User Interface ..........................................................41
Easy and Fast, the XML Layout...........................................................42
Laying Out................................................................................................... 42
Scrolling, Text Entry, Buttons, and All the Simple Things in Life ........... 51
Waking Up the Widgets.........................................................................55
Widgets in Java ........................................................................................... 59
Getting Under the Hood .............................................................................. 59
Custom UI Rendering with the Canvas................................................67
Customizing the View................................................................................. 67
Creating the Game Loop ............................................................................. 69
Bringing It All Together.............................................................................. 74
Using the User Interface.......................................................................74
Chapter 4: Location, Location, Location ......................................75
Where Am I? .........................................................................................75
Building the LocationManager Object........................................................ 76
Look Up, Wave, the Satellites Are Watching… ......................................... 77
Google Maps..........................................................................................80
A Metric Ton of Map Objects ..................................................................... 80
Moving the Map .......................................................................................... 82
Taking Stock................................................................................................ 84
It’s a Bird, It’s a Plane...Nope, It’s Bad Photoshoping ............................... 84
Wrapping Up ............................................................................................... 87
Chapter 5: Taking Android Out for a Walk...................................89
Loading a List from the Web ................................................................89
First Things…First? .................................................................................... 90
Getting the Network in Gear ....................................................................... 92
This book covers the essential information required to build an Android application. It will help
any developer, amateur, professional, or dabbler who is interested in developing for Android.
Over the course of the book, I cover the essentials you’ll need to get started with your own
innovative application. I took on this project because, after five years of working in the mobile
software industry, it has become clear that we need help. With mobile devices becoming more
ubiquitous, powerful, and, indeed, essential, fresh blood is necessary to overcome the stagnation
that has plagued our business. As an industry, we need to graduate from making cookie-cutter
ringtones, wallpaper, and e-mail applications. I hope, once you’ve finished this book, that you’ll
be in a position to start that killer mobile product you’ve told all your friends you’re going to
make.
In Android Essentials, I cover the details of installing and using the Android SDK,
making and rendering user interface tools, harnessing location tracking and Google Maps, and
putting everything together with a little glue from XML parsers and networking clients. These
tools and tricks should be enough to get you past your empty editor, the daunting blank canvas
of the developer world, and onto the path of your own innovative mobile app. Android
potentially represents our best hope for a break from the constricted world of mobile
development. Use it to make something amazing. I can’t wait to see what you create.
对于学习android很不错的英文书! |
|