SlideShare uma empresa Scribd logo
1 de 52
Baixar para ler offline
ACCESSING NATIVE APIS FROM
          SENCHA TOUCH
                            James Pearce
                            @jamespearce



Wednesday, November 2, 11
Web apps are
                             the future




Wednesday, November 2, 11
Native apps are
                             the present




Wednesday, November 2, 11
Native   Web

                Cross-platform       ✘      ✔

                        Linkable     ✘      ✔

                  Discoverable       ✔      ✘

                    Device APIs      ✔      ✘




Wednesday, November 2, 11
Native   Web   Hybrid

                Cross-platform       ✘      ✔       ✔

                        Linkable     ✘      ✔       ✔

                  Discoverable       ✔      ✘       ✔

                    Device APIs      ✔      ✘       ✔




Wednesday, November 2, 11
What is a hybrid app?




Wednesday, November 2, 11
Web
           Site


                            sites

                                    Web
                                    apps

                                             Native
                                             apps
           App




                                           Nativeness



Wednesday, November 2, 11
Web
           Site


                            sites
                                    Web
                                    apps
                                           Hybrid
                                            apps
                                                      Native
                                                      apps
           App




                                                    Nativeness



Wednesday, November 2, 11
Camera         WebFont        Video    Audio    Graphics
                                                                         HTTP
            Location
                                      CSS Styling & Layout               AJAX
            Contacts
                                                                        Events
                SMS                          JavaScript
                                                                        Sockets
          Orientation
                                           Semantic HTML                 SSL
                Gyro

                            File Systems      Workers &
                                                            Cross-App
                             Databases          Parallel
                                                            Messaging
                            App Caches        Processing




Wednesday, November 2, 11
WebView
             Camera         WebFont        Video    Audio    Graphics
                                                                         HTTP
            Location
                                      CSS Styling & Layout               AJAX
            Contacts
                                                                        Events
                SMS                          JavaScript
                                                                        Sockets
          Orientation
                                           Semantic HTML                 SSL
                Gyro

                            File Systems      Workers &
                                                            Cross-App
                             Databases          Parallel
                                                            Messaging
                            App Caches        Processing




Wednesday, November 2, 11
Native Wrapper

                                                      WebView
             Camera         WebFont        Video    Audio    Graphics
                                                                         HTTP
            Location
                                      CSS Styling & Layout               AJAX
            Contacts
                                                                        Events
                SMS                          JavaScript
                                                                        Sockets
          Orientation
                                           Semantic HTML                 SSL
                Gyro

                            File Systems      Workers &
                                                            Cross-App
                             Databases          Parallel
                                                            Messaging
                            App Caches        Processing




Wednesday, November 2, 11
Wednesday, November 2, 11
Wednesday, November 2, 11
Sencha Touch
                              Packager
                               Edmund Leung,
                              Product Manager




Wednesday, November 2, 11
Native Wrapper

                                                      WebView
             Camera         WebFont        Video    Audio    Graphics
                                                                         HTTP
            Location
                                      CSS Styling & Layout               AJAX
            Contacts
                                                                        Events
                SMS                          JavaScript
                                                                        Sockets
          Orientation
                                           Semantic HTML                 SSL
                Gyro

                            File Systems      Workers &
                                                            Cross-App
                             Databases          Parallel
                                                            Messaging
                            App Caches        Processing




Wednesday, November 2, 11
Native Wrapper

                                                      WebView
             Camera         WebFont        Video    Audio    Graphics
                                                                         HTTP
            Location
                                      CSS Styling & Layout               AJAX
            Contacts
                                                                        Events
                SMS                          JavaScript
                                                                        Sockets
          Orientation
                                           Semantic HTML                 SSL
                Gyro

                            File Systems      Workers &
                                                            Cross-App
                             Databases          Parallel
                                                            Messaging
                            App Caches        Processing




Wednesday, November 2, 11
Device Access
Wednesday, November 2, 11
Media Capture (HTML)      Media Capture (API)
               Battery status            Application Registration
               Contacts                  Calendar
               Messaging (SMS, MMS...)   Feature Permissions
               Network Information API   Sensor API
                                         Vibration API
                                         Menu API
               Audio Volume
                                         Permissions for APIs
               Beep
               Gallery
               Systems info and events
               Tasks


Wednesday, November 2, 11
Accelerometer       APDU (SmartCard)
               Orientation         Bluetooth
               Camera              Crypto
               DeviceStatus        DLNA
               Filesystem          Server Push
               Messaging           Sensor
               Geolocation         Telephony
               PIM 
               Contacts
               Calendar
               Tasks
               DeviceInteraction

Wednesday, November 2, 11
Wednesday, November 2, 11
Telephony
                            Messaging
                            Contacts
                            Clock
                            Camera
                            Filesystem
                            Calculator
                            Device Status
                            Settings
                            Accelerometer
                            Mouse Lock
                            Maps

