Skip to content

Instantly share code, notes, and snippets.

@FokkeZB
Created August 22, 2013 09:54
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save FokkeZB/6305325 to your computer and use it in GitHub Desktop.
Save FokkeZB/6305325 to your computer and use it in GitHub Desktop.
How to know if your Android device is LONG or NOTLONG?
http://developer.android.com/guide/topics/resources/providing-resources.html#ScreenAspectQualifier
if ((Ti.Platform.displayCaps.platformWidth / Ti.Platform.displayCaps.platformHeight) < (((Ti.Gesture.orientation === Ti.UI.LANDSCAPE_LEFT)) ? (320 / 240) : (240 / 320)))) {
Ti.API.info('I am LONG');
} else {
Ti.API.info('I am NOTLONG');
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment