Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-24613] Android: customView is not displayed as annotation on Map when used with borderRadius/Color/Width

GitHub Issuen/a
TypeBug
PriorityMedium
StatusOpen
ResolutionUnresolved
Affected Version/sn/a
Fix Version/sn/a
Componentsn/a
Labelsn/a
ReporterILAY SENER
AssigneeUnknown
Created2017-04-21T08:29:21.000+0000
Updated2018-02-28T19:55:39.000+0000

Description

customView works fine in annotation. However, trying to make the view round using borderRadius/color/width makes the annotation non visible.
var Map = require('ti.map');
var mapView = Map.createView();

var place = {
    latitude: 37.338208,
    longitude: -121.886329
};

var win = Ti.UI.createWindow({
    backgroundColor: '#fff'
});

var orangePointer = Ti.UI.createView({
    width : 50,
    height : 50,
    borderRadius : 5,
    borderWidth : 2,
    borderColor : '#fff',
    backgroundColor : '#FF6300',
});

var annot = Alloy.Globals.Map.createAnnotation({
    latitude : place.latitude,
    longitude : place.longitude,
    customView : orangePointer,
});
mapView.addAnnotation(annot);

win.add(mapView);
win.open();

Comments

  1. ILAY SENER 2017-04-21

    In addition, if you create a View (view1) with borderRadius etc, then add this to another View (view2) and use view2 as the customView in the annotation, all seems to work... however, this is a band-aid solution.
  2. Hans Knöchel 2017-04-22

    -Hey [~isener], can you provide a single JS test-case that our engineers can use to debug it?- Updated your test-case, this should still reproduce it but is more simplified. [~gmathews] I remember we had issues with borders on views in the past, maybe we have something ready for this?

JSON Source