Wednesday, November 2, 11
Wednesday, November 2, 11
Wednesday, November 2, 11
Developer choice is
                            limited by options




Wednesday, November 2, 11
Native Wrapper

                                                      WebView
             Camera         WebFont        Video    Audio    Graphics
                                                                         HTTP
            Location
                                      CSS Styling & Layout               AJAX
            Contacts
                                                                        Events
                SMS                          JavaScript
                                                                        Sockets
          Orientation
                                           Semantic HTML                 SSL
                Gyro

                            File Systems      Workers &
                                                            Cross-App
                             Databases          Parallel
                                                            Messaging
                            App Caches        Processing




Wednesday, November 2, 11
PhoneGap




Wednesday, November 2, 11
Apache




Wednesday, November 2, 11
Wednesday, November 2, 11
Wednesday, November 2, 11
Accelerometer                                  Events
              Tap into the device’s motion sensor.           Hook into native events through JavaScript.


              Camera                                         File
              Capture a photo using the device's camera.     Hook into native file system through
                                                             JavaScript.

              Capture
              Capture media files using device's media        Geolocation
              capture applications.                          Make your application location aware.


              Compass                                        Media
              Obtain the direction the device is pointing.   Record and play back audio files.


              Connection                                     Notification
              Quickly check the network state, and           Visual, audible, and tactile device
              cellular network information.                  notifications.


              Contacts                                       Storage
              Work with the devices contact database.        Hook into the device’s native storage
                                                             options.

              Device
              Gather device specific information.


Wednesday, November 2, 11
Project Setup




Wednesday, November 2, 11
Wednesday, November 2, 11
Wednesday, November 2, 11
Wednesday, November 2, 11
PhoneGap.plist




Wednesday, November 2, 11
Wednesday, November 2, 11
Wednesday, November 2, 11
AndroidManifest.xml




Wednesday, November 2, 11
Project Setup




Wednesday, November 2, 11
Accelerometer                                  Events
              Tap into the device’s motion sensor.           Hook into native events through JavaScript.


              Camera                                         File
              Capture a photo using the device's camera.     Hook into native file system through
                                                             JavaScript.

              Capture
              Capture media files using device's media        Geolocation
              capture applications.                          Make your application location aware.


              Compass                                        Media
              Obtain the direction the device is pointing.   Record and play back audio files.


              Connection                                     Notification
              Quickly check the network state, and           Visual, audible, and tactile device
              cellular network information.                  notifications.


              Contacts                                       Storage
              Work with the devices contact database.        Hook into the device’s native storage
                                                             options.

              Device
              Gather device specific information.


Wednesday, November 2, 11
Camera

                            navigator.camera.getPicture(

                                 function(imageData) {
                                 },

                                 function (message) {
                                 },

                                 {} //options

                            );



Wednesday, November 2, 11
Contacts

                            navigator.contacts.create(
                              {}
                            ).save();


                            navigator.contacts.find(
                               contactFields,
                               function(){},
                               function(){},
                               {}
                            );



Wednesday, November 2, 11
Demo




Wednesday, November 2, 11
AdPlugin/               LocalNotification/
                    ApplicationPreferences/           Localizable/
                         AudioEncode/                 MapKitPlug/
                         AudioRecord/               NativeControls/
                             Badge/                 NotificationEx/
                      BarcodeScanner/                PayPalPlugin/
                      BundleFileReader/           PowerManagement/
                         ChildBrowser/                PrintPlugin/
                       ClipboardPlugin/
                          DatePicker/
                                        Plugins         Prompt/
                                                    SMSComposer/
                       EmailComposer/                 ScreenShot/
                         FileUploader/              ShareKitPlugin/
                          GapSocket/                  SoundPlug/
                         Globalization/             SplashScreen/
                          HockeyApp/                   TestFlight/
                   InAppPurchaseManager/                 Torch/
                           Keychain/                 VolumeSlider/




Wednesday, November 2, 11
Caveats




Wednesday, November 2, 11
Obfuscation != security




                     +      =

Wednesday, November 2, 11
Quirks




                              ...
Wednesday, November 2, 11
Android        iOS
                            phonegap.js   phonegap.js   ...
Wednesday, November 2, 11
Avoid start race
               document.addEventListener(
                  "deviceready", app.mainLaunch, false
               );

               new Ext.Application({
                 launch: function() {
                    this.launched = true;
                    this.mainLaunch();
                 },
                 mainLaunch: function() {
                    if (!device || !this.launched) {return;}
                    ...
                 }
               });

Wednesday, November 2, 11
Wouldn’t it be
                             great if...




