Skip to content
This repository was archived by the owner on Mar 25, 2021. It is now read-only.

Commit 93b0e62

Browse files
committed
Location object uses decimals instead of float datatype
1 parent 383c52a commit 93b0e62

3 files changed

Lines changed: 4 additions & 2 deletions

File tree

src/Google Maps Widget.mpr

48 KB
Binary file not shown.

src/javasource/googlemaps/actions/CalculateGeo.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@
1313
import com.mendix.systemwideinterfaces.core.UserAction;
1414
import googlemaps.actions.GeoCoder.Location;
1515
import java.io.IOException;
16+
import java.math.BigDecimal;
17+
import java.math.MathContext;
1618
import java.security.AccessControlException;
1719
import com.mendix.systemwideinterfaces.core.IMendixObject;
1820
import com.mendix.systemwideinterfaces.core.IContext;
@@ -44,8 +46,8 @@ public Boolean executeAction() throws Exception
4446

4547
loc = GeoCoder.getLocation(addressString);
4648

47-
locationObj.setLatitude(loc.lat);
48-
locationObj.setLongitude(loc.lon);
49+
locationObj.setLatitude(new BigDecimal(loc.lat, MathContext.DECIMAL64));
50+
locationObj.setLongitude(new BigDecimal(loc.lon, MathContext.DECIMAL64));
4951

5052
return true;
5153
// END USER CODE

src/widgets/GoogleMaps.mpk

1.29 KB
Binary file not shown.

0 commit comments

Comments
 (0)