Language Version : | ActionScript 3.0 |
Product Version : | Flex 4.5 |
Runtime Versions : | Flash Player 10, AIR 2.5 |
The RuntimeDPIProvider class provides the default mapping of
similar device DPI values into predefined DPI classes.
An Application may have its runtimeDPIProvider property set to a
subclass of RuntimeDPIProvider to override Flex's default mappings.
Overriding Flex's default mappings will cause changes in the Application's
automatic scaling behavior.
Overriding Flex's default mappings is usually only necessary for devices
that incorrectly report their screenDPI and for devices that may scale better
in a different DPI class.
Flex's default mappings are:
160 DPI | <200 DPI |
240 DPI | >=200 DPI and <280 DPI |
320 DPI | >=280 DPI |
Subclasses of RuntimeDPIProvider should only depend on runtime APIs
and should not depend on any classes specific to the Flex framework except
mx.core.DPIClassification
.
runtimeDPI:Number
[read-only]
Language Version : | ActionScript 3.0 |
Product Version : | Flex 4.5 |
Runtime Versions : | Flash Player 10, AIR 2.5 |
Returns the runtime DPI of the current device by mapping its
flash.system.Capabilities.screenDPI
to one of several DPI
values in mx.core.DPIClassification
.
A number of devices can have slightly different DPI values and Flex maps these
into the several DPI classes.
Flex uses this method to calculate the current DPI value when an Application
authored for a specific DPI is adapted to the current one through scaling.
Implementation public function get runtimeDPI():Number
See also
public function RuntimeDPIProvider()
Language Version : | ActionScript 3.0 |
Product Version : | Flex 4.5 |
Runtime Versions : | Flash Player 10, AIR 2.5 |
Constructor.
Mon Feb 18 2013, 01:33 PM +11:00