PDA

View Full Version : sencha touch and phonegap



Shranes
27 Jul 2011, 2:05 AM
i have an existing sencha touch app, developed in VS 2010. now i wanna integrate phonegap with it.

is it possible??

Hanni Sullivan
27 Jul 2011, 2:40 AM
Certainly. I also started out with a pure Sencha Touch app and added PhoneGap later on. It really is no big deal.

Shranes
27 Jul 2011, 4:26 AM
great Ms.Sullivan..

can u tell me how u managed to do that? how did u add the necessary phonegap files and how did u test it?

Hanni Sullivan
27 Jul 2011, 4:45 AM
There really is nothing to it: I downloaded the PhoneGap framework and followed their instructions on how to create the required Android and iOS projects. I then added my files which make up my Sencha Touch app to the folders specified in their documentation. And of course I had to add the phonegap.js file to my index.html head section.

I use Eclipse (under windows) for the Android version and XCode (on a Mac, of couse) for the iOs one.

Debugging a PhoneGap app is no fun since you are stuck with console.log as (more or less) you're only way of debugging. Exceptions will silently fail. People have tried different approaches to lessen the pain of debugging. Check out weinre (http://phonegap.github.com/weinre/) i.e.

In general I can not recommend testing your app on the real thing enough. I use an iPhone 4 and an iPod Touch 3rd Gen. for the iOS version and a Google Nexus S and HTC Desire HD for the android one and I have had plenty of fun with weird behavior I could only experience on the phones or even on a specific platform.

Shranes
27 Jul 2011, 7:32 AM
so i need eclipse and xcode? i cant make do with just VS inside a javascript framework?

Hanni Sullivan
27 Jul 2011, 11:07 PM
Check out the Getting started (http://www.phonegap.com/start) guide of the PhoneGap framework. For the android version you can use either the terminal or Eclipse. But for iOS you definitely need a Mac, XCode and a iOS developer certification on top of that.

Visual Studio unfortunately isn't of much use in these scenarios.

fx-mike
28 Jul 2011, 1:21 AM
Check out phonegap build:
https://build.phonegap.com/

Phonegap will build your app and let you download the binaries for any of their supported platforms.
Sounds very promising to me. No more crappy SDKs, yay :D

You still need a dev certificate for iOS, of course...

Hanni Sullivan
28 Jul 2011, 2:38 AM
Good point. I completely forgot about their new cloud service.

Shranes
28 Jul 2011, 2:54 AM
sounds good...

i'm completely new to phonegap..tell me how do u write,run and test phonegap code without any ide like eclipse and associated SDKs... :-/

mbalsam
3 Aug 2011, 11:40 PM
sounds good...

i'm completely new to phonegap..tell me how do u write,run and test phonegap code without any ide like eclipse and associated SDKs... :-/

you could probably develop and test on android devices without eclipse only using your editor of choice and the tools that come with the android sdk. the sdk is mandatory though. for iPhone there's no alternative to using a mac with the xcode ide thanks to apple's policy of controlling every step in development.