From 208df4ca304b0a98b1876bc1aea7da4819f0cf4a Mon Sep 17 00:00:00 2001 From: paczos Date: Wed, 5 Jul 2017 11:56:53 +0200 Subject: [PATCH] [android] - invible marker views performance fix #9419 --- .../com/mapbox/mapboxsdk/annotations/MarkerViewManager.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/annotations/MarkerViewManager.java b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/annotations/MarkerViewManager.java index 6d42842b7dc..dce6f6b2777 100644 --- a/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/annotations/MarkerViewManager.java +++ b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/annotations/MarkerViewManager.java @@ -198,7 +198,7 @@ public void updateMarkerViewsPosition() { // ensure view is measured first // #6805 invalidate marker views to ensure convertView width and height // values are properly measured and up to date - if (marker.getWidth() == 0) { + if (marker.getWidth() == 0 && marker.isVisible()) { convertView.getViewTreeObserver().addOnPreDrawListener(markerViewPreDrawObserver); } }