Permalink
Browse files

bug/#1209 - using a resource for direction icon on each dpi folder (#…

…1212)

Removed resource:
* `drawable.direction_arrow.png` (only 1 version)

New resource:
* `drawable.round_navigation_white_48.png` (5 versions from `mdpi` to `xxxhdpi`)

Impacted classes:
* `CustomPaintingSurface`, `DirectedLocationOverlay`, `MyLocationNewOverlay`: used drawable `round_navigation_white_48` instead of `direction_arrow`
  • Loading branch information...
monsieurtanuki authored and spyhunter99 committed Dec 6, 2018
1 parent 5316e38 commit c956fe1d923916d1c362994918e31b74c7d45174
@@ -178,7 +178,7 @@ public boolean onClick(Polyline polyline, MapView mapView, GeoPoint eventPos) {
polygon.setTitle("A sample polygon");
polygon.showInfoWindow();
if (withArrows) {
final Bitmap bitmap = BitmapFactory.decodeResource(getResources(), org.osmdroid.library.R.drawable.direction_arrow);
final Bitmap bitmap = BitmapFactory.decodeResource(getResources(), org.osmdroid.library.R.drawable.round_navigation_white_48);
final List<MilestoneManager> managers = new ArrayList<>();
managers.add(new MilestoneManager(
new MilestonePixelDistanceLister(20, 200),
@@ -57,7 +57,7 @@
public DirectedLocationOverlay(final Context ctx) {
super();
BitmapDrawable d=(BitmapDrawable)ctx.getResources().getDrawable(R.drawable.direction_arrow);
BitmapDrawable d=(BitmapDrawable)ctx.getResources().getDrawable(R.drawable.round_navigation_white_48);
setDirectionArrow(d.getBitmap());
@@ -107,7 +107,7 @@ public MyLocationNewOverlay(IMyLocationProvider myLocationProvider, MapView mapV
setDirectionArrow(((BitmapDrawable)mapView.getContext().getResources().getDrawable(R.drawable.person)).getBitmap(),
((BitmapDrawable)mapView.getContext().getResources().getDrawable(R.drawable.direction_arrow)).getBitmap());
((BitmapDrawable)mapView.getContext().getResources().getDrawable(R.drawable.round_navigation_white_48)).getBitmap());
// Calculate position of person icon's feet, scaled to screen density
mPersonHotspot = new PointF(24.0f * mScale + 0.5f, 39.0f * mScale + 0.5f);
Binary file not shown.

0 comments on commit c956fe1

Please sign in to comment.