| Package | feathers.system |
| Class | public class DeviceCapabilities |
| Inheritance | DeviceCapabilities Object |
| Product Version : | Feathers 1.0.0 |
| Property | Defined By | ||
|---|---|---|---|
| dpi : int [static]
The screen density to be used by Feathers. | DeviceCapabilities | ||
| largePhoneScreenLandscapeWidthMinimumInches : Number = 4.5 [static]
The minimum physical size, in inches, of the device's larger side to
be considered a large phone (sometimes called a phablet). | DeviceCapabilities | ||
| largePhoneScreenPortraitWidthMinimumInches : Number = 2.5 [static]
The minimum physical width, in inches, of the device when in
portrait orientation to be considered a large phone (sometimes
called a phablet). | DeviceCapabilities | ||
| screenPixelHeight : Number = NaN [static]
A custom height, in pixels, to use for calculations of the device's
physical screen size. | DeviceCapabilities | ||
| screenPixelWidth : Number = NaN [static]
A custom width, in pixels, to use for calculations of the device's
physical screen size. | DeviceCapabilities | ||
| simulateDPad : Boolean = false [static]
Indicates if the arrow and enter keys on a standard keyboard are
treated the same as a d-pad. | DeviceCapabilities | ||
| tabletScreenLandscapeWidthMinimumInches : Number = 5 [static]
The minimum physical size, in inches, of the device's larger side to
be considered a tablet. | DeviceCapabilities | ||
| tabletScreenPortraitWidthMinimumInches : Number = 3.5 [static]
The minimum physical width, in inches, of the device when in
portrait orientation to be considered a tablet. | DeviceCapabilities | ||
| Method | Defined By | ||
|---|---|---|---|
isLargePhone(stage:Stage = null):Boolean [static]
Determines if this device is probably a large phone (sometimes
called a phablet), based on the physical width and height, in
inches, calculated using the full-screen dimensions and the screen
density. | DeviceCapabilities | ||
isPhone(stage:Stage = null):Boolean [static]
Determines if this device is probably a phone, based on the physical
width and height, in inches, calculated using the full-screen
dimensions and the screen density. | DeviceCapabilities | ||
isTablet(stage:Stage = null):Boolean [static]
Determines if this device is probably a tablet, based on the physical
width and height, in inches, calculated using the full-screen
dimensions and the screen density. | DeviceCapabilities | ||
screenInchesX(stage:Stage = null):Number [static]
The physical width of the device, in inches. | DeviceCapabilities | ||
screenInchesY(stage:Stage = null):Number [static]
The physical height of the device, in inches. | DeviceCapabilities | ||
| dpi | property |
public static var dpi:int
The screen density to be used by Feathers. Defaults to the value of
flash.system.Capabilities.screenDPI, but may be
overridden. For example, if one wishes to demo a mobile app in a
desktop browser, a custom screen density will override the real
density of the desktop screen.
Warning: You should avoid changing this value on
a mobile device because it may result in unexpected side effects. In
addition to being used to scale components in the example themes, the
screen density is used by components such as Scroller
(and its subclasses like List and
ScrollContainer) to optimize the scrolling behavior.
Reporting a different screen density may cause some components to
appear poorly responsive (or overly sensitive) to touches.
The default value is flash.system.Capabilities.screenDPI.
See also
| largePhoneScreenLandscapeWidthMinimumInches | property |
public static var largePhoneScreenLandscapeWidthMinimumInches:Number = 4.5The minimum physical size, in inches, of the device's larger side to be considered a large phone (sometimes called a phablet).
When calling isLargePhone(), a device must meet the
requirements of both the minimum portrait width and the minimum
landscape width.
The default value is 4.5.
See also
| largePhoneScreenPortraitWidthMinimumInches | property |
public static var largePhoneScreenPortraitWidthMinimumInches:Number = 2.5The minimum physical width, in inches, of the device when in portrait orientation to be considered a large phone (sometimes called a phablet).
When calling isLargePhone(), a device must meet the
requirements of both the minimum portrait width and the minimum
landscape width.
The default value is 2.5.
See also
| screenPixelHeight | property |
public static var screenPixelHeight:Number = NaNA custom height, in pixels, to use for calculations of the device's physical screen size. Set to NaN to use the actual height.
The default value is flash.display.Stage.fullScreenHeight.
See also
| screenPixelWidth | property |
public static var screenPixelWidth:Number = NaNA custom width, in pixels, to use for calculations of the device's physical screen size. Set to NaN to use the actual width.
The default value is flash.display.Stage.fullScreenWidth.
See also
| simulateDPad | property |
public static var simulateDPad:Boolean = false| Product Version : | Feathers 3.4.0 |
Indicates if the arrow and enter keys on a standard keyboard are
treated the same as a d-pad. If true, focus and other
behaviors may be controlled with a standard keyboard.
In the following example, the D-Pad is simulated:
DeviceCapabilities.simulateDPad = true; The default value is false.
| tabletScreenLandscapeWidthMinimumInches | property |
public static var tabletScreenLandscapeWidthMinimumInches:Number = 5The minimum physical size, in inches, of the device's larger side to be considered a tablet.
When calling isTablet(), a device must meet the
requirements of both the minimum portrait width and the minimum
landscape width.
The default value is 5.
See also
| tabletScreenPortraitWidthMinimumInches | property |
public static var tabletScreenPortraitWidthMinimumInches:Number = 3.5The minimum physical width, in inches, of the device when in portrait orientation to be considered a tablet.
When calling isTablet(), a device must meet the
requirements of both the minimum portrait width and the minimum
landscape width.
The default value is 3.5.
See also
| isLargePhone | () | method |
public static function isLargePhone(stage:Stage = null):BooleanDetermines if this device is probably a large phone (sometimes called a phablet), based on the physical width and height, in inches, calculated using the full-screen dimensions and the screen density.
Parameters
stage:Stage (default = null) |
Boolean |
See also
| isPhone | () | method |
public static function isPhone(stage:Stage = null):BooleanDetermines if this device is probably a phone, based on the physical width and height, in inches, calculated using the full-screen dimensions and the screen density.
Returns true if the device is smaller than the
minimum dimensions of a tablet. Larger phones (sometimes called
phablets) are classified as phones when calling
isPhone(). If isPhone() returns
true, use isLargePhone() to determine the
size of the phone, if necessary.
Parameters
stage:Stage (default = null) |
Boolean |
See also
| isTablet | () | method |
public static function isTablet(stage:Stage = null):BooleanDetermines if this device is probably a tablet, based on the physical width and height, in inches, calculated using the full-screen dimensions and the screen density.
Parameters
stage:Stage (default = null) |
Boolean |
See also
| screenInchesX | () | method |
public static function screenInchesX(stage:Stage = null):NumberThe physical width of the device, in inches. Calculated using the full-screen width and the screen density.
Parameters
stage:Stage (default = null) |
Number |
See also
| screenInchesY | () | method |
public static function screenInchesY(stage:Stage = null):NumberThe physical height of the device, in inches. Calculated using the full-screen height and the screen density.
Parameters
stage:Stage (default = null) |
Number |
See also