Wednesday, November 2, 11
Further...

                             http://sencha.com/x/cy

                             http://sencha.com/x/de


                            BlackBerry WebWorks APIs
                                 3:50pm - 4:30pm



Wednesday, November 2, 11
THANKS
                              James Pearce
                              @jamespearce



Wednesday, November 2, 11

Mais conteúdo relacionado

Semelhante a Accessing Native APIs from Touch

An Intro to Mobile HTML5
An Intro to Mobile HTML5An Intro to Mobile HTML5
An Intro to Mobile HTML5James Pearce
 
Distributed Shared Memory on Ericsson Labs
Distributed Shared Memory on Ericsson LabsDistributed Shared Memory on Ericsson Labs
Distributed Shared Memory on Ericsson LabsEricsson Labs
 
A Snapshot of the Mobile HTML5 Revolution
A Snapshot of the Mobile HTML5 RevolutionA Snapshot of the Mobile HTML5 Revolution
A Snapshot of the Mobile HTML5 RevolutionJames Pearce
 
MIX11アップデート ~Windows Phone 7, Silverlight 5, IE9, HTML5~ 前編
MIX11アップデート ~Windows Phone 7, Silverlight 5, IE9, HTML5~ 前編MIX11アップデート ~Windows Phone 7, Silverlight 5, IE9, HTML5~ 前編
MIX11アップデート ~Windows Phone 7, Silverlight 5, IE9, HTML5~ 前編Microsoft
 
Tacademy techclinic-2012-07-11
Tacademy techclinic-2012-07-11Tacademy techclinic-2012-07-11
Tacademy techclinic-2012-07-11영호 라
 
Next Generation Web Attacks – HTML 5, DOM(L3) and XHR(L2)
Next Generation Web Attacks – HTML 5, DOM(L3) and XHR(L2)Next Generation Web Attacks – HTML 5, DOM(L3) and XHR(L2)
Next Generation Web Attacks – HTML 5, DOM(L3) and XHR(L2)Shreeraj Shah
 
6.Live Framework 和Mesh Services
6.Live Framework 和Mesh Services6.Live Framework 和Mesh Services
6.Live Framework 和Mesh ServicesGaryYoung
 
HTML5, Silverlight & Kinect
HTML5, Silverlight & KinectHTML5, Silverlight & Kinect
HTML5, Silverlight & KinectFrank La Vigne
 
Cluedin JavaOne 2009
Cluedin JavaOne 2009Cluedin JavaOne 2009
Cluedin JavaOne 2009aegloff
 
Building cross platform mobile web apps
Building cross platform mobile web appsBuilding cross platform mobile web apps
Building cross platform mobile web appsJames Pearce
 
HTML5: State of the Union
HTML5: State of the UnionHTML5: State of the Union
HTML5: State of the UnionSencha
 
HTML5 and the dawn of rich mobile web applications
HTML5 and the dawn of rich mobile web applicationsHTML5 and the dawn of rich mobile web applications
HTML5 and the dawn of rich mobile web applicationsJames Pearce
 
Build and Deploy on OpenShift
Build and Deploy on OpenShiftBuild and Deploy on OpenShift
Build and Deploy on OpenShiftXavier Coulon
 
A Lap Around Silverlight 5
A Lap Around Silverlight 5A Lap Around Silverlight 5
A Lap Around Silverlight 5Frank La Vigne
 
Mesh-Enabled Web Applications
Mesh-Enabled Web ApplicationsMesh-Enabled Web Applications
Mesh-Enabled Web Applicationsgoodfriday
 
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
 
02 Ms Online Identity Session 1
02 Ms Online Identity   Session 102 Ms Online Identity   Session 1
02 Ms Online Identity Session 1Sivadon Chaisiri
 
Community Code: Pega Mobile
Community Code: Pega MobileCommunity Code: Pega Mobile
Community Code: Pega MobileSencha
 
Glass Fish Mobility Platform Santiago Pericas Geersten V2
Glass Fish Mobility Platform Santiago Pericas Geersten V2Glass Fish Mobility Platform Santiago Pericas Geersten V2
Glass Fish Mobility Platform Santiago Pericas Geersten V2Eduardo Pelegri-Llopart
 

Semelhante a Accessing Native APIs from Touch (20)

An Intro to Mobile HTML5
An Intro to Mobile HTML5An Intro to Mobile HTML5
An Intro to Mobile HTML5
 
Distributed Shared Memory on Ericsson Labs
Distributed Shared Memory on Ericsson LabsDistributed Shared Memory on Ericsson Labs
Distributed Shared Memory on Ericsson Labs
 
A Snapshot of the Mobile HTML5 Revolution
A Snapshot of the Mobile HTML5 RevolutionA Snapshot of the Mobile HTML5 Revolution
A Snapshot of the Mobile HTML5 Revolution
 
MIX11アップデート ~Windows Phone 7, Silverlight 5, IE9, HTML5~ 前編
MIX11アップデート ~Windows Phone 7, Silverlight 5, IE9, HTML5~ 前編MIX11アップデート ~Windows Phone 7, Silverlight 5, IE9, HTML5~ 前編
MIX11アップデート ~Windows Phone 7, Silverlight 5, IE9, HTML5~ 前編
 
Tacademy techclinic-2012-07-11
Tacademy techclinic-2012-07-11Tacademy techclinic-2012-07-11
Tacademy techclinic-2012-07-11
 
Next Generation Web Attacks – HTML 5, DOM(L3) and XHR(L2)
Next Generation Web Attacks – HTML 5, DOM(L3) and XHR(L2)Next Generation Web Attacks – HTML 5, DOM(L3) and XHR(L2)
Next Generation Web Attacks – HTML 5, DOM(L3) and XHR(L2)
 
6.Live Framework 和Mesh Services
6.Live Framework 和Mesh Services6.Live Framework 和Mesh Services
6.Live Framework 和Mesh Services
 
HTML5, Silverlight & Kinect
HTML5, Silverlight & KinectHTML5, Silverlight & Kinect
HTML5, Silverlight & Kinect
 
Cluedin JavaOne 2009
Cluedin JavaOne 2009Cluedin JavaOne 2009
Cluedin JavaOne 2009
 
Building cross platform mobile web apps
Building cross platform mobile web appsBuilding cross platform mobile web apps
Building cross platform mobile web apps
 
HTML5: State of the Union
HTML5: State of the UnionHTML5: State of the Union
HTML5: State of the Union
 
HTML5 and the dawn of rich mobile web applications
HTML5 and the dawn of rich mobile web applicationsHTML5 and the dawn of rich mobile web applications
HTML5 and the dawn of rich mobile web applications
 
Build and Deploy on OpenShift
Build and Deploy on OpenShiftBuild and Deploy on OpenShift
Build and Deploy on OpenShift
 
A Lap Around Silverlight 5
A Lap Around Silverlight 5A Lap Around Silverlight 5
A Lap Around Silverlight 5
 
Mesh-Enabled Web Applications
Mesh-Enabled Web ApplicationsMesh-Enabled Web Applications
Mesh-Enabled Web Applications
 
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
 
02 Ms Online Identity Session 1
02 Ms Online Identity   Session 102 Ms Online Identity   Session 1
02 Ms Online Identity Session 1
 
Community Code: Pega Mobile
Community Code: Pega MobileCommunity Code: Pega Mobile
Community Code: Pega Mobile
 
Glass Fish Mobility Platform Santiago Pericas Geersten V2
Glass Fish Mobility Platform Santiago Pericas Geersten V2Glass Fish Mobility Platform Santiago Pericas Geersten V2
Glass Fish Mobility Platform Santiago Pericas Geersten V2
 
T04f
T04fT04f
T04f
 

Mais de Sencha

Breathe New Life into Your Existing JavaScript Applications with Web Components
Breathe New Life into Your Existing JavaScript Applications with Web ComponentsBreathe New Life into Your Existing JavaScript Applications with Web Components
Breathe New Life into Your Existing JavaScript Applications with Web ComponentsSencha
 
Ext JS 6.6 Highlights
Ext JS 6.6 HighlightsExt JS 6.6 Highlights
Ext JS 6.6 HighlightsSencha
 
Sencha Roadshow 2017: BufferedStore Internals featuring eyeworkers interactiv...
Sencha Roadshow 2017: BufferedStore Internals featuring eyeworkers interactiv...Sencha Roadshow 2017: BufferedStore Internals featuring eyeworkers interactiv...
Sencha Roadshow 2017: BufferedStore Internals featuring eyeworkers interactiv...Sencha
 
Sencha Roadshow 2017: Build Progressive Web Apps with Ext JS and Cmd
Sencha Roadshow 2017: Build Progressive Web Apps with Ext JS and Cmd Sencha Roadshow 2017: Build Progressive Web Apps with Ext JS and Cmd
Sencha Roadshow 2017: Build Progressive Web Apps with Ext JS and Cmd Sencha
 
Sencha Roadshow 2017: Best Practices for Implementing Continuous Web App Testing
Sencha Roadshow 2017: Best Practices for Implementing Continuous Web App TestingSencha Roadshow 2017: Best Practices for Implementing Continuous Web App Testing
Sencha Roadshow 2017: Best Practices for Implementing Continuous Web App TestingSencha
 
Sencha Roadshow 2017: What's New in Sencha Test
Sencha Roadshow 2017: What's New in Sencha TestSencha Roadshow 2017: What's New in Sencha Test
Sencha Roadshow 2017: What's New in Sencha TestSencha
 
