Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Is it possible to build a native GUI within an Android web app?

 
Daniel Trebbien
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For one Android app that I wrote, I chose to write the UI using the native UI subsystem (primarily I used a ListView). Is it possible to instead write Javascript that builds a UI using native widgets? If this is possible, I would imagine that it could only be accomplished with libraries like PhoneGap which expose native functionality to the web app.

I could, of course, emulate the look-and-feel of the native widget system using CSS and HTML, but one nice thing about using the native UI widgets is that the look-and-feel of native Android widgets changes slightly from API level to API level, so any emulation of the native look-and-feel would need to be varied for each API level.
 
Sebastien Blanc
author
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As far as I know I don't think it's possible but I will check with Damon maybe he has more info on this.
 
Damon Oehlman
author
Greenhorn
Posts: 23
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey Daniel,

As per another of your questions, I think a PhoneGap plugin would probably be a way that you could achieve this. I certainly understand your reasons for doing this but I guess I would consider it a lot of effort for potentially limited returns. If native controls are a priority for you and you are comfortable working with Javascript, then possibly something like Appcelerator would be a better choice for you than a "web app" approach.

While Appcelerator do get bundled up into the cross-platform mobile web app technologies, there approach is fundamentally different. Their technology generates a native UI from Javascript application code, with Appcelerator acting as kind of a interpreter between Javascript and the native platform.

While the approach is not one I am a fan of (I think there are potentially long term problems with the sustainability of the approach, given a broad spectrum of devices they may have to support), it definitely meets the requirements of providing application users a UI experience that is consistent with other "purely native" applications that they may be using on their device.

Thanks for the question - I think it's got some good "food for thought" for all of us with the intention of writing mobile web apps.

Cheers,
Damon.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic