As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I've read about phonegap which enables users to write web-based apps for android and i was wondering:
how is the performance of phonegap compared to a "real" android app
what would NOT work in phonegap?
i know it's possible to implement google maps with phonegap but i guess there's a lots of limitation compared to direct coding the maps under android?
as a newbie to android (but intermediate in web-programming), should I go for direct android coding instead of phonegap?
i'm planning to write an app which uses google maps service+gps, database access and such, and i'm afraid it's not really possible with phonegap.
thx
I am building an application with Google maps, GPS and uses a back-end Service/Database. I have chosen to use
Phonegap - To 'wrap' my HTML and I also use the Geo-Location library.
Javascript - JQuery - JQuery Mobile - Most of the UI
HTML5 - Heavily custom UI where I needed to do graphics and gesturing
etc, needed to hand-code
Node.JS - my back-end service.
JSONP - Communicating between my Mobile app and the service
CouchDB - In the cloud, NoSQL Javascript friendly Database, very
cool.
Having almost finished, I can say that this type of app certainly is do-able with this stack of technologies and the whole cross/platform aspect of it is fantastic. However it has not been particularly easy. In particular, you need to watch out for ...
Phonegap uses file:// based URLs so all kinds of problems with browser 'security' and cross site scripting messing up your Ajax and cookie code. I got around this by using JSONP but it did stop me from using some cool stuff that would otherwise have been possible like SocketIO.
debugging your JavaScript within the browser, within the Phonegap container, within the emulator... is virtually impossible. I got around this by doing most of my debugging on Firefox with Firebug and then using alert('blah') for any issues that popped up only when deployed.
Google Maps hosted inside HTML will only work while connected to the internet, this meant that debugging while mobile (i do a lot of coding while commuting) was a pain. I needed to find reliable mobile internet, no biggie, its cool anyway but, it was something extra.
Google maps InfoView windows suck suck suck. I eventually gave up and pop any necessary dialogs from the map as JQuery Mobile pages.
Hope this helps somebody ;)
The performance of PhoneGap apps is good, but it largely depends on exactly what you are doing (for example animations probably perform better native).
If you are only building it on one platform it might be best to go native since there is going to be a learning curve with both PhoneGap and native Android development. It may also be easier to go native since you are using maps a lot.
I would avoid Phonegap at all costs. I've been working on a project with Phonegap, and we had lots of problems with it. In the end, we turned to coding in native languages (java/objective c/java me).
Maybe something changed in the meanwhile, but at that time (Q2 of 2010) Phonegap was really OK only for iPhone. Android API didn't have half the features documented on their site, and even those features were stuffed with bugs. For instance, their Contacts API had a huge blocker - used some non-existing javascript object. It seemed as if they just copy/pasted the code from iPhone API and didn't even care to check if it worked. I was really disappointed with Phonegap - we couldn't use database, we couldn't get contacts, documentation was false....
One more thing I hated about doing an HTML app for Android was the lack of libraries with native looking Android GUI. Almost all the JS GUI libraries were focused on iPhone, and replicating the iPhone GUI. A few of those that advertized to have support for Android had such a bad components design that they were useless.
Again, these are my experiences from 6 months ago. I hope some things changed in the meanwhile, but I'm sure I won't be using HTML for mobile apps/android any time soon.
The good thing about phonegap is that it enables you to build cross-platform mobile apps.
If you are doing just android, I guess it doesn't make sense.
Related
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 9 years ago.
I am a .NET developer (more than 6 years now) and just starting to learn about mobile/smartphone/tablets development. Logically, I (and probably everybody else out there) would like the application we create to run on all smartphone platforms. It just feels natural from the normal user (layman) perspective that if it's a "mobile app" it should run on mobile device. It shouldn't matter if I own iPhone or Android, mobile app is a mobile app. Note: I am talking about native platform development, not HTML/web apps that can be used from browsers.
So this is just a high-level overview question... what are the current strategies (in year 2013) to deal with this issue? The way I imagine mobile cross platform development works is there's probably a single common code base that implements app's business logic and then for each targeting platform we need to develop GUI part separately. How far is this from truth in practice?
Take for example the popular game "Angry Birds". I played it on iPhone, Android and even from Chrome browser on Windows Desktop (probably as Flash or HTML5 game) and each version had pretty much identical feeling when played. How did they do that? I imagine they have game engine as common code but in what language could it be written? As far as I know there is no common programming language that given the single source code files it can be compiled into native binaries for ios/android/win8 phone.
Unfortunately, there is no way to develop a cross-platform app which has really native look and feel and shares same code for all platforms.
Its possible to share some code on some platforms though (for example, you can use C/C++ for iOS and Android), but only for the logic part of your app. To get native UI you will be forced to use native APIs. If your app doesn't involve some complicated data processing then this approach may have more downsides than really helping you out.
You can get rather good platform independence with hybrid app platforms such as PhoneGap or Titanium, but that involves HTML/Javascript development which could lead to a lot of time and efforts required to bring user experience to be somewhat similar to that of a native app.
Since you are a .NET Dev one logical solution for you would be to use Xamarin's offerings. (http://xamarin.com/) They allow you to develop your back-end logic once and then compile it into all three major mobile platforms (iPhone/Android/WP). You can then use this back-end logic project to write the UI layer for each specific platform.
Another option that devs have is to use the javascript/html route similar to PhoneGap. While I haven't looked at this recently there used to be some performance hits and hardware usability gaps when going the JS/HTML route. This may have been improved now.
EDIT:
Since you specifically mentioned games like Angry Birds. The Unity platform offers very good support for development that is compatible with most devices if you need 3D.
For Angry Birds specifically...they use Box2D for the Physics and I'm not 100%, but it looks like Cocos2d to draw the elements.
If you are looking to build games and like the idea of Xamarin then take a look at MonoGame which basically looks like an XNA port to the Mono Framework.
in addition of Jared's answer, this afternoon I tested Xamarin.
You are a .Net Developer and if you are already using Visual Studio, you are so lucky. Because Xamarin has an extension for Visual Studio
I just want to give a bad impression about xamarin, you can test good ones by the time, user interface is created in a xml based file and there is no auto complete, so you have to write whole code or use properties window. But I think it will be better by the time. nice coding
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
As we are still in the design stage we have no code in place yet for our mobile app. I then stumbled on the PhoneGap tool which has left us thinking. We are both from a Java background so that is why developing using ADT/Java looked like the only option. Is the knowledge ramp up for PhoneGap steep or do you think it would be worth going with it from the start seeing as we have no existing code done yet.
We had intended to use GAE/Big table for our back end persistence. Is this still possible if you use PhoneGap for the front end?
Also, can I assume it's possible to use Selenium to automate functional tests with phoneGap?
Our UI will just consist of Buttons, a sprinkling of static images and Text. Am I correct in saying the the performance drawbacks of PhoneGap should probably not be an issue in this case?
I did develop both for both platform but they are completely apps and below notes are based on my experiences, I am writing for PhoneGap (I think) and you can assume android is the opposite side.
Cross platform, right now it is supporting all major phones (Android, IOS, WP) I am not sure it is case for you as you only tagged for Android.
HTML5, JS, CSS these are my area as you are Java based developers so it is up to you.
Not native so will be slower than native.
Cross browser compatibility. I think this does not need explanation especially for desktop browsers it a pain the mobiles are more easier but it is still a problem.
To answer your questions,
Yes you can use GAE/Big table for backend, with AJAX as PhoneGap uses file:// protocol it is supporting cross URL request.
I personally don t use PhoneGap, if the app is a game and have lots of animation going on. But in your case it is a application for listing data and responsive web might make your life easier than native app to support all screen size.
I have no idea about Selenium testing so I keep my silence for that.
And shorter answer to your for me YES you can use and should.
Hope this helps.
Lets get going to answer your bunch of questions ?
Would I prefer you to use PhoneGap ?
Definitely Yes, The learning curve is not steep too , All you have to know is basic HTML,CSS and Javascript. Since you have also mentioned the app is simple,It would be good to use PhoneGap. Everybody know that PhoneGap sucks at Performance but since your app seems simple it wont be a problem.
Why did I recommend ?
Write once, deploy across lot of mobile platforms (If you want to support more devices)
Can Selenium Tests be run ?
Yes, You can,its just a web app. :)
Go for it, Give it a try.
If you want to support only Android or iOS or WP7 then I would prefer native development over PhoneGap because Performance matters.
In your case, you can choose between those two. There will be no serious drawbacks.
In many cases, particularly business applications which are connected to web services, choosing between Phonegap and native app is a matter of personal choice. I've met some people who prefer Phonegap and other people who avoid Phonegap, Appcelerator, or other wrapper frameworks and prefer native code.
Phonegap is easy to learn and if you need some functinalities beyond that provided by Phonegap, you can create a plugin for your app. That said, you still need to write native code for the plugin if you need to implement functionalities not provided by Phonegap.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
Our company will soon start developing few products for mobile platforms, as CTO I was asked to examine the Pro and Cons of the different tools available in order to achieve the best quality / cost effective solution.
We will be aiming primarily at iOS and Android , secondary for Windows-Mobile and BlackBerry.
Candidates:
After conducting some background research, I found the following possible candidates:
Native - Simply but laboriously develop for each platform with its native tools and language.
HTML5, CSS and JavaScript - Could be a web service running on the device's browser (a website) , or an app which incapsulate such code around WebKit.
Rho mobile - Made by Google so it ought to be good - nevertheless based on Ruby (which we are not comfortable with) and does have a complex and rather flimsy dev environment.
PhoneGap - It seems easy and mostly based on Javascript - It is open source but lately acquired by adobe - (not a good sign)
Appcelerator - Anything from Javascript to PHP and to python, have a nice range of API Access but we heard many stories of rejection (by apple), and incompatibilities when using complex code across different platforms.
And more like MoSync, Sencha, Appmobi and Corona (didn't tested them first hand).
Some points of reference:
We are not planning on developing games, the applications we are planning to develop are in the realm of business applications & information tools.
The applications are not depending on excessive use of the devices API's (but do need some minor basic access)
The company already developed for iOS and we have a small team of native iOS developers (Objective-C geeks)
We would like to be sure that we can carry on developing our applications in the feature without them getting broken due to new OS or APIs
It will be beneficial to ensure before hand that the application will not be rejected due to cross platform code (mostly AppStore)
Like any company we would like to be as cost effective as we can - on the other hand we insist on high quality products and top-of-the-line User experience.
There is no better place to ask this question than StackOverflow, I would appreciate any comments from developers with experience on this topic.
There are 500k+ apps on the app markets and competition is fierce. It is paramount to have great UX and graphics.
Cross-platform tools are NOT on par with native development. If they were, we would all be using them. But we are not. With a reason - you do NOT have full control. And full-control is necessary to have great looking apps.
If your app is not a consumer app, but an enterprise app, which use is dictated by some internal department, then you might get by with so-so design, because the value of such app is in it's functionality.
But, if you are serious about mobile apps market - then the only way is to go native. And you need an UX guy and a designer (who knows mobile development) on team full time. You will spend upwards of 50% of time on looks. The project that I'm part of now is spending 80%+ of time on looks (graphics, animations, UX, usability testing).
A suggestion: spend a reasonable amount of time (= days) using you competitors apps. Also spend time with top 50 apps on each market. You will get a feeling how high the bar is. Then check apps made with cross-platform tools (you can find links on their sites) and compare.
While I'm in complete agreement with #Peter Knego, I'd add a few minor points for teams looking to support several platforms:
As Peter notes, UX is huge, and cross-platform UX is least-common-denominator UX. It's hard enough to get this stuff to be everything it needs to be without tying a hand behind your back. Really fantastic web apps are judged on their ability to come close to a native experience, not the other way around.
There are many parts of a product that aren't UX. It's worth considering carefully what kind of reuse you can get there. For instance, I've often advised teams who have SQL databases already working on Android not to try to use Core Data on iPhone. There's no reason to reinvent your object and data models.
This is not a blanket suggestion that you write your core in C++. If you have an extensive, existing C++ core, I've made suggestions before about how to reuse it. But I don't generally recommend it for new code. It's better to use the best OS-level features of the platform in most cases.
Designing network protocols that work well on all platforms is pretty easy and should be pursued. Your best bet here in almost every case is REST and JSON. Keep it simple, especially for iPhone which hates things like SOAP and parsing complex XML.
Some complicated layout problems are easier in HTML+CSS than with native controls. This is particularly true if you have complex multi-column tables (especially things you'd need colspan and rowspan for). I've had fairly good luck embedding individual UIWebView pieces in otherwise native apps, even when portability is not a consideration at all. There can be some worthwhile reuse here. Just remember that you don't want to waste a lot of effort and performance trying to make your HTML browser-neutral. On iPhone, use WebKit extensions anywhere they make your app better for the user.
One of the most important lessons in this, though, is that there isn't a single "right" way to make an app that is appropriate for all platforms. iPhone apps should act like iPhone apps. Android apps should act like Android apps.
Highly cross-platform approaches are a cheap way to get "something" if you don't really care what "something" is. They're a very expensive way to get something great.
I work at AppMobi and I'll just make a few comments.
You're app shouldn't be rejected for being cross platform using a native webview. We haven't had Apple use that on any AppMobi submitted apps.
Rhombile isn't "Made by google". In fact, it's not even the part of Motorola that Google bought, it's their business division. They are pushing towards HTML5/Javascript but currently Ruby.
Appcelerator started out supporting a webview, then backtracked. They just raised a ton of money to go back to the webview suppport.
As to people saying "No" to the cross platform apps. Facebook and some other major companies are moving towards HTML5 based apps for mobile.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
Our company will soon start developing few products for mobile platforms, as CTO I was asked to examine the Pro and Cons of the different tools available in order to achieve the best quality / cost effective solution.
We will be aiming primarily at iOS and Android , secondary for Windows-Mobile and BlackBerry.
Candidates:
After conducting some background research, I found the following possible candidates:
Native - Simply but laboriously develop for each platform with its native tools and language.
HTML5, CSS and JavaScript - Could be a web service running on the device's browser (a website) , or an app which incapsulate such code around WebKit.
Rho mobile - Made by Google so it ought to be good - nevertheless based on Ruby (which we are not comfortable with) and does have a complex and rather flimsy dev environment.
PhoneGap - It seems easy and mostly based on Javascript - It is open source but lately acquired by adobe - (not a good sign)
Appcelerator - Anything from Javascript to PHP and to python, have a nice range of API Access but we heard many stories of rejection (by apple), and incompatibilities when using complex code across different platforms.
And more like MoSync, Sencha, Appmobi and Corona (didn't tested them first hand).
Some points of reference:
We are not planning on developing games, the applications we are planning to develop are in the realm of business applications & information tools.
The applications are not depending on excessive use of the devices API's (but do need some minor basic access)
The company already developed for iOS and we have a small team of native iOS developers (Objective-C geeks)
We would like to be sure that we can carry on developing our applications in the feature without them getting broken due to new OS or APIs
It will be beneficial to ensure before hand that the application will not be rejected due to cross platform code (mostly AppStore)
Like any company we would like to be as cost effective as we can - on the other hand we insist on high quality products and top-of-the-line User experience.
There is no better place to ask this question than StackOverflow, I would appreciate any comments from developers with experience on this topic.
There are 500k+ apps on the app markets and competition is fierce. It is paramount to have great UX and graphics.
Cross-platform tools are NOT on par with native development. If they were, we would all be using them. But we are not. With a reason - you do NOT have full control. And full-control is necessary to have great looking apps.
If your app is not a consumer app, but an enterprise app, which use is dictated by some internal department, then you might get by with so-so design, because the value of such app is in it's functionality.
But, if you are serious about mobile apps market - then the only way is to go native. And you need an UX guy and a designer (who knows mobile development) on team full time. You will spend upwards of 50% of time on looks. The project that I'm part of now is spending 80%+ of time on looks (graphics, animations, UX, usability testing).
A suggestion: spend a reasonable amount of time (= days) using you competitors apps. Also spend time with top 50 apps on each market. You will get a feeling how high the bar is. Then check apps made with cross-platform tools (you can find links on their sites) and compare.
While I'm in complete agreement with #Peter Knego, I'd add a few minor points for teams looking to support several platforms:
As Peter notes, UX is huge, and cross-platform UX is least-common-denominator UX. It's hard enough to get this stuff to be everything it needs to be without tying a hand behind your back. Really fantastic web apps are judged on their ability to come close to a native experience, not the other way around.
There are many parts of a product that aren't UX. It's worth considering carefully what kind of reuse you can get there. For instance, I've often advised teams who have SQL databases already working on Android not to try to use Core Data on iPhone. There's no reason to reinvent your object and data models.
This is not a blanket suggestion that you write your core in C++. If you have an extensive, existing C++ core, I've made suggestions before about how to reuse it. But I don't generally recommend it for new code. It's better to use the best OS-level features of the platform in most cases.
Designing network protocols that work well on all platforms is pretty easy and should be pursued. Your best bet here in almost every case is REST and JSON. Keep it simple, especially for iPhone which hates things like SOAP and parsing complex XML.
Some complicated layout problems are easier in HTML+CSS than with native controls. This is particularly true if you have complex multi-column tables (especially things you'd need colspan and rowspan for). I've had fairly good luck embedding individual UIWebView pieces in otherwise native apps, even when portability is not a consideration at all. There can be some worthwhile reuse here. Just remember that you don't want to waste a lot of effort and performance trying to make your HTML browser-neutral. On iPhone, use WebKit extensions anywhere they make your app better for the user.
One of the most important lessons in this, though, is that there isn't a single "right" way to make an app that is appropriate for all platforms. iPhone apps should act like iPhone apps. Android apps should act like Android apps.
Highly cross-platform approaches are a cheap way to get "something" if you don't really care what "something" is. They're a very expensive way to get something great.
I work at AppMobi and I'll just make a few comments.
You're app shouldn't be rejected for being cross platform using a native webview. We haven't had Apple use that on any AppMobi submitted apps.
Rhombile isn't "Made by google". In fact, it's not even the part of Motorola that Google bought, it's their business division. They are pushing towards HTML5/Javascript but currently Ruby.
Appcelerator started out supporting a webview, then backtracked. They just raised a ton of money to go back to the webview suppport.
As to people saying "No" to the cross platform apps. Facebook and some other major companies are moving towards HTML5 based apps for mobile.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 9 years ago.
I have started to build my own apps on iPhone and iPad using the iPhone SDK. The next question that is always asked by the client is, "Can we have it on Android?"
So my question to you, 'the internet', is: what are my options?
I don't have the time to learn another language (learning iOS has been enough!), so are there companies who specialize in this, or are there any online services that do a conversion?
Any help on this welcome, just need to know which way to turn...
No, there is no way to convert an existing iOS app to an Android app.
However, there are cross-platform frameworks that allow you to code once and deploy your app in more than one platform. The most popular are based on HTML/CSS/JavaScript and one of them is PhoneGap.
You can also develop for iOS and Android with Adobe technologies such as Adobe AIR (this was forbidden by Apple until recently).
And there are online services (such as Mobile Roadie) that allow you to generate cross-platform apps using a content management system.
That said, I strongly recommend to:
Learn Android and Java development if you want to specialize in mobile development.
Take advantage of the strengths of each platform when working on an iOS/Android project, instead of creating something that uses only what's common to both.
Converting a native application from one mobile platform to the other is not a straight-forward process unless the initial application was built with a framework with cross-platform capabilities from the start.
Your options at this point are learn the other platform and develop it yourself, or contract with another development company which specializes in the platform you need to target.
Due to the massive differences between the 2 platforms, you are looking at a complete rewrite of your application. You either do it yourself or pay someone else to do it. I don't see any shortcuts you can take.
You may be interested in reading my book, HTML5 for iOS and Android, which enables you to take web apps created in HTML, JavaScript & CSS, and turn them into standalone apps that you can upload to the app stores (for free or to sell). See http://html5formobile.com - the wrappers to do this for the iOS and Android SDKs are freely available on the website, and you don't need any knowledge of either programming language if you follow the instructions in the book.
You can try the following https://bitbucket.org/zabirauf/icona.
Its open source iOS to Android Application Conversion Tool.
Even if there was a way to easily port an Objective-C application to Java, I wouldn't highly encourage it. iPhone users and Android users are two different families of users. The typical iPhone interface just wouldn't sit well with Android users who aren't familiar with how the iPhone works. Yes, I understand that the UIs of both iPhone and Android seem pretty trivial to learn to most people, but when you break a novice's comfort zone, it puts your applications (or websites) on a higher learning curve.
You should take the time to learn Android's language and UI and develop your application in a fashion that is consistent with how applications on Android work. As said in other answers, if your taught yourself Objective-C, you should find that Java will come pretty easily to you. In addition, in never hurts to know more than one programming language.
You can't just convert iOS apps into Android. iOS is Objective-C and Android is Java.
I highly doubt there are 'converters' on the internet, even if there are that's not the way you should program an app because every SDK has his own special capabilities and you should use them for maximum user-experience.
I'm sure there are some companies who specialize in porting apps from iOS to Android. Look it up on Google I'd say..
If you want an easy place to look for android development you can try appMaker which I hear is a GUI based Android development tool or I believe Google has released its own GUI based android application development tool. If you are not a java programmer than you might be better off with the gui. Otherwise I would say android is not too different from traditional java. As a java programmer who went from Android to iOS, I will tell you Android is a walk in the park compared to learning iOS. Two completely different beasts in my opinion.
Selecting a mobile development environment which will enable you write once and deploy/distribute it on many devices would be a better solution in the future. If your application is HTML-based, go with HTML5/CSS alternative (ex: PhoneGap, ). If you prefer native, then chances are you may want to learn Lua, a scripting language (ex: Gideros Studio) or C++ (ex: Mosync).
Other than that, the application you created on iOS with Objective-C is very, very hard to port to Android and other devices.