SlideShare a Scribd company logo
1 of 38
Glen Gordon Developer Evangelist, Microsoft http://blogs.msdn.com/glengordon @glengordon Building Windows Phone 7 Apps with Silverlight
Agenda Silverlight Momentum Development Experience Phone Controls Web Browser Control App Bar Navigation Launchers and Choosers Application Lifecycle
Agenda Silverlight Momentum XAML Fundamentals Development Experience Phone Controls Q&A ….with lots of demos!
Silverlight Momentum
Silverlight 1 September 2007
Silverlight 2 October 2008 Silverlight 1 September 2007
Silverlight 3 July 2009 Silverlight 1 Silverlight 2 September 2007 October 2008
Silverlight 4 Business Applications Media Beyond the Browser Silverlight 1 Silverlight 2 Silverlight 3 Silverlight 4 September 2007 October 2008 July 2009 April 2010
60% RIAStats.com
225% Simplyhired.com
Development Experience
Windows Phone 7 Framework Windows Phone Frameworks Camera Device Integration Launchers & Choosers Windows Phone Controls PhoneApplicationPage PushNotification WebBrowserControl Sensors PhoneApplicationFrame Silverlight Presentation and Media XNA Frameworks for Games Controls Drawing IsolatedStorage Drawing GamerServices Navigation Shapes Markup Media Audio Media Graphics Content Input Application Object Common Base Class Library Diagnostics Reflection IO Runtime Resources Globalization Text Location Net Collections ComponentModel Configuration Security Threading ServiceModel Linq
Graphics Composition Start Experience System Tray Direct3D Surface AppPage Notification Volume SIP Incoming Call App Bar Shell frame composes all UI into a single screen Central page management enables cross app UI transitions and other effects You can also do this for orientation changes
UI Model: Familiar Web Concepts Phone application Provides UI represented as XAML pages connected into cross-app flows by URI’s Web application Provide media represented as HTTP resources linked by URL’s Shell frame Requests pages, renders UI, and handles navigation across apps Web browser Requests HTTP resources, renders them, and handles navigation across sites Sessions and back stack Groups together sequences of pages corresponding to a user’s activity across apps History and tabs Groups together sequences of HTTP resources corresponding to a user’s activity across sites
Phone Controls
Silverlight Controls Rich Set of Controls Familiar  Additional features For example, Software Input Panel (SIP) support on TextBox 16
Supported Border Button Canvas CheckBox Grid HyperlinkButton Image ListBox MediaElement Messagebox ProgressBar RadioButton ScrollViewer TextBlock TextBox WebBrowser
Controls support Touch Mouse Events  Automatically converted for you SIP and WebBrowser control have gestures ScrollViewer Just like Silverlight Basic Flick and Pan gestures Raw  Touch.FrameRendered DoodlePad – Sketch App
Controls support Touch Gestures  System level (WM_GESTURE). Can make your own. Tap, Double Tap, Pan, Flick, Touch and Hold  Multi-Touch Pinch, Stretch Manipulations Events ManipulationStarted ManipulationData ManipulationCompleted Use for Drag and Drop, etc.
DEMO – Controls
List Application Master/Detail Data MainPage.Xaml, DetailsPage.xaml ViewModel ItemViewModel.cs, MainViewModel.cs Project Types VS2010 calls it List Application and Blend calls it Databound Application
DEMO – List Application
WebBrowser control Displays network and local content Gestures: pan, double tap and pinch Supports transforms & projections No Input on transform  Application can interact with JavaScript Optimized for privacy Script is disabled by default Cookies and cache are isolated 23
Silverlight to Script Silverlight string fromScript = wb.InvokeScript("runScriptStuff", arg1, arg2); JavaScript function runScriptStuff(arg1, arg2) { return “awesome”; }
Script to Silverlight  Silverlight void wb_ScriptNotify(object s, NotifyEventArgs e) {    string fromScript = e.Value; } JavaScript Window.external.Notify(string);
DEMO – Web Browser
AppBar Toolbar Up to 4 icons Can set transparency level Slide up Menu can display more items Can declare in code or XAML Icons found under Program Filesicrosoft SDKsindows Phone7.0cons
AppBar Icons 48 pixels by 48 pixels  White foreground on a transparent background  Using alpha channel. Icon get colorized to current style Circle will be added
DEMO – AppBar
Frame and Page Frame Top-level container control PhoneApplicationFrame class Contains the page control and system elements such as system tray and application bar Page Fills the entire content region of the frame PhoneApplicationPage-derived class Optionally surfaces its own application bar Handles Orientation  NavigatedTo  and NavigatedFrom
Page Navigation Forward NavigationService.Navigate(new Uri(“/Page2.xaml”,uriKind.RelativeOrAbsolute)); Back NavigationService.GoBack(); Hardware Back Button Handle BackKeyPress, OnBackKeyPressand Navigate to where you would like
DEMO – Navigation
Tasks - Launchers and Choosers Launcher Launches one of the built-in applications through which a user completes a task No data is returned to calling application Example: PhoneCallTask Chooser Launches one of the built-in applications through which a user completes a task, and which returns some data to calling application When caller completes, calling application is activated and supplied with the Chooser result Example: PhotoChooserTask
Launchers & Choosers Launchers EmailComposeTask MarketplaceDetailTask MarketplaceHubTask MarketplaceReviewTask MarketplaceSearchTask MediaPlayerLauncher PhoneCallTask SearchTask SMSComposeTask WebBrowserTask Choosers CameraCaptureTask EmailAddressChooserTask PhoneNumberChooserTask PhotoChooserTask SaveEmailAddressTask SavePhoneNumberTask
DEMO – Tasks
UI and State Management: Concepts Page UI Describes the visual appearance of a page Retained in shell frame to support resuming paused sessions Discarded while the session is paused Page State Contains data that describes an instance of a page, analogous to browser cookie
App Lifecycle Close Back Button Tombstoned Start Button Task Launched Phone call received Handle events in App.xaml.cs
App State - Storage Isolated Storage Settings and Custom Data Secure and Sandboxed Logical Folder Structure via APIs No quota currently Be responsible and inform/empower user State Management PhoneApplicationPage/PhoneApplicationState Good for transient data

