xiv
Contents
Acquiring Push Notification Certificates .........................................................................................................................266
Developing Your Server-Side Push Notification Service .................................................................................................269
Implementing a Ruby push notification supplier ..............................................................................................269
Pushing notifications ........................................................................................................................................272
Checking delivery using feedback .....................................................................................................................272
Integrating Push Notifications with Your iPhone Client .................................................................................................273
Registering for notifications .............................................................................................................................273
Receiving notifications in your application .......................................................................................................274
Summary .......................................................................................................................................................................275
Chapter 21: Using the Game Kit API . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .277
Providing Peer-to-Peer Connectivity .............................................................................................................................277
Finding peers ....................................................................................................................................................278
Working with sessions ......................................................................................................................................281
Providing In-Game Voice ...............................................................................................................................................284
Summary .......................................................................................................................................................................288
Chapter 22: Implementing Cut, Copy, and Paste . . . . . . . . . . . . . . . . . . . . . . . .289
Copying and Pasting with Standard Controls .................................................................................................................289
Understanding Pasteboard Types ..................................................................................................................................290
Interacting with UIPasteboard ......................................................................................................................................291
Implementing Cut, Copy, and Paste on a Custom View .................................................................................................292
Implementing touchesEnded:withEvent: to display the menu .........................................................................292
Implementing the copy: method ......................................................................................................................293
Implementing the paste: method ....................................................................................................................294
Understanding the interactions ........................................................................................................................294
Summary .......................................................................................................................................................................295
Chapter 23: Using the Maps API . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .297
Showing an Embedded Map with MKMapView .............................................................................................................297
Creating an MKMapView ..................................................................................................................................297
Specifying the map region ................................................................................................................................299
Annotating Maps ...........................................................................................................................................................301
Thinking about performance with annotations ................................................................................................303
Converting Coordinates .................................................................................................................................................303
Summary .......................................................................................................................................................................305
Part IV: Working with Media ............................................................307
Chapter 24: Exploring the Supported Media Types. . . . . . . . . . . . . . . . . . . . . .309
Supported Audio Formats ..............................................................................................................................................309
Compressed audio ............................................................................................................................................309
Uncompressed audio ........................................................................................................................................310
Supported Video Formats ..............................................................................................................................................310
Summary .......................................................................................................................................................................310