SlideShare a Scribd company logo
1 of 24
Developing cross-platform mobile
  applications with PhoneGap


         @ColinEberhardt
Overview

Why cross-platform?
Introduction to PhoneGap
 PhoneGap APIs, History of PhoneGap WP7
A simple PhoneGap application
 How PhoneGap works
A more complex application
 KnockoutJS – MVVM, Property Finder
 iOS ‘view’
Is PhoneGap a viable approach?
Why cross platform?




                      http://bit.ly/gartner-wp7-share
Rewrite for each platform
What is PhoneGap?




                           Phone APIs
              HTML /
             JavaScript
             Application




                           Phone APIs
PhoneGap APIs


  Accelerometer   Events
  Compass         File
  Camera          Geolocation
  Capture         Media
  Connection      Notification
  Contacts        Storage
  Device
PhoneGap for Windows Phone 7

PhoneGap, first stable release, Feb 2009
Matt Lacey, August 2010, initial implementation
PhoneGap for WP7 beta, Sept 2011
Mango roll-out, Oct 2011
Adobe acquires Nitobi, Oct 2011
Property Finder enters Marketplace, Nov 2011
  http://bit.ly/property-finder
WP7 fully supported, Jan 2012
Our first PhoneGap app


PhoneGap application template
  Overview of the various files
   ‘www’ folder - HTML / JS / image assets
   GapSourceDictionary.xml
   Regular WP7 Silverlight files


Simple modification
  Read accelerometer data
How does it work?

                   PhoneGap                 PhoneGap C#
                   JavaScript                   code            Accelerometer

acc.getCurrentPosition()


                           window.external.Notify()
                                                      getAcceleration()



                                                      DispatchResult()


                                 ScriptNotify()
Applications styles

Multi-page applications
  Separate HTML pages
  JavaScript re-loaded between each page
  No state transferred from page-to-page
  Back-button handling required
   http://bit.ly/wp7-multipage-phonegap


Single-page applications
  Page updates as application state changes
   ‘think’ GMail
Twitter Search


       http://knockoutjs.com/

       Demo running FireFox
       Back-button handling
Native look and feel

CSS Styling
  Does not support pressed state


Disable pinch / tap zoom
  Requires some ‘hacking’
  http://bit.ly/suppress-pinch


Gray highlight
  You’re stuck with it!
The WP7 IE9 browser

Pros
 Much better than the pre-mango!
 http://bit.ly/ie9-mobile-features
   Canvas, video, audio
   Many CSS3 features
Cons
 A lack of touch events
 The ‘gray link’ issue
   http://bit.ly/stackoverflow-gray-highlight
Property Finder (video)




The first HTML5-based WP7 app (I think!)
Uncovered a few PhoneGap issues!
Cross platform?


Knockout JS enables the use of MVVM
The ‘view’ code is currently WP7 specific
For iOS use a different view
  http://jquerymobile.com/
Property Finder iOS
PhoneGap Build
Property Finder iOS (video)
Is PhoneGap a viable approach?

Set-up cost is low
  PhoneGap build removes the need for a Mac
  Browser-based testing


Browser specific JavaScript / CSS code
  Often handled by existing JavaScript libraries
  More required if you want to have a native ‘feel’
   Currently most people roll-out an iOS look to Android


WP7 IE9 browser is _almost_ good enough
  Webkit browsers also have major flaws – overflow:scroll
Is PhoneGap a viable approach?




  Create an application with its own identity
The JavaScript advantage

JavaScript is ubiquitous
  Re-use code for a Windows 8 Metro App
  Re-use code for web-app


JavaScript is relatively future proof

Offline applications
  Uses the HTML5 app-cache
   The FT iPad application is a good example
  Frees you from the marketplace
Would I use it? Or go native?



 It depends!
   Project budget
   Number of platforms targeted
   Richness of content being delivered
   Willingness to depart from native UIs
PhoneGap alternatives

MonoTouch
  C# with bindings to native controls
  http://xamarin.com/monotouch


Appcelerator Titanium
  Previously ran JavaScript in browser, now compiles to
  native
  http://www.appcelerator.com/


Adobe Mobile Air
  AS3 running within the Air runtime
  http://www.adobe.com/products/air.html
Questions?