More Related Content

What's hot

Build 2017 - B8099 - What's new in Xamarin.Forms
Build 2017 - B8099 - What's new in Xamarin.FormsBuild 2017 - B8099 - What's new in Xamarin.Forms
Build 2017 - B8099 - What's new in Xamarin.FormsWindows Developer
 
Build 2017 - P4115 - Go big! Optimizing your applications for large screen ex...
Build 2017 - P4115 - Go big! Optimizing your applications for large screen ex...Build 2017 - P4115 - Go big! Optimizing your applications for large screen ex...
Build 2017 - P4115 - Go big! Optimizing your applications for large screen ex...Windows Developer
 
01 09 - graphical user interface - basic widgets
01  09 - graphical user interface - basic widgets01  09 - graphical user interface - basic widgets
01 09 - graphical user interface - basic widgetsSiva Kumar reddy Vasipally
 
Building On Demand Apps On Force.com
Building On Demand Apps On Force.comBuilding On Demand Apps On Force.com
Building On Demand Apps On Force.comguneetsahai
 
Cross Platform Mobile Development: The Easy Way to Develop Native iPhone & An...
Cross Platform Mobile Development: The Easy Way to Develop Native iPhone & An...Cross Platform Mobile Development: The Easy Way to Develop Native iPhone & An...
Cross Platform Mobile Development: The Easy Way to Develop Native iPhone & An...CITYTECH, Inc.
 
Intro to Xamarin.Forms for Visual Studio 2017
Intro to Xamarin.Forms for Visual Studio 2017Intro to Xamarin.Forms for Visual Studio 2017
Intro to Xamarin.Forms for Visual Studio 2017Xamarin
 
Xamarin.Forms - Your Complete Mobile Solution
Xamarin.Forms - Your Complete Mobile SolutionXamarin.Forms - Your Complete Mobile Solution
Xamarin.Forms - Your Complete Mobile SolutionCommit University
 
Wpf Under The Hood Engines
Wpf Under The Hood EnginesWpf Under The Hood Engines
Wpf Under The Hood EnginesTamir Khason
 

What's hot (12)

Build 2017 - B8099 - What's new in Xamarin.Forms
Build 2017 - B8099 - What's new in Xamarin.FormsBuild 2017 - B8099 - What's new in Xamarin.Forms
Build 2017 - B8099 - What's new in Xamarin.Forms
 
Silverlight
SilverlightSilverlight
Silverlight
 
Build 2017 - P4115 - Go big! Optimizing your applications for large screen ex...
Build 2017 - P4115 - Go big! Optimizing your applications for large screen ex...Build 2017 - P4115 - Go big! Optimizing your applications for large screen ex...
Build 2017 - P4115 - Go big! Optimizing your applications for large screen ex...
 