Sencha Roadshow 2017: Sencha Upgrades - The Good. The Bad. The Ugly - Eva Luc...
Sencha Roadshow 2017: Sencha Upgrades - The Good. The Bad. The Ugly - Eva Luc...Sencha Roadshow 2017: Sencha Upgrades - The Good. The Bad. The Ugly - Eva Luc...
Sencha Roadshow 2017: Sencha Upgrades - The Good. The Bad. The Ugly - Eva Luc...Sencha
 
Sencha Roadshow 2017: Modernizing the Ext JS Class System and Tooling
Sencha Roadshow 2017: Modernizing the Ext JS Class System and ToolingSencha Roadshow 2017: Modernizing the Ext JS Class System and Tooling
Sencha Roadshow 2017: Modernizing the Ext JS Class System and ToolingSencha
 
Sencha Roadshow 2017: Sencha Best Practices: Coworkee App
Sencha Roadshow 2017: Sencha Best Practices: Coworkee App Sencha Roadshow 2017: Sencha Best Practices: Coworkee App
Sencha Roadshow 2017: Sencha Best Practices: Coworkee App Sencha
 
Sencha Roadshow 2017: Mobile First or Desktop First
Sencha Roadshow 2017: Mobile First or Desktop FirstSencha Roadshow 2017: Mobile First or Desktop First
Sencha Roadshow 2017: Mobile First or Desktop FirstSencha
 
Sencha Roadshow 2017: Innovations in Ext JS 6.5 and Beyond
Sencha Roadshow 2017: Innovations in Ext JS 6.5 and BeyondSencha Roadshow 2017: Innovations in Ext JS 6.5 and Beyond
Sencha Roadshow 2017: Innovations in Ext JS 6.5 and BeyondSencha
 
Leveraging React and GraphQL to Create a Performant, Scalable Data Grid
Leveraging React and GraphQL to Create a Performant, Scalable Data GridLeveraging React and GraphQL to Create a Performant, Scalable Data Grid
Leveraging React and GraphQL to Create a Performant, Scalable Data GridSencha
 
Learn Key Insights from The State of Web Application Testing Research Report
Learn Key Insights from The State of Web Application Testing Research ReportLearn Key Insights from The State of Web Application Testing Research Report
Learn Key Insights from The State of Web Application Testing Research ReportSencha
 
Introducing ExtReact: Adding Powerful Sencha Components to React Apps
Introducing ExtReact: Adding Powerful Sencha Components to React AppsIntroducing ExtReact: Adding Powerful Sencha Components to React Apps
Introducing ExtReact: Adding Powerful Sencha Components to React AppsSencha
 
SenchaCon 2016: Keynote Presentation - Art Landro, Gautam Agrawal, Mark Brocato
SenchaCon 2016: Keynote Presentation - Art Landro, Gautam Agrawal, Mark BrocatoSenchaCon 2016: Keynote Presentation - Art Landro, Gautam Agrawal, Mark Brocato
SenchaCon 2016: Keynote Presentation - Art Landro, Gautam Agrawal, Mark BrocatoSencha
 
SenchaCon 2016: Add Magic to Your Ext JS Apps with D3 Visualizations - Vitaly...
SenchaCon 2016: Add Magic to Your Ext JS Apps with D3 Visualizations - Vitaly...SenchaCon 2016: Add Magic to Your Ext JS Apps with D3 Visualizations - Vitaly...
SenchaCon 2016: Add Magic to Your Ext JS Apps with D3 Visualizations - Vitaly...Sencha
 
SenchaCon 2016: LinkRest - Modern RESTful API Framework for Ext JS Apps - Rou...
SenchaCon 2016: LinkRest - Modern RESTful API Framework for Ext JS Apps - Rou...SenchaCon 2016: LinkRest - Modern RESTful API Framework for Ext JS Apps - Rou...
SenchaCon 2016: LinkRest - Modern RESTful API Framework for Ext JS Apps - Rou...Sencha
 
SenchaCon 2016: Expect the Unexpected - Dealing with Errors in Web Apps
SenchaCon 2016: Expect the Unexpected - Dealing with Errors in Web AppsSenchaCon 2016: Expect the Unexpected - Dealing with Errors in Web Apps
SenchaCon 2016: Expect the Unexpected - Dealing with Errors in Web AppsSencha
 
Ext JS Architecture Best Practices - Mitchell Simeons
Ext JS Architecture Best Practices - Mitchell SimeonsExt JS Architecture Best Practices - Mitchell Simeons
Ext JS Architecture Best Practices - Mitchell SimeonsSencha
 
