From 3f527b43ef26318d6effae8deda3eb8e5f2523dd Mon Sep 17 00:00:00 2001 From: Masashi Katsumata Date: Sat, 7 Nov 2026 23:10:49 -0800 Subject: [PATCH] Clear strategy-driven markers in clearOverlays() clearOverlays() cleared this provider's own overlay controllers but not the strategy controller behind MarkerRenderingSupport, so markers drawn by clustering (or any other marker-rendering plugin) stayed on the map. It now ends with MapServiceRegistry.clearMarkerRendering() (ios-sdk-core fix/clear-strategy), which reaches the registered support's clearMarkers(): StrategyMarkerController.clear() (onRemove -> strategy.clear() -> onPostProcess), and the next syncMarkers sends the markers again, as the overlay collectors do after a clear. Requires the ios-sdk-core change that adds clearMarkers() to MarkerRenderingSupport. --- .../OpenMobileMapsMapViewController.swift | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Sources/MapConductorForOpenMobileMaps/OpenMobileMapsMapViewController.swift b/Sources/MapConductorForOpenMobileMaps/OpenMobileMapsMapViewController.swift index 38ca90b..ff68179 100644 --- a/Sources/MapConductorForOpenMobileMaps/OpenMobileMapsMapViewController.swift +++ b/Sources/MapConductorForOpenMobileMaps/OpenMobileMapsMapViewController.swift @@ -470,6 +470,9 @@ public final class OpenMobileMapsMapViewController: MapViewControllerProtocol { await circleController.clear() await groundImageController.clear() await rasterLayerController.clear() + // strategy(クラスタリングなど)が描いたマーカーも消す。OMM は自分の strategyManager を + // MarkerRenderingSupportKey に登録している(他プロバイダは state.serviceRegistry 経由で同じものに届く)。 + await strategyManager.clearMarkers() layers.clearAll() }