How to port a PhoneGap-based iPhone app to webOS in 10 minutes [video] 17
by Derek Kessler
Fri, 04 Jun 2010 11:19 am EDT
If you’re a developer that’s a fan of the PhoneGap cross-platform development utility, you might be interested in bringing your app to webOS (especially with impending App Store restrictions). The good folks at PhoneGap want you to know that it’s easy. Like, ten minutes easy. As demonstrated in the video after the break, porting an iPhone PhoneGap app to webOS is a relatively painless process with a few code additions and CSS tweaks to get the Snow Reports app working perfectly on webOS. Check it out after the break.
Source: Steve Gill's Blog; via: Palm Developer Center Blog and PhoneGap



























17 Comments
Awesome !!! I hope some people utilise this tool !!!!
lets hope some good devs are watching.
Maybe this should be posted on developer sites using phone gap, just so they know... And perhaps they should know about the waived Palm Fee for the year as well. That will be enticing...
Hmmmm... Maybe we need to do a new viral video contest for dev's..
This is great news!
I like the idea of another video contest this time for developers
good news ..... But since the HP comments I notice the slowdown on the palm webos sites, hot that bring it up.
That's so cool. I really do hope developers take notice and start porting over some apps quick.
If I'm understanding this correctly, the quick "10-minute" port only works if the iPhone app was originally developed using PhoneGap. If the normal iPhone SDK was used, I don't think the porting process is this simple.
If so, how many apps are we looking at here? I just forwarded the link to this page to Olivetree (several webOS users would like to have Olivetree's Biblereader on their webOS phone) asking them to take a look at it. If they didn't use PhoneGap, this is no help to them?
I'm not sure if there's a way to convert an iPhone app in native Objective-C to PhoneGap. If not, then I don't think there would be an easy way to port an app written in native Objective-C to webOS.
There isn't, not really. This is sort of the tradeoff for developers.
To get all the nifty features that make an app really feel 'at home' and integrated on a given platform, you'll usually have to write in that platform's chosen format. Which is Objective-C on iPhone/iPad, Dalvik Java on Android, or Javascript/CSS on WebOS... all three platforms use different programming languages as their 'first-class development citizen.'
Most cross-platform toolkits will, somewhat of necessity, support the lowest-common denominator of features across all platforms. If you use something like PhoneGap or a similar cross-platform development toolkit, you can rapidly re-target another platform and release a port without having to rewrite things in a new language... but you also generally don't get access to some of those platform-specific features. For instance, it's unlikely that a cross-platform toolkit will allow, say, Android apps to integrate with the Android 2.x contacts API (allowing you to add new quick-command actions to the little contact viewer box, or show a given status message or anything similar), or a WebOS app to integrate with Synergy.
Gameloft and EA seem to makes apps that seem really "at home", yet have ported them in days to the Pre. Now, they obviously didn't use this cross-platform too, but they probably used standard C libraries, and the API's were close enough that the port was trivial.
Yes, some platform-specific features will require rewrites, but many development companies already insulate themselves from this by creating their own API. Also, how many Apple-specific features are there? Until their new OS is released, most of the existing apps just sort of lived in a sandbox, right? No synergy, notifications, etc. I'm sure that will change, as the various platforms mature, but even if it does, it won't impact most applications - most platforms will share all "must-have" features, and most of the other features won't be commonly used in killer applications.
OpenGL ES apps are sort of the exception to the rule; OpenGL ES is a standard in and of itself to which the smartphone platforms are adhering. The vast majority of OpenGL ES apps are not using any native UI code (and in fact on WebOS right now, you /can't/ combine Mojo and PDK), and so are just pure C/C++ and OpenGL ES. That sort of code will port very quickly, but (other than performance concerns), neither will either really stand out as unique to the platform.
But something like, say, Tweep on WebOS or Tweetie -- sorry, 'Twitter for iPhone' -- over on the iPhone? Neither of those is written using C/C++ behind OpenGL. Those both are using native UI without a cross-platform toolkit -- and both show off the strengths of each platform's native toolkits -- and both would likely be almost easier to rewrite from scratch than to actually 'port.' And those are the general-use apps we want brought over.
Sure, getting a port of Need For Speed is great, but I'd rather see (for instance) a decent Skype app, and that's not generally the sort of app that will come over quickly.
Interesting and thanks for the insight and video. Very interesting! Sorli...
SO is snow report coming to webOS?
There is already a snow report app out for webOS called "Snow Report". (I'm the author.) The app currently gives conditions and weather for snow resorts in the US and Canada. If there is something you'd like to see in the app that isn't there please let me know!