[TIMOB-12880] Android: ImageView parity on Android, not rendering the image as expected
| GitHub Issue | n/a |
|---|---|
| Type | Bug |
| Priority | High |
| Status | Closed |
| Resolution | Invalid |
| Resolution Date | 2013-02-27T00:49:17.000+0000 |
| Affected Version/s | Release 3.0.2 |
| Fix Version/s | n/a |
| Components | Android |
| Labels | qe-sdk3.0.2 |
| Reporter | Smitha Guduru |
| Assignee | Ingo Muschenetz |
| Created | 2013-02-26T23:15:55.000+0000 |
| Updated | 2014-06-19T12:43:29.000+0000 |
Description
While testing image rendering from a URL using the following code with imageView properties set to width: Ti.UI.FILL and height: Ti.UI.SIZE, there is a parity on how the image is being rendered on Android.
Please see the attached screenshots for parity on Android vs iOS.
This is not a regression. Also occurs on 3.0.0.GA and 2.1.4.GA.
Steps to reproduce:
1. Create a Titanium app in the Studio
2. Copy the following code in the app.js
3. Build the app using SDK: 3.0.2.GA on an Android device
Ti.UI.backgroundColor = 'white';
var win =Ti.UI.createWindow({
});
var view = Titanium.UI.createScrollView({
layout: 'vertical',
backgroundColor:'white',
scrollType:'vertical'
});
win.add(view);
var numObjects=10;
for (var i = 0; i <numObjects; i++ ) {
var image = Ti.UI.createImageView({
image:'http://static.appcelerator.com/images/header/appc_logo.png',
backgroundColor: 'black',
width: Ti.UI.FILL,
height: Ti.UI.SIZE
});
view.add(image);
}
//eval(name+myString);
Ti.API.info("image"+ i);
Ti.API.info(JSON.stringify(image));
win.open();
Actual result:
The Appcelerator logo is not being scaled correctly.
Expected result:
The Appcelerator logo should be scaled correctly.
Attachments
| File | Date | Size |
|---|---|---|
| AndroidImageView.png | 2013-02-26T23:15:55.000+0000 | 76656 |
| iOSimageView.png | 2013-02-26T23:15:55.000+0000 | 306544 |
Closing this issue as invalid since adding this code in the tiapp.xml is scaling the image as expected.