[AC-931] Android's view.toImage returns a KrollDict instead to TiBlob
| GitHub Issue | n/a |
|---|---|
| Type | Bug |
| Priority | n/a |
| Status | Resolved |
| Resolution | Duplicate |
| Resolution Date | 2015-09-30T01:00:59.000+0000 |
| Affected Version/s | n/a |
| Fix Version/s | n/a |
| Components | Titanium SDK & CLI |
| Labels | android |
| Reporter | grebulon |
| Assignee | Shak Hossain |
| Created | 2015-04-13T12:12:10.000+0000 |
| Updated | 2016-03-08T07:37:14.000+0000 |
Description
The following code that is supposed to write a file containing the view's image fails.
{noformat}
var img = view.toImage();
var file = Ti.Filesystem.getFile(dir, "file.bin");
file.write(img);
{noformat}
That's because TiUIView.toView() returns the KrollDict that TiUIHelper.viewToImage() creates. It should only return the media in the dict.
Comments
- Shak Hossain 2015-09-30