Titanium JIRA Archive
Appcelerator Community (AC)

[AC-2300] Android: Problem with Annotation rightView

GitHub Issuen/a
ResolutionNeeds more info
Resolution Date2013-07-23T22:00:00.000+0000
Affected Version/sn/a
Fix Version/sn/a
ComponentsTitanium SDK & CLI
Labelsandroid, annotations, view
ReporterArmindo Da Silva
AssigneeMauro Parra-Miranda


*Problem* When using rightView property annotation, when clearing all annotations, it seems that on Android, it deletes the view as well, so next time you update the annotation (by recreating them), when you click on annotations it crashes the app. *Test case*
var annotView = Titanium.UI.createView({
	height : '32dp',
	width : '70dp'

function createAnnotations() {
	// then a loop for creating annotations
	for (var i = 0; i < annot.length; i++) {
		// some stuff here
		var annotation = Titanium.Map.createAnnotation({
			latitude : lat,
			longitude : lon,
			title : myTitle,
			subtitle : myTitle,
			animate : true,
			leftButton : '/images/myImg.png',
			dataId : i,
			rightView : annotView
		// some stuff here

// call createAnnotations();
Now you can click the annotations and it works fine. Then you clear all annotations and call createAnnotations() again. If you click on an annotation it crashes the app. This code works fine on iOS.


  1. Daniel Sefton 2013-07-11

    Hi Armindo, It would help a lot if you could edit your test case to be runnable in a project so that we can easily reproduce the crash. Thanks!

JSON Source