Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-13006] Android: Maps V2 Module - image for a button on the annotation not showing up

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionDuplicate
Resolution Date2013-03-15T00:30:31.000+0000
Affected Version/sRelease 2.1.3
Fix Version/s2013 Sprint 06 API, 2013 Sprint 06, Co-3.1.0
ComponentsAndroid
LabelsSupportTeam
ReporterEduardo Gomez
AssigneeIngo Muschenetz
Created2013-03-08T17:03:21.000+0000
Updated2017-03-21T23:03:39.000+0000

Description

Issue

The image for a button on the annotation is not showing up. You get the screenshot attached called: AnnotationPopupWithNoButton.png. It should look like AnnotationWithAButton.png

Additional details

Something to note is that once that annotation has been selected the app does not force close when you select it later on but selecting any other annotation causes the app to close.

Steps to reproduce

Just replace few lines of code below "Resources/ui/common/FirstView.js" using sample project attached in Timob-13004 and install to device to get it to work.
//FirstView Component Constructor
function FirstView() {

var self = Ti.UI.createView();

var MapModule = require('ti.map');
 
var map1 = MapModule.createView({
    userLocation: true,
    mapType: MapModule.NORMAL_TYPE,
    animate: true,
    region: {latitude: -33.87365, longitude: 151.20689, latitudeDelta: 0.1, longitudeDelta: 0.1 }, //Sydney
    height: '80%',
    top: 0,
    left: 0,
    width: '100%'
});

var anno1 = MapModule.createAnnotation({
                latitude: -33.86665,
                longitude: 151.20689,
                title: "Anno2",
                subtitle: "Ann2 subtitle",
                animate: true,
                id: 33
            });
    anno1.image = '/mbanking/images/Locations-Pin-Android-red-hdpi.png';
    anno1.rightButton = '/images/locations-android-popover-arrow.png';
    anno1.rightButton.height = 44;
    anno1.rightButton.width = 46;

var anno2 = MapModule.createAnnotation({
                latitude: -33.87365,
                longitude: 151.20689,
                title: "Anno2",
                subtitle: "Ann2 subtitle",
                animate: true,
                id: 43
            });
    anno2.image = '/mbanking/images/Locations-Pin-Android-red-hdpi.png';
    anno2.rightButton = '/images/locations-android-popover-arrow.png';
    anno2.rightButton.height = 44;
    anno2.rightButton.width = 46;

var anno3 = MapModule.createAnnotation({
                latitude: -33.87964,
                longitude: 151.21130,
                title: "Anno3",
                subtitle: "Ann3 subtitle",
                animate: true,
                id: 45
            });
    anno3.image = '/mbanking/images/Locations-Pin-Android-red-hdpi.png';
    anno3.rightButton = '/images/locations-android-popover-arrow.png';
    anno3.rightButton.height = 44;
    anno3.rightButton.width = 46;


var anns = [];
anns.push(anno1);
anns.push(anno2);
anns.push(anno3);
map1.addAnnotations(anns);

setTimeout(function () {
map1.selectAnnotation(anno1, true);
map1.setHeight('100%');
}, 8000);

self.add(map1);

    return self;

}

module.exports = FirstView;

Further details

Public link 2.1.3.MapsModule patched 2.1.3.GA SDK for use: http://dl.dropbox.com/u/34061091/mobilesdk-2.1.3.MapsModule-osx.zip

Attachments

FileDateSize
AnnotationPopupWithNoButton.png2013-03-08T17:03:21.000+0000369386
AnnotationWithAButton.png2013-03-08T17:03:21.000+0000189724

Comments

  1. Ping Wang 2013-03-15

    The current Map module does not support leftButton and rightButton. This has been reported in TIMOB-12810. Mark this ticket as duplicate.
  2. Lee Morris 2017-03-21

    Closing ticket as duplicate with reference to the above comments.

JSON Source