[AC-2485] [android]when creating a blob from an image, width and height are not set
| GitHub Issue | n/a |
|---|---|
| Type | Bug |
| Priority | n/a |
| Status | Closed |
| Resolution | Duplicate |
| Resolution Date | 2012-11-06T21:51:35.000+0000 |
| Affected Version/s | n/a |
| Fix Version/s | n/a |
| Components | Titanium SDK & CLI |
| Labels | android, imageview |
| Reporter | Martin Guillon |
| Assignee | Davide Cassenti |
| Created | 2012-08-25T11:17:17.000+0000 |
| Updated | 2016-03-08T07:41:32.000+0000 |
Description
test case says it all
var win = Ti.UI.createWindow({
backgroundColor: 'white'
});
var fileName = "http://3.bp.blogspot.com/_Z-tqVTd9fPI/TRzjXBKIKvI/AAAAAAAACEo/wflE9APHFWE/s200/steve_jobs.jpg";
var xhr = Titanium.Network.createHTTPClient();
image = Ti.UI.createImageView({
width:400,
backgroundColor:'blue',
// image:fileName,
height:200
});
win.add(image);
xhr.onload = function() {
var imgBlob = this.responseData;
Ti.API.info("image size " + imgBlob.width + "," + imgBlob.height);
};
xhr.open('GET', fileName);
win.open();
xhr.send();
Comments
- Federico Casali 2012-11-06