Quantcast
Channel: Appcelerator Developer Center Q&A Unanswered Questions 20
Viewing all articles
Browse latest Browse all 8068

Annotation Image android

$
0
0

I have this code for the Annotation:

var thisView = Ti.UI.createView({
        width : 30,
        height : 30
    });
 
    var thisImage = Ti.UI.createImageView({
        width : 30,
        height : 30,
        image: '/icons/app-pin-avl.png'
    });
 
    var ant = gl_map.createAnnotation({
        latitude : latitude,
        longitude : longitude,
    });
 
    thisView.add(thisImage);
    ant.leftView = thisView;
    ant.image = thisView.toImage();
 
    $.mapview.addAnnotation(ant);
Works perfectly on IOS. Its not working on Android and i'm getting this warning:

AnnotationProxy: (main) [56,25040] Unable to get the image from the path: {height=60, cropRect={x=0, width=60, height=60}, media=[object TiBlob], y=0, mimeType=image/png, x=0, width=60}

Already tried to change from toImage() to toImage().media, but still don't work.

Any ideas! Thanks!

IOS 7.1, Android 4.4.2, SDK 3.3.0


Viewing all articles
Browse latest Browse all 8068

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>