diff options
author | Konstantin Käfer <mail@kkaefer.com> | 2017-01-26 18:52:44 +0100 |
---|---|---|
committer | Konstantin Käfer <mail@kkaefer.com> | 2017-01-27 11:44:16 +0100 |
commit | 62ea1f21858c69f6921c775ba7a3de201f0514d8 (patch) | |
tree | 7a4da88706e8a5513e1e13e993b2acc212cae3b1 /platform/android/MapboxGLAndroidSDKTestApp/src/main/java/com/mapbox/mapboxsdk/testapp/activity/infowindow/DynamicInfoWindowAdapterActivity.java | |
parent | a662508ddde4043ece36d8ea9b424368891d892c (diff) | |
download | qtlocation-mapboxgl-62ea1f21858c69f6921c775ba7a3de201f0514d8.tar.gz |
[core] remove trailing whitespace, add trailing newlines, add space after //
Diffstat (limited to 'platform/android/MapboxGLAndroidSDKTestApp/src/main/java/com/mapbox/mapboxsdk/testapp/activity/infowindow/DynamicInfoWindowAdapterActivity.java')
-rw-r--r-- | platform/android/MapboxGLAndroidSDKTestApp/src/main/java/com/mapbox/mapboxsdk/testapp/activity/infowindow/DynamicInfoWindowAdapterActivity.java | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/platform/android/MapboxGLAndroidSDKTestApp/src/main/java/com/mapbox/mapboxsdk/testapp/activity/infowindow/DynamicInfoWindowAdapterActivity.java b/platform/android/MapboxGLAndroidSDKTestApp/src/main/java/com/mapbox/mapboxsdk/testapp/activity/infowindow/DynamicInfoWindowAdapterActivity.java index 15749cbd19..5da7a3047b 100644 --- a/platform/android/MapboxGLAndroidSDKTestApp/src/main/java/com/mapbox/mapboxsdk/testapp/activity/infowindow/DynamicInfoWindowAdapterActivity.java +++ b/platform/android/MapboxGLAndroidSDKTestApp/src/main/java/com/mapbox/mapboxsdk/testapp/activity/infowindow/DynamicInfoWindowAdapterActivity.java @@ -48,38 +48,38 @@ public class DynamicInfoWindowAdapterActivity extends AppCompatActivity implemen mapboxMap = map; - //Add info window adapter + // Add info window adapter addCustomInfoWindowAdapter(mapboxMap); - //Keep info windows open on click + // Keep info windows open on click mapboxMap.getUiSettings().setDeselectMarkersOnTap(false); - //Add a marker + // Add a marker final MarkerView marker = addMarker(mapboxMap); mapboxMap.selectMarker(marker); - //On map click, change the info window contents + // On map click, change the info window contents mapboxMap.setOnMapClickListener(new MapboxMap.OnMapClickListener() { @Override public void onMapClick(@NonNull LatLng point) { - //Distance from click to marker + // Distance from click to marker double distanceKm = marker.getPosition().distanceTo(point) / 1000; - //Get the info window + // Get the info window InfoWindow infoWindow = marker.getInfoWindow(); - //Get the view from the info window + // Get the view from the info window if (infoWindow != null && infoWindow.getView() != null) { - //Set the new text on the text view in the info window + // Set the new text on the text view in the info window ((TextView) infoWindow.getView()).setText(String.format("%.2fkm", distanceKm)); - //Update the info window position (as the text length changes) + // Update the info window position (as the text length changes) infoWindow.update(); } } }); - //Focus on Paris + // Focus on Paris mapboxMap.animateCamera(CameraUpdateFactory.newLatLng(paris)); } |