You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flex.apache.org by "Justin Mclean (JIRA)" <ji...@apache.org> on 2013/09/18 01:50:52 UTC

[jira] [Created] (FLEX-33739) Duplication segment of code calling MultiBitmapSource getSource(dpi)

Justin Mclean created FLEX-33739:
------------------------------------

             Summary: Duplication segment of code calling MultiBitmapSource getSource(dpi)
                 Key: FLEX-33739
                 URL: https://issues.apache.org/jira/browse/FLEX-33739
             Project: Apache Flex
          Issue Type: Improvement
    Affects Versions: Apache Flex 4.10.0
            Reporter: Justin Mclean
            Priority: Minor


MultiBitmapSource getSource(dpi) method is called 3 times in the SDK with exactly the same code:

    var app:Object = FlexGlobals.topLevelApplication;
               var dpi:Number;
               if ("runtimeDPI" in app)
                   dpi = app["runtimeDPI"];
               else
                   dpi = DensityUtil.getRuntimeDPI();
               var multiSource:Object = MultiDPIBitmapSource(source).getSource(dpi);


It would be better to have this code embedded in the MultiBitmapSource getSource() method.

The desiredDPI:Number arg could be made optional, so as not to break existing code.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira