10
Multitasking On Windows Phone Jason Lee Ethos Technologie

09 wp7 multitasking

Embed Size (px)

Citation preview

Page 1: 09 wp7   multitasking

MultitaskingOn

Windows Phone

Jason LeeEthos Technologies

Page 2: 09 wp7   multitasking

Agenda• Multitasking Considerations• Multitasking Patterns• Multitasking Types• Code Samples• Q & A

Page 3: 09 wp7   multitasking

Considerations• User Experience

• Delightful and responsive• Integrated Feel• Never regret installing applications

• Resource Friendly• Battery Saving• Network Conscience• Hardened Services

Page 4: 09 wp7   multitasking

Multitasking Patterns• Quick Switch / Resume

• Quick Resume : Hit Start key and come back within a short period• Quick Switch : Long-press on Back key, and choose between running apps

• Start in Foreground, Run in Background• Audio Player

• Start in Background, Run in Background• Auto Check-In

Page 5: 09 wp7   multitasking

Multitasking Types• Background Notification Service

• Alarms• Reminders

• Background Transfer Service• Has limitation on file size for cellular network• Deal with large file when wifi is available

• Background Audio• Supports both Silverlight applications and HTML 5• Extend control to foreground such as volume control, track navigation,

play/pause

• Background Agent• Initialized foreground, run in Background• Persists across reboots

Page 6: 09 wp7   multitasking

Agent• Periodic Agent

• Occurs every 30 minutes• Duration : 15 seconds• Scenarios : Incremental data sync, Location

• On Idle Agent• Occurs when external power and non-cellular network detected• Duration : 10 minutes• Scenarios : Large data transferring

• Limitations• Up to a maximum of 18 periodic agents allowed on a phone• Each agent runs for 14 days. Can be renewed before deadline, otherwise

abandoned

Page 7: 09 wp7   multitasking

Agent Functionality

Allowed

Tiles

Toast

Location

Network

Read/Write ISO store

Sockets

Most framework APIs

Restricted

Display UI

XNA libraries

Microphone and Camera

Sensors

Audio(except for background audio APIs)

Page 8: 09 wp7   multitasking

Play Time !• Goals

• Get familiar with multitasking model and development pattern• Understand how to create an agent

Page 9: 09 wp7   multitasking

Deep Linking• Scenario

• When you play around with phone, a reminder comes up• You hit the reminder, and system navigates to the relevant page• This page may be the main page of the app, or may be not, in which case

we call the navigation activity as Deep Linking

Page 10: 09 wp7   multitasking

! & ?

Thank You ! Any Questions ?