Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-26657

Developers are able to override the DPI bucket, but not the exact device DPI

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Reopened
    • Minor
    • Resolution: Unresolved
    • Adobe Flex SDK Previous
    • None
    • Mobile: Density
    • None
    • Affected OS(s): All OS Platforms
      Affected OS(s): All OS Platforms
      Language Found: English

    Description

      One of the main reasons behind the "Override Default Density Mapping" feature (http://opensource.adobe.com/wiki/display/flexsdk/Override+Default+Density+Mapping) was to allow developers to customize the DPI bucket choice for devices that incorrectly report their DPI.

      However there are places in the SDK code that depend on the exact device DPI and not the bucketed DPI. For example touch scrolling has a "slop" threshold between selection and scrolling that is equal to 0.079365 inches (20 pixels on a Nexus One). This value is currently multiplied by Capabilities.screenDPI of the device to get the number of pixels on that device. If the device is reporting the wrong DPI then this slop will be incorrect.

      Skinning, scaling, and multi-resolution bitmaps acts upon the bucketed DPI values, but things related to physical touch don't care about the bucketed DPI but instead should act on the exact DPI of the device.

      RunTimeDPIProvider should provide a getter like runtimeDPI except called something like "exactRuntimeDPI" that is overridable in the same fashion. By default that method would return Capabilities.screenDPI and developers can override it if they need to when they override the bucket behavior. The SDK should always use this value rather than Capabilities.screenDPI and developers building on top of the SDK will probably want to do the same.

      Attachments

        Activity

          People

            Unassigned Unassigned
            adobejira Adobe JIRA
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: