show markers that are partially on screen

This commit is contained in:
Hannes Janetzek 2014-01-29 00:56:50 +01:00
parent 5ca313a9b2
commit aaf250dca4

View File

@ -103,6 +103,11 @@ public abstract class ItemizedLayer<Item extends MarkerItem> extends MarkerLayer
mMap.getViewport().getMapViewProjection(mBox); mMap.getViewport().getMapViewProjection(mBox);
float flipMax = (float) (Tile.SIZE * pos.scale) / 2; float flipMax = (float) (Tile.SIZE * pos.scale) / 2;
/** increase view to show items that are partially visible */
for (int i = 0; i < 8; i++)
// should suffice for reasonable large items
mBox[i] += mBox[i] > 0 ? 100 : -100;
synchronized (lock) { synchronized (lock) {
if (mItems == null) { if (mItems == null) {