SenchaCon 2016: Mobile First? Desktop First? Or Should you Think Universal Ap...
SenchaCon 2016: Mobile First? Desktop First? Or Should you Think Universal Ap...SenchaCon 2016: Mobile First? Desktop First? Or Should you Think Universal Ap...
SenchaCon 2016: Mobile First? Desktop First? Or Should you Think Universal Ap...Sencha
 

Mais de Sencha (20)

Breathe New Life into Your Existing JavaScript Applications with Web Components
Breathe New Life into Your Existing JavaScript Applications with Web ComponentsBreathe New Life into Your Existing JavaScript Applications with Web Components
Breathe New Life into Your Existing JavaScript Applications with Web Components
 
Ext JS 6.6 Highlights
Ext JS 6.6 HighlightsExt JS 6.6 Highlights
Ext JS 6.6 Highlights
 
Sencha Roadshow 2017: BufferedStore Internals featuring eyeworkers interactiv...
Sencha Roadshow 2017: BufferedStore Internals featuring eyeworkers interactiv...Sencha Roadshow 2017: BufferedStore Internals featuring eyeworkers interactiv...
Sencha Roadshow 2017: BufferedStore Internals featuring eyeworkers interactiv...
 
Sencha Roadshow 2017: Build Progressive Web Apps with Ext JS and Cmd
Sencha Roadshow 2017: Build Progressive Web Apps with Ext JS and Cmd Sencha Roadshow 2017: Build Progressive Web Apps with Ext JS and Cmd
Sencha Roadshow 2017: Build Progressive Web Apps with Ext JS and Cmd
 
Sencha Roadshow 2017: Best Practices for Implementing Continuous Web App Testing
Sencha Roadshow 2017: Best Practices for Implementing Continuous Web App TestingSencha Roadshow 2017: Best Practices for Implementing Continuous Web App Testing
Sencha Roadshow 2017: Best Practices for Implementing Continuous Web App Testing
 
Sencha Roadshow 2017: What's New in Sencha Test
Sencha Roadshow 2017: What's New in Sencha TestSencha Roadshow 2017: What's New in Sencha Test
Sencha Roadshow 2017: What's New in Sencha Test
 
Sencha Roadshow 2017: Sencha Upgrades - The Good. The Bad. The Ugly - Eva Luc...
Sencha Roadshow 2017: Sencha Upgrades - The Good. The Bad. The Ugly - Eva Luc...Sencha Roadshow 2017: Sencha Upgrades - The Good. The Bad. The Ugly - Eva Luc...
Sencha Roadshow 2017: Sencha Upgrades - The Good. The Bad. The Ugly - Eva Luc...
 
Sencha Roadshow 2017: Modernizing the Ext JS Class System and Tooling
Sencha Roadshow 2017: Modernizing the Ext JS Class System and ToolingSencha Roadshow 2017: Modernizing the Ext JS Class System and Tooling
Sencha Roadshow 2017: Modernizing the Ext JS Class System and Tooling
 
Sencha Roadshow 2017: Sencha Best Practices: Coworkee App
Sencha Roadshow 2017: Sencha Best Practices: Coworkee App Sencha Roadshow 2017: Sencha Best Practices: Coworkee App
Sencha Roadshow 2017: Sencha Best Practices: Coworkee App
 
Sencha Roadshow 2017: Mobile First or Desktop First
Sencha Roadshow 2017: Mobile First or Desktop FirstSencha Roadshow 2017: Mobile First or Desktop First
Sencha Roadshow 2017: Mobile First or Desktop First
 
Sencha Roadshow 2017: Innovations in Ext JS 6.5 and Beyond
Sencha Roadshow 2017: Innovations in Ext JS 6.5 and BeyondSencha Roadshow 2017: Innovations in Ext JS 6.5 and Beyond
Sencha Roadshow 2017: Innovations in Ext JS 6.5 and Beyond
 
Leveraging React and GraphQL to Create a Performant, Scalable Data Grid
Leveraging React and GraphQL to Create a Performant, Scalable Data GridLeveraging React and GraphQL to Create a Performant, Scalable Data Grid
Leveraging React and GraphQL to Create a Performant, Scalable Data Grid
 
Learn Key Insights from The State of Web Application Testing Research Report
Learn Key Insights from The State of Web Application Testing Research ReportLearn Key Insights from The State of Web Application Testing Research Report
Learn Key Insights from The State of Web Application Testing Research Report
 
Introducing ExtReact: Adding Powerful Sencha Components to React Apps
Introducing ExtReact: Adding Powerful Sencha Components to React AppsIntroducing ExtReact: Adding Powerful Sencha Components to React Apps
Introducing ExtReact: Adding Powerful Sencha Components to React Apps
 
