[TIMOB-1790] iPhone OS4: image from openPhotoGallery cannot be added to an imageView
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Trivial |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2011-04-17T01:57:10.000+0000 |
Affected Version/s | n/a |
Fix Version/s | n/a |
Components | iOS |
Labels | gallery, imageview, ios, photo |
Reporter | Shiki |
Assignee | Reggie Seagraves |
Created | 2011-04-15T03:02:29.000+0000 |
Updated | 2011-04-17T01:57:10.000+0000 |
Description
This works:
Ti.Media.openPhotoGallery({
allowEditing: true,
mediaTypes: [Ti.Media.MEDIA_TYPE_PHOTO],
success: function(e) {
if (e.mediaType == Ti.Media.MEDIA_TYPE_PHOTO) {
var imageView = Ti.UI.createImageView({image: e.media});
Ti.UI.currentWindow.add(imageView);
}
});
But if set allowEditing
to false, I get this
error:
[ERROR] invalid image type. expected either TiBlob or TiFile, was: TiBlob in -[TiUIImageView setImage_:] (TiUIImageView.m:618)
Tested 1.6.0GM. Test in bugtests.