01 09 - graphical user interface - basic widgets
01  09 - graphical user interface - basic widgets01  09 - graphical user interface - basic widgets
01 09 - graphical user interface - basic widgets
 
Building On Demand Apps On Force.com
Building On Demand Apps On Force.comBuilding On Demand Apps On Force.com
Building On Demand Apps On Force.com
 
Single Page Application
Single Page ApplicationSingle Page Application
Single Page Application
 
01 08 - graphical user interface - layouts
01  08 - graphical user interface - layouts01  08 - graphical user interface - layouts
01 08 - graphical user interface - layouts
 
Windows Phone 7
Windows Phone 7Windows Phone 7
Windows Phone 7
 
Cross Platform Mobile Development: The Easy Way to Develop Native iPhone & An...
Cross Platform Mobile Development: The Easy Way to Develop Native iPhone & An...Cross Platform Mobile Development: The Easy Way to Develop Native iPhone & An...
Cross Platform Mobile Development: The Easy Way to Develop Native iPhone & An...
 
Intro to Xamarin.Forms for Visual Studio 2017
Intro to Xamarin.Forms for Visual Studio 2017Intro to Xamarin.Forms for Visual Studio 2017
Intro to Xamarin.Forms for Visual Studio 2017
 
Xamarin.Forms - Your Complete Mobile Solution
Xamarin.Forms - Your Complete Mobile SolutionXamarin.Forms - Your Complete Mobile Solution
Xamarin.Forms - Your Complete Mobile Solution
 
Wpf Under The Hood Engines
Wpf Under The Hood EnginesWpf Under The Hood Engines
Wpf Under The Hood Engines
 

Viewers also liked

Windows Phone 7 Services
Windows Phone 7 ServicesWindows Phone 7 Services
Windows Phone 7 ServicesGlen Gordon
 
Introduction to Microsoft Silverlight
Introduction to Microsoft SilverlightIntroduction to Microsoft Silverlight
Introduction to Microsoft SilverlightGlen Gordon
 
Windows Phone Garage - Application Jumpstart
Windows Phone Garage - Application JumpstartWindows Phone Garage - Application Jumpstart
Windows Phone Garage - Application JumpstartGlen Gordon
 
Windows phone 7 xna
Windows phone 7 xnaWindows phone 7 xna
Windows phone 7 xnaGlen Gordon
 
OData for iOS developers
OData for iOS developersOData for iOS developers
OData for iOS developersGlen Gordon
 
What's new in Windows Phone Mango for Developers
What's new in Windows Phone Mango for DevelopersWhat's new in Windows Phone Mango for Developers
What's new in Windows Phone Mango for DevelopersGlen Gordon
 

Viewers also liked (6)

Windows Phone 7 Services
Windows Phone 7 ServicesWindows Phone 7 Services
Windows Phone 7 Services
 
Introduction to Microsoft Silverlight
Introduction to Microsoft SilverlightIntroduction to Microsoft Silverlight
Introduction to Microsoft Silverlight
 
Windows Phone Garage - Application Jumpstart
Windows Phone Garage - Application JumpstartWindows Phone Garage - Application Jumpstart
Windows Phone Garage - Application Jumpstart
 
Windows phone 7 xna
Windows phone 7 xnaWindows phone 7 xna
Windows phone 7 xna
 
OData for iOS developers
OData for iOS developersOData for iOS developers
OData for iOS developers
 
What's new in Windows Phone Mango for Developers
What's new in Windows Phone Mango for DevelopersWhat's new in Windows Phone Mango for Developers
What's new in Windows Phone Mango for Developers
 

Similar to Windows Phone 7 and Silverlight

An end-to-end experience of Windows Phone 7 development (Part 2)
An end-to-end experience of Windows Phone 7 development (Part 2)An end-to-end experience of Windows Phone 7 development (Part 2)
An end-to-end experience of Windows Phone 7 development (Part 2)rudigrobler
 
Silverlight Developer Introduction
Silverlight   Developer IntroductionSilverlight   Developer Introduction
Silverlight Developer IntroductionTomy Ismail
 
Building cross platform mobile web apps
Building cross platform mobile web appsBuilding cross platform mobile web apps
Building cross platform mobile web appsJames Pearce
 
Windows Phone 7 Architecture Overview
Windows Phone 7 Architecture OverviewWindows Phone 7 Architecture Overview
Windows Phone 7 Architecture OverviewBhavya Siddappa
 