SenchaCon 2016: Keynote Presentation - Art Landro, Gautam Agrawal, Mark Brocato
SenchaCon 2016: Keynote Presentation - Art Landro, Gautam Agrawal, Mark BrocatoSenchaCon 2016: Keynote Presentation - Art Landro, Gautam Agrawal, Mark Brocato
SenchaCon 2016: Keynote Presentation - Art Landro, Gautam Agrawal, Mark Brocato
 
SenchaCon 2016: Add Magic to Your Ext JS Apps with D3 Visualizations - Vitaly...
SenchaCon 2016: Add Magic to Your Ext JS Apps with D3 Visualizations - Vitaly...SenchaCon 2016: Add Magic to Your Ext JS Apps with D3 Visualizations - Vitaly...
SenchaCon 2016: Add Magic to Your Ext JS Apps with D3 Visualizations - Vitaly...
 
SenchaCon 2016: LinkRest - Modern RESTful API Framework for Ext JS Apps - Rou...
SenchaCon 2016: LinkRest - Modern RESTful API Framework for Ext JS Apps - Rou...SenchaCon 2016: LinkRest - Modern RESTful API Framework for Ext JS Apps - Rou...
SenchaCon 2016: LinkRest - Modern RESTful API Framework for Ext JS Apps - Rou...
 
SenchaCon 2016: Expect the Unexpected - Dealing with Errors in Web Apps
SenchaCon 2016: Expect the Unexpected - Dealing with Errors in Web AppsSenchaCon 2016: Expect the Unexpected - Dealing with Errors in Web Apps
SenchaCon 2016: Expect the Unexpected - Dealing with Errors in Web Apps
 
Ext JS Architecture Best Practices - Mitchell Simeons
Ext JS Architecture Best Practices - Mitchell SimeonsExt JS Architecture Best Practices - Mitchell Simeons
Ext JS Architecture Best Practices - Mitchell Simeons
 
SenchaCon 2016: Mobile First? Desktop First? Or Should you Think Universal Ap...
SenchaCon 2016: Mobile First? Desktop First? Or Should you Think Universal Ap...SenchaCon 2016: Mobile First? Desktop First? Or Should you Think Universal Ap...
SenchaCon 2016: Mobile First? Desktop First? Or Should you Think Universal Ap...
 

Último

Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfRankYa
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Manik S Magar
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyAlfredo García Lavilla
 
Training state-of-the-art general text embedding
Training state-of-the-art general text embeddingTraining state-of-the-art general text embedding
Training state-of-the-art general text embeddingZilliz
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
The Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfThe Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfSeasiaInfotech2
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Wonjun Hwang
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 

Último (20)

Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdf
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easy
 
Training state-of-the-art general text embedding
Training state-of-the-art general text embeddingTraining state-of-the-art general text embedding
Training state-of-the-art general text embedding
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
The Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfThe Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdf
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 

