Permalink
Browse files

Force MockCircle default position to (0, 0)

Fixes #1379

Change-Id: I2682c4b12806e13a78524fce2d47293d46123f93
  • Loading branch information...
ewpatton authored and SusanRatiLane committed Sep 30, 2018
1 parent c8199a0 commit 118fe43072288ed62dffda1339f58f758694b199
@@ -134,7 +134,10 @@ private void updateRadius(double radius) {
// JSNI Methods
private native void initCircle()/*-{
this.@com.google.appinventor.client.editor.simple.components.MockMapFeatureBase::feature =
top.L.circle([], @com.google.appinventor.components.common.ComponentConstants::CIRCLE_PREFERRED_RADIUS, {
// Fix for https://github.com/mit-cml/appinventor-sources/issues/1379: Initial coordinate
// should match default property values for Latitude and Longitude (i.e., (0, 0)) otherwise
// Leaflet throws an exception when we later add the Circle to the Map.
top.L.circle([0, 0], @com.google.appinventor.components.common.ComponentConstants::CIRCLE_PREFERRED_RADIUS, {
className: 'leaflet-interactive',
weight: 1,
color: '#000',

0 comments on commit 118fe43

Please sign in to comment.