Re-use Your Skills and Code to Expand the Reach of Your Apps with Silverlight
Re-use Your Skills and Code to Expand the Reach of Your Apps with SilverlightRe-use Your Skills and Code to Expand the Reach of Your Apps with Silverlight
Re-use Your Skills and Code to Expand the Reach of Your Apps with SilverlightFrank La Vigne
 
DODN2009 - Jump Start Silverlight
DODN2009 - Jump Start SilverlightDODN2009 - Jump Start Silverlight
DODN2009 - Jump Start SilverlightClint Edmonson
 
An Introduction to Sencha Touch
An Introduction to Sencha TouchAn Introduction to Sencha Touch
An Introduction to Sencha TouchJames Pearce
 
Developing Applications for WebOS
Developing Applications for WebOSDeveloping Applications for WebOS
Developing Applications for WebOSChuq Von Rospach
 
Building Cross Platform Mobile Web Apps
Building Cross Platform Mobile Web AppsBuilding Cross Platform Mobile Web Apps
Building Cross Platform Mobile Web AppsJames Pearce
 
Compact Framework Development For The Desktop Developer
Compact Framework Development For The Desktop DeveloperCompact Framework Development For The Desktop Developer
Compact Framework Development For The Desktop Developerchristopherfairbairn
 
Windows Phone 7 Unleashed Session 1
Windows Phone 7 Unleashed Session 1Windows Phone 7 Unleashed Session 1
Windows Phone 7 Unleashed Session 1Wes Yanaga
 
HTML5 and the dawn of rich mobile web applications pt 1
HTML5 and the dawn of rich mobile web applications pt 1HTML5 and the dawn of rich mobile web applications pt 1
HTML5 and the dawn of rich mobile web applications pt 1James Pearce
 
SLUGUK BUILD Round-up
SLUGUK BUILD Round-upSLUGUK BUILD Round-up
SLUGUK BUILD Round-upDerek Lakin
 
Bd conf sencha touch workshop
Bd conf sencha touch workshopBd conf sencha touch workshop
Bd conf sencha touch workshopJames Pearce
 
Windows Phone 7.5 Mango - What's New
Windows Phone 7.5 Mango - What's NewWindows Phone 7.5 Mango - What's New
Windows Phone 7.5 Mango - What's NewSascha Corti
 
Developing Applications for Windows Phone 7 - Chris Ismael
Developing Applications for Windows Phone 7 - Chris IsmaelDeveloping Applications for Windows Phone 7 - Chris Ismael
Developing Applications for Windows Phone 7 - Chris IsmaelSpiffy
 
Silverlight 2
Silverlight 2Silverlight 2
Silverlight 2Dave Bost
 
Mix 2010 twilight
Mix 2010 twilightMix 2010 twilight
Mix 2010 twilightIntergen
 

Similar to Windows Phone 7 and Silverlight (20)

mobicon_paper
mobicon_papermobicon_paper
mobicon_paper
 
An end-to-end experience of Windows Phone 7 development (Part 2)
An end-to-end experience of Windows Phone 7 development (Part 2)An end-to-end experience of Windows Phone 7 development (Part 2)
An end-to-end experience of Windows Phone 7 development (Part 2)
 
Silverlight Developer Introduction
Silverlight   Developer IntroductionSilverlight   Developer Introduction
Silverlight Developer Introduction
 
Building cross platform mobile web apps
Building cross platform mobile web appsBuilding cross platform mobile web apps
Building cross platform mobile web apps
 
Windows Phone 7 Architecture Overview
Windows Phone 7 Architecture OverviewWindows Phone 7 Architecture Overview
Windows Phone 7 Architecture Overview
 
Re-use Your Skills and Code to Expand the Reach of Your Apps with Silverlight
Re-use Your Skills and Code to Expand the Reach of Your Apps with SilverlightRe-use Your Skills and Code to Expand the Reach of Your Apps with Silverlight
Re-use Your Skills and Code to Expand the Reach of Your Apps with Silverlight
 
DODN2009 - Jump Start Silverlight
DODN2009 - Jump Start SilverlightDODN2009 - Jump Start Silverlight
DODN2009 - Jump Start Silverlight
 
An Introduction to Sencha Touch
An Introduction to Sencha TouchAn Introduction to Sencha Touch
An Introduction to Sencha Touch
 
Silverlight Training
Silverlight TrainingSilverlight Training
Silverlight Training
 
Developing Applications for WebOS
Developing Applications for WebOSDeveloping Applications for WebOS
Developing Applications for WebOS
 
