• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

degrading

 
Greenhorn
Posts: 11
Eclipse IDE Oracle Tomcat Server
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I was wondering with the range of phones out there that run on android, is there something analogous to degrading such as there is in webapps?
For example, a well designed webapp will still function (albeit with reduced functionality) if the user doesn't allow say, flash or in a more extreme case javascript...

Does android come with a good way of doing this? Or is it a matter of having to manually detect the environment and program around it?
 
author
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Interesting question. In general its like developing for a specific desktop operating system such as windows where you target the specific hardware. In some cases you need to take in account specific vendor modifications to Android but most of the time you can target a set of technical specifications if you want to develop something like a game. For more generic applications, such as a todo list, you can build your application so that it conforms to screen size, orientation, and the like with very little concern about specific platform. In general the simpler your application the less you have to worry about the specific phone. Thus a simple todo list app may work on almost any phone from a HTC Hero running 1.6 to a Nexus S running 2.3. Something like a video game were you count on the API, specific hardware like a Nvida accelerator, certain clock speed of CPU, size and type of display etc your are going to really have to test your app on specific hardware and there will be little you can do for backwards compatibility or graceful degradation.
 
Ranch Hand
Posts: 140
Android Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You will need to think about the android firmware you are trying to run it with. And also if the handset manufacturers will support those
 
Ranch Hand
Posts: 90
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Paul Bartels wrote:I was wondering with the range of phones out there that run on android, is there something analogous to degrading such as there is in webapps?
For example, a well designed webapp will still function (albeit with reduced functionality) if the user doesn't allow say, flash or in a more extreme case javascript...

Does android come with a good way of doing this? Or is it a matter of having to manually detect the environment and program around it?



Part of the functionality of an app that I developed is to display streaming video clips. In order to do this, I used the android.widget.VideoView class.

Using VideoView was frustrating because many of the methods are undocumented, so there was a bit of trial and error involved in getting it to work. One issue that I encountered was that if the video was already started, then to resume playing after pausing I needed to use the resume method on Android 2.2+ (API Level >= 8), but start on Android devices running less than version 2.2. I ended up using the Java Reflection API to dynamically call resume if it is available, or else start.

I guess that that is one way to "detect the environment and program around it", but I am curious if there are better ways.
 
them good ole boys were drinking whiskey and rye singin' this'll be the day that I die. Drink tiny ad.
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic