Add proper markers icons

This commit is contained in:
Mieszko Wrzeszczyński 2018-11-25 22:27:57 +01:00
parent aef7174d90
commit f0df7b7440
16 changed files with 10 additions and 10 deletions

View File

@ -232,7 +232,7 @@ public class MapActivity extends BaseActivity
mapboxMap.addOnMapLongClickListener((LatLng latLng) -> { mapboxMap.addOnMapLongClickListener((LatLng latLng) -> {
selectLocationButton.setVisibility(View.VISIBLE); selectLocationButton.setVisibility(View.VISIBLE);
removeLocationButton.setVisibility(View.GONE); removeLocationButton.setVisibility(View.GONE);
Icon icon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.green_marker); Icon icon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.my_marker);
if (tmpLocalMarker == null) { if (tmpLocalMarker == null) {
@ -400,14 +400,14 @@ public class MapActivity extends BaseActivity
coordsMap.put(id, element); coordsMap.put(id, element);
String sharingLevel = coordsMap.get(id).getDisplayMode(); String sharingLevel = coordsMap.get(id).getDisplayMode();
Icon defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.red_marker); Icon defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.exact_localization_marker);
if (sharingLevel.equals(SharingLevel.APPROXIMATED.toString())) { if (sharingLevel.equals(SharingLevel.APPROXIMATED.toString())) {
defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.blue_marker); defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.approximate_localization_marker);
} else if (sharingLevel.equals(SharingLevel.MANUAL.toString())) { } else if (sharingLevel.equals(SharingLevel.MANUAL.toString())) {
defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.green_marker); defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.manual_localization_marker);
} else if (id.equals(myID)) { } else if (id.equals(myID)) {
defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.custom_marker); defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.my_marker);
} }
MarkerOptions markerOptions = new MarkerOptions() MarkerOptions markerOptions = new MarkerOptions()
@ -426,16 +426,16 @@ public class MapActivity extends BaseActivity
Boolean newLocalizationMode = markerHash.get(id).getMarkerType().equals(newSharingLevel); Boolean newLocalizationMode = markerHash.get(id).getMarkerType().equals(newSharingLevel);
if (!newLocalizationMode) { if (!newLocalizationMode) {
Icon defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.red_marker); Icon defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.exact_localization_marker);
MapMarker marker = markerHash.get(id); MapMarker marker = markerHash.get(id);
coordsMap.get(id).setDisplayMode(newSharingLevel); coordsMap.get(id).setDisplayMode(newSharingLevel);
if (newSharingLevel.equals(SharingLevel.APPROXIMATED.toString())) { if (newSharingLevel.equals(SharingLevel.APPROXIMATED.toString())) {
defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.blue_marker); defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.approximate_localization_marker);
} else if (newSharingLevel.equals(SharingLevel.MANUAL.toString())) { } else if (newSharingLevel.equals(SharingLevel.MANUAL.toString())) {
defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.green_marker); defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.manual_localization_marker);
} else if (id.equals(myID)) { } else if (id.equals(myID)) {
defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.custom_marker); defaultIcon = IconFactory.getInstance(MapActivity.this).fromResource(R.drawable.my_marker);
} }
marker.setDefaultIcon(defaultIcon); marker.setDefaultIcon(defaultIcon);

Binary file not shown.

Before

Width:  |  Height:  |  Size: 923 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 923 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 444 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 389 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 399 B

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB