From 3a6ba961bc9d7339ecf89115944d6f5c299ed743 Mon Sep 17 00:00:00 2001 From: Iván Ávalos Date: Wed, 12 Jan 2022 19:42:20 -0600 Subject: Improved cluster generator style and disabled selection --- .../mx/trackermap/TrackerMap/android/map/MapFragment.kt | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'androidApp/src/main/java/mx/trackermap') diff --git a/androidApp/src/main/java/mx/trackermap/TrackerMap/android/map/MapFragment.kt b/androidApp/src/main/java/mx/trackermap/TrackerMap/android/map/MapFragment.kt index 1b736d1..019bb1e 100644 --- a/androidApp/src/main/java/mx/trackermap/TrackerMap/android/map/MapFragment.kt +++ b/androidApp/src/main/java/mx/trackermap/TrackerMap/android/map/MapFragment.kt @@ -71,6 +71,20 @@ class MapFragment : GlobeMapFragment() { val loader = QuadImageLoader(params, tileInfo, baseControl) loader.setImageFormat(RenderController.ImageFormat.MaplyImageUShort565) + val clusterGenerator = BasicClusterGenerator( + intArrayOf( + Color.argb(255, 255, 255, 255) + ), 0, Point2d(64.0, 64.0), baseControl, activity + ) + clusterGenerator.cacheBitmaps(true) + clusterGenerator.setExponentBase(2.5) + clusterGenerator.setTextColor(Color.BLACK) + clusterGenerator.setLayoutSize(Point2d(80.0, 80.0)) + clusterGenerator.setSelectable(false) + + baseControl.clearClusterGenerators() + baseControl.addClusterGenerator(clusterGenerator) + val latitude = 23.191 val longitude = -100.36 focusOn(latitude, longitude, zoom = 0.4, animated = false) -- cgit v1.2.3