Accessing Native APIs from Touch

  • 1. ACCESSING NATIVE APIS FROM SENCHA TOUCH James Pearce @jamespearce Wednesday, November 2, 11
  • 2. Web apps are the future Wednesday, November 2, 11
  • 3. Native apps are the present Wednesday, November 2, 11
  • 4. Native Web Cross-platform ✘ ✔ Linkable ✘ ✔ Discoverable ✔ ✘ Device APIs ✔ ✘ Wednesday, November 2, 11
  • 5. Native Web Hybrid Cross-platform ✘ ✔ ✔ Linkable ✘ ✔ ✔ Discoverable ✔ ✘ ✔ Device APIs ✔ ✘ ✔ Wednesday, November 2, 11
  • 6. What is a hybrid app? Wednesday, November 2, 11
  • 7. Web Site sites Web apps Native apps App Nativeness Wednesday, November 2, 11
  • 8. Web Site sites Web apps Hybrid apps Native apps App Nativeness Wednesday, November 2, 11
  • 9. Camera WebFont Video Audio Graphics HTTP Location CSS Styling & Layout AJAX Contacts Events SMS JavaScript Sockets Orientation Semantic HTML SSL Gyro File Systems Workers & Cross-App Databases Parallel Messaging App Caches Processing Wednesday, November 2, 11
  • 10. WebView Camera WebFont Video Audio Graphics HTTP Location CSS Styling & Layout AJAX Contacts Events SMS JavaScript Sockets Orientation Semantic HTML SSL Gyro File Systems Workers & Cross-App Databases Parallel Messaging App Caches Processing Wednesday, November 2, 11
  • 11. Native Wrapper WebView Camera WebFont Video Audio Graphics HTTP Location CSS Styling & Layout AJAX Contacts Events SMS JavaScript Sockets Orientation Semantic HTML SSL Gyro File Systems Workers & Cross-App Databases Parallel Messaging App Caches Processing Wednesday, November 2, 11
  • 14. Sencha Touch Packager Edmund Leung, Product Manager Wednesday, November 2, 11
  • 15. Native Wrapper WebView Camera WebFont Video Audio Graphics HTTP Location CSS Styling & Layout AJAX Contacts Events SMS JavaScript Sockets Orientation Semantic HTML SSL Gyro File Systems Workers & Cross-App Databases Parallel Messaging App Caches Processing Wednesday, November 2, 11
  • 16. Native Wrapper WebView Camera WebFont Video Audio Graphics HTTP Location CSS Styling & Layout AJAX Contacts Events SMS JavaScript Sockets Orientation Semantic HTML SSL Gyro File Systems Workers & Cross-App Databases Parallel Messaging App Caches Processing Wednesday, November 2, 11
  • 18. Media Capture (HTML) Media Capture (API) Battery status Application Registration Contacts Calendar Messaging (SMS, MMS...) Feature Permissions Network Information API Sensor API Vibration API Menu API Audio Volume Permissions for APIs Beep Gallery Systems info and events Tasks Wednesday, November 2, 11
  • 19. Accelerometer APDU (SmartCard) Orientation Bluetooth Camera Crypto DeviceStatus DLNA Filesystem Server Push Messaging Sensor Geolocation Telephony PIM  Contacts Calendar Tasks DeviceInteraction Wednesday, November 2, 11
  • 21. Telephony Messaging Contacts Clock Camera Filesystem Calculator Device Status Settings Accelerometer Mouse Lock Maps Wednesday, November 2, 11
  • 24. Developer choice is limited by options Wednesday, November 2, 11
  • 25. Native Wrapper WebView Camera WebFont Video Audio Graphics HTTP Location CSS Styling & Layout AJAX Contacts Events SMS JavaScript Sockets Orientation Semantic HTML SSL Gyro File Systems Workers & Cross-App Databases Parallel Messaging App Caches Processing Wednesday, November 2, 11
  • 30. Accelerometer Events Tap into the device’s motion sensor. Hook into native events through JavaScript. Camera File Capture a photo using the device's camera. Hook into native file system through JavaScript. Capture Capture media files using device's media Geolocation capture applications. Make your application location aware. Compass Media Obtain the direction the device is pointing. Record and play back audio files. Connection Notification Quickly check the network state, and Visual, audible, and tactile device cellular network information. notifications. Contacts Storage Work with the devices contact database. Hook into the device’s native storage options. Device Gather device specific information. Wednesday, November 2, 11
  • 40. Accelerometer Events Tap into the device’s motion sensor. Hook into native events through JavaScript. Camera File Capture a photo using the device's camera. Hook into native file system through JavaScript. Capture Capture media files using device's media Geolocation capture applications. Make your application location aware. Compass Media Obtain the direction the device is pointing. Record and play back audio files. Connection Notification Quickly check the network state, and Visual, audible, and tactile device cellular network information. notifications. Contacts Storage Work with the devices contact database. Hook into the device’s native storage options. Device Gather device specific information. Wednesday, November 2, 11
  • 41. Camera navigator.camera.getPicture( function(imageData) { }, function (message) { }, {} //options ); Wednesday, November 2, 11
  • 42. Contacts navigator.contacts.create( {} ).save(); navigator.contacts.find( contactFields, function(){}, function(){}, {} ); Wednesday, November 2, 11
  • 44. AdPlugin/ LocalNotification/ ApplicationPreferences/ Localizable/ AudioEncode/ MapKitPlug/ AudioRecord/ NativeControls/ Badge/ NotificationEx/ BarcodeScanner/ PayPalPlugin/ BundleFileReader/ PowerManagement/ ChildBrowser/ PrintPlugin/ ClipboardPlugin/ DatePicker/ Plugins Prompt/ SMSComposer/ EmailComposer/ ScreenShot/ FileUploader/ ShareKitPlugin/ GapSocket/ SoundPlug/ Globalization/ SplashScreen/ HockeyApp/ TestFlight/ InAppPurchaseManager/ Torch/ Keychain/ VolumeSlider/ Wednesday, November 2, 11
  • 46. Obfuscation != security + = Wednesday, November 2, 11
  • 47. Quirks ... Wednesday, November 2, 11
  • 48. Android iOS phonegap.js phonegap.js ... Wednesday, November 2, 11
  • 49. Avoid start race document.addEventListener( "deviceready", app.mainLaunch, false ); new Ext.Application({ launch: function() { this.launched = true; this.mainLaunch(); }, mainLaunch: function() { if (!device || !this.launched) {return;} ... } }); Wednesday, November 2, 11
  • 50. Wouldn’t it be great if... Wednesday, November 2, 11
  • 51. Further... http://sencha.com/x/cy http://sencha.com/x/de BlackBerry WebWorks APIs 3:50pm - 4:30pm Wednesday, November 2, 11
  • 52. THANKS James Pearce @jamespearce Wednesday, November 2, 11