Building Cross Platform Mobile Web Apps
Building Cross Platform Mobile Web AppsBuilding Cross Platform Mobile Web Apps
Building Cross Platform Mobile Web Apps
 
Compact Framework Development For The Desktop Developer
Compact Framework Development For The Desktop DeveloperCompact Framework Development For The Desktop Developer
Compact Framework Development For The Desktop Developer
 
Windows Phone 7 Unleashed Session 1
Windows Phone 7 Unleashed Session 1Windows Phone 7 Unleashed Session 1
Windows Phone 7 Unleashed Session 1
 
HTML5 and the dawn of rich mobile web applications pt 1
HTML5 and the dawn of rich mobile web applications pt 1HTML5 and the dawn of rich mobile web applications pt 1
HTML5 and the dawn of rich mobile web applications pt 1
 
SLUGUK BUILD Round-up
SLUGUK BUILD Round-upSLUGUK BUILD Round-up
SLUGUK BUILD Round-up
 
Bd conf sencha touch workshop
Bd conf sencha touch workshopBd conf sencha touch workshop
Bd conf sencha touch workshop
 
Windows Phone 7.5 Mango - What's New
Windows Phone 7.5 Mango - What's NewWindows Phone 7.5 Mango - What's New
Windows Phone 7.5 Mango - What's New
 
Developing Applications for Windows Phone 7 - Chris Ismael
Developing Applications for Windows Phone 7 - Chris IsmaelDeveloping Applications for Windows Phone 7 - Chris Ismael
Developing Applications for Windows Phone 7 - Chris Ismael
 
Silverlight 2
Silverlight 2Silverlight 2
Silverlight 2
 
Mix 2010 twilight
Mix 2010 twilightMix 2010 twilight
Mix 2010 twilight
 

Recently uploaded

Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024The Digital Insurer
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsRoshan Dwivedi
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 

Recently uploaded (20)

Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 

