Add ability to control how Ti.UI.ImageView scales its image. In particular, developers want the ability to crop the image.
Add a new "scalingMode" property to Ti.UI.ImageView supporting the following constants...
- Ti.Media.IMAGE_SCALING_AUTO // Legacy behavior.
- Ti.Media.IMAGE_SCALING_NONE // No scaling. Show image as-is.
- Ti.Media.IMAGE_SCALING_FILL // Stretches image disproportionally.
- Ti.Media.IMAGE_SCALING_ASCPECT_FILL // Crops proportionally.
- Ti.Media.IMAGE_SCALING_ASCPECT_FIT // Letterbox/Pillarbox proportionally.
The above property name and scaling constants match the names used by our Ti.Media.VideoPlayer for consistency.
In the future, we could add properties "horizontalAlignment" and "verticalAlignment" to control where the image should be aligned to within the image view container. For now, we should only support center alignment since that would satisfy most developers.