You are previewing Windows® Phone 7 Development Internals.
O'Reilly logo
Windows® Phone 7 Development Internals

Book Description

Drill into Windows® Phone 7 design and architecture—and learn best practices for building a variety of applications. Each chapter focuses on a single Windows Phone building block or feature area, and shows you how to apply it in your applications. If you’re an experienced .NET developer familiar with Microsoft® Silverlight®, you’ll gain deep insights into the Windows Phone platform design and API surface.

Table of Contents

  1. Windows® Phone 7 Development Internals
  2. A Note Regarding Supplemental Files
  3. Foreword
  4. Introduction
    1. Who Should Read This Book
      1. Assumptions
    2. Who Should Not Read This Book
    3. Organization of This Book
    4. Conventions and Features in This Book
    5. System Requirements
    6. Code Samples
      1. Installing the Code Samples
      2. Using the Code Samples
    7. Acknowledgments
    8. Errata & Book Support
    9. We Want to Hear from You
    10. Stay in Touch
  5. I. Building Blocks
    1. 1. Vision and Architecture
      1. Windows Phone Vision
        1. Metro
        2. Developer Guidelines
      2. Windows Phone Architecture
        1. Comparison of Silverlight and XNA
      3. Developer Tools
        1. Development Cycle
      4. The Anatomy of a Basic Windows Phone Application
        1. XAP Contents
        2. Standard Project Types
        3. Themes and Accent Colors
        4. Standard Application Images
      5. Version 7 vs. Version 7.1
      6. Summary
    2. 2. UI Core
      1. Phone UI Elements
        1. Standard UI Elements
        2. Visual Tree
        3. Screen Layout
      2. UserControl vs. Custom Control
        1. Routed Events
      3. Resources
        1. Content vs. Resource
        2. Resource Dictionaries
      4. Dependency and Attached Properties
        1. Dependency Properties
        2. Attached Properties
      5. Summary
    3. 3. Controls
      1. Standard Controls
        1. Platform, SDK, Toolkit
        2. SDK Controls: Pivot
        3. SDK Controls: Panorama
        4. Toolkit Controls
      2. Transient Panels
      3. Summary
    4. 4. Data Binding and Layer Decoupling
      1. Life without Data Binding
      2. Simple Data Binding and INotifyPropertyChanged
      3. Data Binding Collections
        1. Data Templates
        2. Dynamic Data-Bound Collections
        3. Template Resources
      4. Type/Value Converters
      5. Element Binding
      6. Data Validation
      7. Separating Concerns
        1. Design-Time Data
        2. The Model-View ViewModel Pattern
      8. The Visual Studio Databound Application Project
      9. Summary
    5. 5. Touch UI
      1. Logical Touch Gestures
      2. Manipulation Events: Single Touch (Tap)
      3. Manipulation Events: Single Touch (Flick)
      4. Manipulation Events: Multi-Touch
      5. Mouse Events
      6. FrameReported Events
      7. Combining Manipulation and Mouse Events
      8. Click vs. Mouse/Manipulation Events
      9. The Silverlight Toolkit GestureService
        1. Pinch and Drag
        2. Flick and Tap
        3. Problems with the GestureService
      10. Behaviors
      11. Keyboard Input
      12. Orientation
      13. The Application Bar
      14. Summary
  6. II. Application Model
    1. 6. Application Model
      1. Lifetime Events and Tombstoning
        1. Application Closing
        2. Application Deactivated
        3. Application Deactivated (the Non-Tombstone Case)
        4. Unhandled Exceptions
        5. Why Is There No App.Exit?
        6. Obscured and Unobscured
        7. Launchers/Choosers and Tombstoning
        8. User Expectations
      2. Page Model
        1. Page Creation Order
      3. Summary
    2. 7. Navigation State and Storage
      1. Navigation and State
        1. Application and Page State
        2. Detecting Resurrection
      2. Navigation Options
        1. Using NavigateUri
        2. Pages in Separate Assemblies
        3. Fragment and QueryString
        4. The NavigationMode Property
        5. Rerouting Navigation and URI Mappers
        6. Nonlinear Navigation Service
      3. Isolated Storage
        1. Simple Persistence
        2. Persisting the ViewModel
        3. Serialization Options
        4. Isolated Storage Helpers
      4. Summary
    3. 8. Diagnostics and Debugging
      1. Visual Studio Debugging
      2. Simple Diagnostics
        1. Setting Up a Diagnostics Pop-Up Window
        2. Fixed Diagnostics Control
        3. Post-Release Diagnostics
        4. Persisting Logs
        5. Configurable Diagnostics
        6. Screen Capture
        7. Emulator Console Output
        8. Debugging Tombstoning and Lock-Screen
        9. Debugging MediaPlayer
      3. Device and User Information
      4. Windows Phone Performance Counters
        1. Memory Diagnostics
      5. The Device Emulator
        1. Emulator vs. Device
        2. XDE Automation
      6. Using the Microsoft Network Monitor
      7. Fiddler
      8. Silverlight Spy
      9. Summary
  7. III. Extended Services
    1. 9. Phone Services
      1. Phone Hardware
      2. Launchers and Choosers
      3. Photo Extras
      4. Accelerometer
        1. Reactive Extensions for .NET
        2. Level Starter Kit
        3. Shake
      5. Geo-Location
      6. Summary
    2. 10. Media Services
      1. Audio and Video Hardware
      2. Audio and Video APIs
      3. Media Playback
        1. The MediaPlayerLauncher Class
        2. The MediaElement Class
        3. The MediaStreamSource and ManagedMediaHelpers Classes
        4. MediaElement Controls
      4. Audio Input and Manipulation
        1. The SoundEffect and SoundEffectInstance Classes
        2. Audio Input and the Microphone
        3. The DynamicSoundEffectInstance Class
      5. Music and Videos Hub
      6. The FM Tuner
      7. Summary
    3. 11. Web and Cloud
      1. The WebClient Class
        1. WebClient: The DownloadStringAsync Method
        2. WebClient: The OpenReadAsync Method
      2. The HttpWebRequest Class
      3. WebBrowser Control
        1. Silverlight and Javascript
      4. Web Services
      5. WCF Data Services
        1. The OData Client and XML Data
        2. JSON-Formatted Data
      6. Bing Maps and Geolocation
        1. Using the Map Control
        2. Geolocation
        3. Bing Maps Web Services
      7. Deep Zoom (MultiScaleImage)
      8. Windows Azure
        1. Windows Azure Web Services
        2. Windows Azure Toolkit for Windows Phone
      9. bitly
      10. Facebook
      11. Windows Live
        1. SkyDrive
      12. Summary
    4. 12. Push Notifications
      1. Architecture
      2. Push Notification Server
      3. Push Notification Client
      4. Additional Server Features
        1. Batching Intervals
        2. XML Payload
        3. Response Information
      5. Additional Client Features
        1. Persistent Client Settings
        2. The ErrorOccurred Event
        3. User Opt-In/Out
        4. Implementing a Push ViewModel
      6. The Push Notification Server-Side Helper Library
      7. Common Push Notification Service
      8. Summary
    5. 13. Security
      1. Device Security
      2. Application Safeguards
        1. Application Deployment
        2. Managed Code Constraints
        3. Chambers and Capabilities
        4. Missing Security Features
      3. Data Encryption
      4. SDL Tools
        1. Threat Modeling
        2. Static Code Analysis/FxCop
      5. Web Service Security
        1. Authentication
        2. Forms Authentication
          1. Forms Authentication: Server Side
          2. Forms Authentication: Client Side
        3. Basic Authentication
        4. SSL
      6. Push Notification Security
      7. OAuth 1.0
      8. OAuth 2.0
      9. Securing Web Service IDs
      10. Implementing Security for the WebBrowser Control
      11. Summary
    6. 14. Go to Market
      1. Threading
      2. Performance
        1. UI vs. Render Thread, and BitmapCache Mode
        2. UI Layout and ListBoxes
        3. More UI Performance Tips
        4. Non-UI Performance Tips
      3. Silverlight Unit Testing Framework
      4. Certification and Publication
        1. Updates
        2. Marketplace Reports
        3. Beta Testing
      5. Versions
        1. Light-Up Features
      6. Obfuscation
      7. Ads
      8. Trial Mode
      9. Silverlight Analytics Framework
      10. Summary
  8. IV. Version 7.5 Enhancements
    1. 15. Multi-Tasking and Fast App Switching
      1. Fast Application Switching
      2. Multi-Tasking
      3. Alarms and Reminders
        1. Alarms
        2. Reminders
      4. Background Transfer Service
      5. Generic Background Agents
      6. Background Audio
        1. Background Audio: The Main Application
        2. Background Audio: The Background Agent
      7. Summary
    2. 16. Enhanced Phone Services
      1. Sensor APIs
        1. Accelerometer
        2. Compass
        3. Gyroscope
        4. Motion APIs
      2. Camera Pipeline
      3. Augmented Reality
        1. The Geo Augmented Reality Toolkit
      4. New Photo Extensibility
      5. Launcher and Chooser Enhancements
      6. The DeviceStatus and DeviceNetworkInformation classes
      7. Version 7.1.1
      8. Summary
    3. 17. Enhanced Connectivity Features
      1. Push, Tile, and Toast Enhancements
        1. Local Tiles
        2. Pinning Tiles
        3. Push Enhancements
      2. Sockets
        1. TCP Sockets
      3. OData Client
      4. Search Extensibility
        1. App Connect
        2. App Instant Answer
      5. Summary
    4. 18. Data Support
      1. Local Database and LINQ-to-SQL
        1. Create and Read
        2. Update and Delete
        3. Schema Updates
        4. Associations
        5. Isolated Storage Explorer Tool
        6. Performance Considerations
        7. Database Encryption
      2. Encrypting Data and Credentials
      3. Contacts and Calendar
      4. Sync Framework
        1. Service Configuration
        2. Database Provisioning
        3. Code Generation
      5. Summary
    5. 19. Framework Enhancements
      1. Navigation Enhancements
        1. Frame and Page Navigation
        2. Backstack Management
      2. UI Enhancements
        1. Enhanced Controls
        2. The ApplicationBar and SystemTray Classes, and the ProgressIndicator Property
        3. The Clipboard API
        4. 32 Bits per Pixel
        5. Background Image Decoding
        6. Touch Thread
      3. Silverlight 4.0
        1. Implicit Styles
        2. Command Binding
        3. Data-Binding Enhancements
      4. Summary
    6. 20. Tooling Enhancements
      1. Emulator Improvements
      2. Debugger Experience
      3. Marketplace Test Kit
      4. The Profiler
      5. UserVoice Forums
      6. Portable Library Tools
      7. Async Framework
      8. Summary
  9. Index
  10. About the Author
  11. Copyright