File tree Expand file tree Collapse file tree 2 files changed +1
-4
lines changed Expand file tree Collapse file tree 2 files changed +1
-4
lines changed Original file line number Diff line number Diff line change @@ -161,10 +161,6 @@ public void showUserLocation(boolean enabled) {
161
161
}
162
162
163
163
private void applyOptions (JSONObject options ) throws JSONException {
164
- if (options .has ("style" )) {
165
- this .mapView .setStyleUrl (Mapbox .getStyle (options .optString ("style" )));
166
- }
167
-
168
164
if (!options .isNull ("showUserLocation" )) {
169
165
this .showUserLocation (options .getBoolean ("showUserLocation" ));
170
166
}
Original file line number Diff line number Diff line change @@ -389,6 +389,7 @@ public void onError(String error) {
389
389
private MapView createMapView (String accessToken , JSONObject options ) throws JSONException {
390
390
MapView mapView = new MapView (this .webView .getContext ());
391
391
mapView .setAccessToken (accessToken );
392
+ mapView .setStyleUrl (Mapbox .getStyle (options .optString ("style" )));
392
393
393
394
final JSONObject margins = options .isNull ("margins" ) ? null : options .getJSONObject ("margins" );
394
395
final int left = (int ) (retinaFactor * (margins == null || margins .isNull ("left" ) ? 0 : margins .getInt ("left" )));
You can’t perform that action at this time.
0 commit comments