Windows Phone 7 and Silverlight

  • 1. Glen Gordon Developer Evangelist, Microsoft http://blogs.msdn.com/glengordon @glengordon Building Windows Phone 7 Apps with Silverlight
  • 2. Agenda Silverlight Momentum Development Experience Phone Controls Web Browser Control App Bar Navigation Launchers and Choosers Application Lifecycle
  • 3. Agenda Silverlight Momentum XAML Fundamentals Development Experience Phone Controls Q&A ….with lots of demos!
  • 6. Silverlight 2 October 2008 Silverlight 1 September 2007
  • 7. Silverlight 3 July 2009 Silverlight 1 Silverlight 2 September 2007 October 2008
  • 8. Silverlight 4 Business Applications Media Beyond the Browser Silverlight 1 Silverlight 2 Silverlight 3 Silverlight 4 September 2007 October 2008 July 2009 April 2010
  • 12. Windows Phone 7 Framework Windows Phone Frameworks Camera Device Integration Launchers & Choosers Windows Phone Controls PhoneApplicationPage PushNotification WebBrowserControl Sensors PhoneApplicationFrame Silverlight Presentation and Media XNA Frameworks for Games Controls Drawing IsolatedStorage Drawing GamerServices Navigation Shapes Markup Media Audio Media Graphics Content Input Application Object Common Base Class Library Diagnostics Reflection IO Runtime Resources Globalization Text Location Net Collections ComponentModel Configuration Security Threading ServiceModel Linq
  • 13. Graphics Composition Start Experience System Tray Direct3D Surface AppPage Notification Volume SIP Incoming Call App Bar Shell frame composes all UI into a single screen Central page management enables cross app UI transitions and other effects You can also do this for orientation changes
  • 14. UI Model: Familiar Web Concepts Phone application Provides UI represented as XAML pages connected into cross-app flows by URI’s Web application Provide media represented as HTTP resources linked by URL’s Shell frame Requests pages, renders UI, and handles navigation across apps Web browser Requests HTTP resources, renders them, and handles navigation across sites Sessions and back stack Groups together sequences of pages corresponding to a user’s activity across apps History and tabs Groups together sequences of HTTP resources corresponding to a user’s activity across sites
  • 16. Silverlight Controls Rich Set of Controls Familiar Additional features For example, Software Input Panel (SIP) support on TextBox 16
  • 17. Supported Border Button Canvas CheckBox Grid HyperlinkButton Image ListBox MediaElement Messagebox ProgressBar RadioButton ScrollViewer TextBlock TextBox WebBrowser
  • 18. Controls support Touch Mouse Events Automatically converted for you SIP and WebBrowser control have gestures ScrollViewer Just like Silverlight Basic Flick and Pan gestures Raw Touch.FrameRendered DoodlePad – Sketch App
  • 19. Controls support Touch Gestures System level (WM_GESTURE). Can make your own. Tap, Double Tap, Pan, Flick, Touch and Hold Multi-Touch Pinch, Stretch Manipulations Events ManipulationStarted ManipulationData ManipulationCompleted Use for Drag and Drop, etc.
  • 21. List Application Master/Detail Data MainPage.Xaml, DetailsPage.xaml ViewModel ItemViewModel.cs, MainViewModel.cs Project Types VS2010 calls it List Application and Blend calls it Databound Application
  • 22. DEMO – List Application
  • 23. WebBrowser control Displays network and local content Gestures: pan, double tap and pinch Supports transforms & projections No Input on transform Application can interact with JavaScript Optimized for privacy Script is disabled by default Cookies and cache are isolated 23
  • 24. Silverlight to Script Silverlight string fromScript = wb.InvokeScript("runScriptStuff", arg1, arg2); JavaScript function runScriptStuff(arg1, arg2) { return “awesome”; }
  • 25. Script to Silverlight Silverlight void wb_ScriptNotify(object s, NotifyEventArgs e) { string fromScript = e.Value; } JavaScript Window.external.Notify(string);
  • 26. DEMO – Web Browser
  • 27. AppBar Toolbar Up to 4 icons Can set transparency level Slide up Menu can display more items Can declare in code or XAML Icons found under Program Filesicrosoft SDKsindows Phone7.0cons
  • 28. AppBar Icons 48 pixels by 48 pixels White foreground on a transparent background Using alpha channel. Icon get colorized to current style Circle will be added
  • 30. Frame and Page Frame Top-level container control PhoneApplicationFrame class Contains the page control and system elements such as system tray and application bar Page Fills the entire content region of the frame PhoneApplicationPage-derived class Optionally surfaces its own application bar Handles Orientation NavigatedTo and NavigatedFrom
  • 31. Page Navigation Forward NavigationService.Navigate(new Uri(“/Page2.xaml”,uriKind.RelativeOrAbsolute)); Back NavigationService.GoBack(); Hardware Back Button Handle BackKeyPress, OnBackKeyPressand Navigate to where you would like
  • 33. Tasks - Launchers and Choosers Launcher Launches one of the built-in applications through which a user completes a task No data is returned to calling application Example: PhoneCallTask Chooser Launches one of the built-in applications through which a user completes a task, and which returns some data to calling application When caller completes, calling application is activated and supplied with the Chooser result Example: PhotoChooserTask
  • 34. Launchers & Choosers Launchers EmailComposeTask MarketplaceDetailTask MarketplaceHubTask MarketplaceReviewTask MarketplaceSearchTask MediaPlayerLauncher PhoneCallTask SearchTask SMSComposeTask WebBrowserTask Choosers CameraCaptureTask EmailAddressChooserTask PhoneNumberChooserTask PhotoChooserTask SaveEmailAddressTask SavePhoneNumberTask
  • 36. UI and State Management: Concepts Page UI Describes the visual appearance of a page Retained in shell frame to support resuming paused sessions Discarded while the session is paused Page State Contains data that describes an instance of a page, analogous to browser cookie
  • 37. App Lifecycle Close Back Button Tombstoned Start Button Task Launched Phone call received Handle events in App.xaml.cs
  • 38. App State - Storage Isolated Storage Settings and Custom Data Secure and Sandboxed Logical Folder Structure via APIs No quota currently Be responsible and inform/empower user State Management PhoneApplicationPage/PhoneApplicationState Good for transient data
  • 39. Isolated Storage API Using System.IO;using System.IO.IsolatedStorage;IsolatedStoragefileisf = IsolatedStorageFile.GetUserStoreForApplication(); IsolatedStorageFileStreamfs = new IsolatedStorageFileStream(“myfile.txt”,FileMode.Open,isf); StreamReadersr = new StreamReader(fs); data=sr.ReadLine(); sr.Close();
  • 42. Calling a Service WebClient Class Just like Silverlight WebClient client = new WebClient(); client.DownloadStringCompleted += DownloadComplete; client.DownloadStringAsync(new Uri(RssUrl)); oData Library oData.org Covered this afternoon
  • 43. DEMO 9 – Netflix Web Service
  • 45. © 2010 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.