Image credit: Lattice by ColinBroug
(http://www.sxc.hu/photo/1359433)

More Related Content

What's hot

PhoneGap: Building Mobile Applications with HTML/JS
PhoneGap: Building Mobile Applications with HTML/JSPhoneGap: Building Mobile Applications with HTML/JS
PhoneGap: Building Mobile Applications with HTML/JSRyan Stewart
 
(2015년 상반기) HTML5 및 Hybrid app 최신 동향
(2015년 상반기) HTML5 및 Hybrid app 최신 동향(2015년 상반기) HTML5 및 Hybrid app 최신 동향
(2015년 상반기) HTML5 및 Hybrid app 최신 동향Wonsuk Lee
 
Mobile web application development
Mobile web application developmentMobile web application development
Mobile web application developmentVince Aggrippino
 
快快樂樂利用 PhoneGap 打造屬於自己的 App
快快樂樂利用 PhoneGap 打造屬於自己的 App快快樂樂利用 PhoneGap 打造屬於自己的 App
快快樂樂利用 PhoneGap 打造屬於自己的 Appericpi Bi
 
Georges Chitiga - Introduction to Phonegap - HTML5 & JS to native mobile app
Georges Chitiga - Introduction to Phonegap - HTML5 & JS to native mobile appGeorges Chitiga - Introduction to Phonegap - HTML5 & JS to native mobile app
Georges Chitiga - Introduction to Phonegap - HTML5 & JS to native mobile appCodecamp Romania
 
Phonegap/Cordova vs Native Application
Phonegap/Cordova vs Native ApplicationPhonegap/Cordova vs Native Application
Phonegap/Cordova vs Native ApplicationMuhammad Hakim A
 
N2Y4 Mobile Challenge May 2009 San Jose
N2Y4 Mobile Challenge May 2009   San JoseN2Y4 Mobile Challenge May 2009   San Jose
N2Y4 Mobile Challenge May 2009 San JoseAdhearsion Foundation
 
Apache Cordova, Hybrid Application Development
Apache Cordova, Hybrid Application DevelopmentApache Cordova, Hybrid Application Development
Apache Cordova, Hybrid Application Developmentthedumbterminal
 
BayJax: Expanding Yahoo! Axis across 3 screens
BayJax: Expanding Yahoo! Axis across 3 screensBayJax: Expanding Yahoo! Axis across 3 screens
BayJax: Expanding Yahoo! Axis across 3 screensCaridy Patino
 
PhoneGap Day US 2013 - Chrome Packaged Apps
PhoneGap Day US 2013 - Chrome Packaged AppsPhoneGap Day US 2013 - Chrome Packaged Apps
PhoneGap Day US 2013 - Chrome Packaged AppsPhoneGap
 
Vue storefront London PWA meetup
Vue storefront London PWA meetupVue storefront London PWA meetup
Vue storefront London PWA meetupFilip Rakowski
 
Making HTML5 Work Everywhere
Making HTML5 Work EverywhereMaking HTML5 Work Everywhere
Making HTML5 Work EverywhereTodd Anglin
 
HTML5 and jQuery Mobile
HTML5 and jQuery MobileHTML5 and jQuery Mobile
HTML5 and jQuery MobileKeir Bowden
 
Kendo UI 101
Kendo UI 101Kendo UI 101
Kendo UI 101Sam Basu
 
PhoneGap - What It Actually Is
PhoneGap - What It Actually IsPhoneGap - What It Actually Is
PhoneGap - What It Actually IsMarkiyan Matsekh
 
Performance optimization of vue.js apps with modern js
Performance optimization of vue.js apps with modern jsPerformance optimization of vue.js apps with modern js
Performance optimization of vue.js apps with modern jsFilip Rakowski
 
Developing for Windows Phone 7
Developing for Windows Phone 7Developing for Windows Phone 7
Developing for Windows Phone 7Gergely Orosz
 
10min mobile-app
10min mobile-app10min mobile-app
10min mobile-appeasychen
 

What's hot (20)

PhoneGap: Building Mobile Applications with HTML/JS
PhoneGap: Building Mobile Applications with HTML/JSPhoneGap: Building Mobile Applications with HTML/JS
PhoneGap: Building Mobile Applications with HTML/JS
 
(2015년 상반기) HTML5 및 Hybrid app 최신 동향
(2015년 상반기) HTML5 및 Hybrid app 최신 동향(2015년 상반기) HTML5 및 Hybrid app 최신 동향
(2015년 상반기) HTML5 및 Hybrid app 최신 동향
 
Mobile web application development
Mobile web application developmentMobile web application development
Mobile web application development
 
快快樂樂利用 PhoneGap 打造屬於自己的 App
快快樂樂利用 PhoneGap 打造屬於自己的 App快快樂樂利用 PhoneGap 打造屬於自己的 App
快快樂樂利用 PhoneGap 打造屬於自己的 App
 
Georges Chitiga - Introduction to Phonegap - HTML5 & JS to native mobile app
Georges Chitiga - Introduction to Phonegap - HTML5 & JS to native mobile appGeorges Chitiga - Introduction to Phonegap - HTML5 & JS to native mobile app
Georges Chitiga - Introduction to Phonegap - HTML5 & JS to native mobile app
 
Phonegap/Cordova vs Native Application
Phonegap/Cordova vs Native ApplicationPhonegap/Cordova vs Native Application
Phonegap/Cordova vs Native Application
 
N2Y4 Mobile Challenge May 2009 San Jose
N2Y4 Mobile Challenge May 2009   San JoseN2Y4 Mobile Challenge May 2009   San Jose
N2Y4 Mobile Challenge May 2009 San Jose
 
Apache Cordova, Hybrid Application Development
Apache Cordova, Hybrid Application DevelopmentApache Cordova, Hybrid Application Development
Apache Cordova, Hybrid Application Development
 
BayJax: Expanding Yahoo! Axis across 3 screens
BayJax: Expanding Yahoo! Axis across 3 screensBayJax: Expanding Yahoo! Axis across 3 screens
BayJax: Expanding Yahoo! Axis across 3 screens
 
Maintainable design
Maintainable designMaintainable design
Maintainable design
 
PhoneGap Day US 2013 - Chrome Packaged Apps
PhoneGap Day US 2013 - Chrome Packaged AppsPhoneGap Day US 2013 - Chrome Packaged Apps
PhoneGap Day US 2013 - Chrome Packaged Apps
 
Vue storefront London PWA meetup
Vue storefront London PWA meetupVue storefront London PWA meetup
Vue storefront London PWA meetup
 
Making HTML5 Work Everywhere
Making HTML5 Work EverywhereMaking HTML5 Work Everywhere
Making HTML5 Work Everywhere
 
Introduction to jQueryMobile
Introduction to jQueryMobileIntroduction to jQueryMobile
Introduction to jQueryMobile
 
HTML5 and jQuery Mobile
HTML5 and jQuery MobileHTML5 and jQuery Mobile
HTML5 and jQuery Mobile
 
Kendo UI 101
Kendo UI 101Kendo UI 101
Kendo UI 101
 
PhoneGap - What It Actually Is
PhoneGap - What It Actually IsPhoneGap - What It Actually Is
PhoneGap - What It Actually Is
 
Performance optimization of vue.js apps with modern js
Performance optimization of vue.js apps with modern jsPerformance optimization of vue.js apps with modern js
Performance optimization of vue.js apps with modern js
 
Developing for Windows Phone 7
Developing for Windows Phone 7Developing for Windows Phone 7
Developing for Windows Phone 7
 
10min mobile-app
10min mobile-app10min mobile-app
10min mobile-app
 

Viewers also liked

ReactiveCocoa and Swift, Better Together
ReactiveCocoa and Swift, Better TogetherReactiveCocoa and Swift, Better Together
ReactiveCocoa and Swift, Better TogetherColin Eberhardt
 
Cross platform mobile applications - Touch Tour Chennai
Cross platform mobile applications - Touch Tour ChennaiCross platform mobile applications - Touch Tour Chennai
Cross platform mobile applications - Touch Tour ChennaiRIA RUI Society
 
Reactive cocoa made Simple with Swift
Reactive cocoa made Simple with SwiftReactive cocoa made Simple with Swift
Reactive cocoa made Simple with SwiftColin Eberhardt
 

Viewers also liked (6)

ReactiveCocoa and Swift, Better Together
ReactiveCocoa and Swift, Better TogetherReactiveCocoa and Swift, Better Together
ReactiveCocoa and Swift, Better Together
 
Cross platform mobile applications - Touch Tour Chennai
Cross platform mobile applications - Touch Tour ChennaiCross platform mobile applications - Touch Tour Chennai
Cross platform mobile applications - Touch Tour Chennai
 
Reactive cocoa made Simple with Swift
Reactive cocoa made Simple with SwiftReactive cocoa made Simple with Swift
Reactive cocoa made Simple with Swift
 
Building Cross Platform Mobile Applications
Building Cross Platform Mobile ApplicationsBuilding Cross Platform Mobile Applications
Building Cross Platform Mobile Applications
 
Web server
Web serverWeb server
Web server
 
Web servers
Web serversWeb servers
Web servers
 

Similar to Developing cross platform mobile applications with phone gap for windows phone

DevChatt 2011 - PhoneGap: For Fun and Science
DevChatt 2011 - PhoneGap: For Fun and ScienceDevChatt 2011 - PhoneGap: For Fun and Science
DevChatt 2011 - PhoneGap: For Fun and ScienceCameron Kilgore
 
PhoneGap/PhoneGap Build - Amsterdam Adobe Camp
PhoneGap/PhoneGap Build - Amsterdam Adobe CampPhoneGap/PhoneGap Build - Amsterdam Adobe Camp
PhoneGap/PhoneGap Build - Amsterdam Adobe CampMihai Corlan
 
Brian Le Roux Presentation Introducing Phone Gap
Brian Le Roux Presentation Introducing Phone GapBrian Le Roux Presentation Introducing Phone Gap
Brian Le Roux Presentation Introducing Phone GapAjax Experience 2009
 
HTML5 Technical Executive Summary
HTML5 Technical Executive SummaryHTML5 Technical Executive Summary
HTML5 Technical Executive SummaryGilad Khen
 
Building Mobile Web Apps using ASP.NET MVC, HTML5, & jQuery Mobile
Building Mobile Web Apps using ASP.NET MVC, HTML5, & jQuery MobileBuilding Mobile Web Apps using ASP.NET MVC, HTML5, & jQuery Mobile
Building Mobile Web Apps using ASP.NET MVC, HTML5, & jQuery MobileJon Cortez
 
Getting Acquainted with PhoneGap
Getting Acquainted with PhoneGapGetting Acquainted with PhoneGap
Getting Acquainted with PhoneGapJoseph Labrecque
 
Mobile Drupal
Mobile DrupalMobile Drupal
Mobile DrupalTwinbit
 
Getting started with PhoneGap
Getting started with PhoneGapGetting started with PhoneGap
Getting started with PhoneGapMihai Corlan
 
FEDM Meetup: Introducing Mojito
FEDM Meetup: Introducing MojitoFEDM Meetup: Introducing Mojito
FEDM Meetup: Introducing MojitoCaridy Patino
 
Build Cross-Platform Mobile Application with PhoneGap
Build Cross-Platform Mobile Application with PhoneGapBuild Cross-Platform Mobile Application with PhoneGap
Build Cross-Platform Mobile Application with PhoneGapAllan Huang
 
Cross Platform Development Strategies with vendor review and PhoneGap case study
Cross Platform Development Strategies with vendor review and PhoneGap case studyCross Platform Development Strategies with vendor review and PhoneGap case study
Cross Platform Development Strategies with vendor review and PhoneGap case studyElegant Technologies, LLC
 
Building Cross-Platform Mobile Apps
Building Cross-Platform Mobile AppsBuilding Cross-Platform Mobile Apps
Building Cross-Platform Mobile AppsTroy Miles
 
Phone gap in android technology
Phone gap in android technologyPhone gap in android technology
Phone gap in android technologyVikrant Thakare
 
Developing Windows Phone 8 apps using PhoneGap
Developing Windows Phone 8 apps using PhoneGapDeveloping Windows Phone 8 apps using PhoneGap
Developing Windows Phone 8 apps using PhoneGapAmar Mesic
 
Building Native Mobile Applications with PhoneGap
Building Native Mobile Applications with PhoneGapBuilding Native Mobile Applications with PhoneGap
Building Native Mobile Applications with PhoneGapSimon MacDonald
 

Similar to Developing cross platform mobile applications with phone gap for windows phone (20)

PhoneGap
PhoneGapPhoneGap
PhoneGap
 
DevChatt 2011 - PhoneGap: For Fun and Science
DevChatt 2011 - PhoneGap: For Fun and ScienceDevChatt 2011 - PhoneGap: For Fun and Science
DevChatt 2011 - PhoneGap: For Fun and Science
 
PhoneGap/PhoneGap Build - Amsterdam Adobe Camp
PhoneGap/PhoneGap Build - Amsterdam Adobe CampPhoneGap/PhoneGap Build - Amsterdam Adobe Camp
PhoneGap/PhoneGap Build - Amsterdam Adobe Camp
 
Brian Le Roux Presentation Introducing Phone Gap
Brian Le Roux Presentation Introducing Phone GapBrian Le Roux Presentation Introducing Phone Gap
Brian Le Roux Presentation Introducing Phone Gap
 
Intro to PhoneGap
Intro to PhoneGapIntro to PhoneGap
Intro to PhoneGap
 
HTML5 Technical Executive Summary
HTML5 Technical Executive SummaryHTML5 Technical Executive Summary
HTML5 Technical Executive Summary
 
Building Mobile Web Apps using ASP.NET MVC, HTML5, & jQuery Mobile
Building Mobile Web Apps using ASP.NET MVC, HTML5, & jQuery MobileBuilding Mobile Web Apps using ASP.NET MVC, HTML5, & jQuery Mobile
Building Mobile Web Apps using ASP.NET MVC, HTML5, & jQuery Mobile
 
Getting Acquainted with PhoneGap
Getting Acquainted with PhoneGapGetting Acquainted with PhoneGap
Getting Acquainted with PhoneGap
 
Mobile Drupal
Mobile DrupalMobile Drupal
Mobile Drupal
 
Getting started with PhoneGap
Getting started with PhoneGapGetting started with PhoneGap
Getting started with PhoneGap
 
FEDM Meetup: Introducing Mojito
FEDM Meetup: Introducing MojitoFEDM Meetup: Introducing Mojito
FEDM Meetup: Introducing Mojito
 
Build Cross-Platform Mobile Application with PhoneGap
Build Cross-Platform Mobile Application with PhoneGapBuild Cross-Platform Mobile Application with PhoneGap
Build Cross-Platform Mobile Application with PhoneGap
 
What is PhoneGap?
What is PhoneGap?What is PhoneGap?
What is PhoneGap?
 
Cross Platform Development Strategies with vendor review and PhoneGap case study
Cross Platform Development Strategies with vendor review and PhoneGap case studyCross Platform Development Strategies with vendor review and PhoneGap case study
Cross Platform Development Strategies with vendor review and PhoneGap case study
 
Building Cross-Platform Mobile Apps
Building Cross-Platform Mobile AppsBuilding Cross-Platform Mobile Apps
Building Cross-Platform Mobile Apps
 
Phone gap in android technology
Phone gap in android technologyPhone gap in android technology
Phone gap in android technology
 
Developing Windows Phone 8 apps using PhoneGap
Developing Windows Phone 8 apps using PhoneGapDeveloping Windows Phone 8 apps using PhoneGap
Developing Windows Phone 8 apps using PhoneGap
 
Hybrid mobile apps
Hybrid mobile appsHybrid mobile apps
Hybrid mobile apps
 
Building Native Mobile Applications with PhoneGap
Building Native Mobile Applications with PhoneGapBuilding Native Mobile Applications with PhoneGap
Building Native Mobile Applications with PhoneGap
 
Phonegap
PhonegapPhonegap
Phonegap
 

Recently uploaded

FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
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
 

Recently uploaded (20)

FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
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
 

Developing cross platform mobile applications with phone gap for windows phone

  • 1. Developing cross-platform mobile applications with PhoneGap @ColinEberhardt
  • 2. Overview Why cross-platform? Introduction to PhoneGap PhoneGap APIs, History of PhoneGap WP7 A simple PhoneGap application How PhoneGap works A more complex application KnockoutJS – MVVM, Property Finder iOS ‘view’ Is PhoneGap a viable approach?
  • 3. Why cross platform? http://bit.ly/gartner-wp7-share
  • 4. Rewrite for each platform
  • 5. What is PhoneGap? Phone APIs HTML / JavaScript Application Phone APIs
  • 6. PhoneGap APIs Accelerometer Events Compass File Camera Geolocation Capture Media Connection Notification Contacts Storage Device
  • 7. PhoneGap for Windows Phone 7 PhoneGap, first stable release, Feb 2009 Matt Lacey, August 2010, initial implementation PhoneGap for WP7 beta, Sept 2011 Mango roll-out, Oct 2011 Adobe acquires Nitobi, Oct 2011 Property Finder enters Marketplace, Nov 2011 http://bit.ly/property-finder WP7 fully supported, Jan 2012
  • 8. Our first PhoneGap app PhoneGap application template Overview of the various files ‘www’ folder - HTML / JS / image assets GapSourceDictionary.xml Regular WP7 Silverlight files Simple modification Read accelerometer data
  • 9. How does it work? PhoneGap PhoneGap C# JavaScript code Accelerometer acc.getCurrentPosition() window.external.Notify() getAcceleration() DispatchResult() ScriptNotify()
  • 10. Applications styles Multi-page applications Separate HTML pages JavaScript re-loaded between each page No state transferred from page-to-page Back-button handling required http://bit.ly/wp7-multipage-phonegap Single-page applications Page updates as application state changes ‘think’ GMail
  • 11. Twitter Search http://knockoutjs.com/ Demo running FireFox Back-button handling
  • 12. Native look and feel CSS Styling Does not support pressed state Disable pinch / tap zoom Requires some ‘hacking’ http://bit.ly/suppress-pinch Gray highlight You’re stuck with it!
  • 13. The WP7 IE9 browser Pros Much better than the pre-mango! http://bit.ly/ie9-mobile-features Canvas, video, audio Many CSS3 features Cons A lack of touch events The ‘gray link’ issue http://bit.ly/stackoverflow-gray-highlight
  • 14. Property Finder (video) The first HTML5-based WP7 app (I think!) Uncovered a few PhoneGap issues!
  • 15. Cross platform? Knockout JS enables the use of MVVM The ‘view’ code is currently WP7 specific For iOS use a different view http://jquerymobile.com/
  • 19. Is PhoneGap a viable approach? Set-up cost is low PhoneGap build removes the need for a Mac Browser-based testing Browser specific JavaScript / CSS code Often handled by existing JavaScript libraries More required if you want to have a native ‘feel’ Currently most people roll-out an iOS look to Android WP7 IE9 browser is _almost_ good enough Webkit browsers also have major flaws – overflow:scroll
  • 20. Is PhoneGap a viable approach? Create an application with its own identity
  • 21. The JavaScript advantage JavaScript is ubiquitous Re-use code for a Windows 8 Metro App Re-use code for web-app JavaScript is relatively future proof Offline applications Uses the HTML5 app-cache The FT iPad application is a good example Frees you from the marketplace
  • 22. Would I use it? Or go native? It depends! Project budget Number of platforms targeted Richness of content being delivered Willingness to depart from native UIs
  • 23. PhoneGap alternatives MonoTouch C# with bindings to native controls http://xamarin.com/monotouch Appcelerator Titanium Previously ran JavaScript in browser, now compiles to native http://www.appcelerator.com/ Adobe Mobile Air AS3 running within the Air runtime http://www.adobe.com/products/air.html
  • 24. Questions? Image credit: Lattice by ColinBroug (http://www.sxc.hu/photo/1359433)

Editor's Notes

  1. SETUP:PhoneGapStarter app loaded into VS4WP7Emulator started, accelerometer simulator startedFireFox started, pointing to TwitterSearch index page, property finder iOS on other tabVS4Web started with index.html, app.js, twitterSearchViewModel.js, applicationViewModel.js, wp7.css loaded
  2. Why cross-platform? – market shareIntroduction to PhoneGap – basic architecture, history of WP7 version (Matt Lacey), current status, Nitobi / Apache / Callback CordovaDeveloping simple page-based applications – hello world, page navigation, tombstoning, pinch zoom, back-stackjQuery-MobileDeveloping complex applications – structuring our JavaScript, MVVM, Property Finder – how cross platform is this solution?Knockout-JSBack-stack handlingConclusionsIs this a viable approach? – IE9 issues, gray rectangle,MonoTouch / MonoDroid
  3. HTML5 / JavaScript applicationPhoneGap provides: + A packaging mechanism + APIs for features that are outside of the scope of HTML5
  4. Timeline me!
  5. Anatomy of a basic applicationLaunch itdescribe it …‘www’ folder – HTML5 assetsGapSourceDictionary.xaml – files to load into local storage (required because you cannot read XAP content)ManifestProcessor.js – generates the aboveApp, MainPage, icons …Make changes to read accelerometerAdd JavaScriptAdd HTMLDiscuss how the JavaScript API works.
  6. NOTE: This is quite specific to the WP7 implementation of PhoneGap
  7. Execute applicationWalkthroughShow folder structure – mirrors Silverlight applicationKnockout-JS view modelShow how to run within FireFoxBack-button handling
  8. Just play the vid!
  9. NOTE: Horrible code required for vertical scrolling!
  10. Create a UI that works across platforms