From 9c12b1eccb86df7c6c4dcb21d2101b6c3b40ea8a Mon Sep 17 00:00:00 2001 From: atsunatsu Date: Fri, 11 Sep 2026 21:17:12 +0800 Subject: [PATCH] =?UTF-8?q?fix(map):=20own=20grid=20never=20striped=20?= =?UTF-8?q?=E2=80=94=20bold=20outline=20only?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The station's own gridsquare is in the roamed set (LoTW MY_GRIDSQUARE includes the home grid). Exclude it from the blue stripe overlay at both zoom levels so the current cell shows only its bold cyan outline, matching the user's request. chore: bump version to 4.4.6-ba7opf.10 --- .../look4sat/feature/map/MaidenheadGridOverlay.kt | 10 +++++++--- gradle/libs.versions.toml | 2 +- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/feature/map/src/main/java/com/rtbishop/look4sat/feature/map/MaidenheadGridOverlay.kt b/feature/map/src/main/java/com/rtbishop/look4sat/feature/map/MaidenheadGridOverlay.kt index 287168fa..28eaa4c3 100644 --- a/feature/map/src/main/java/com/rtbishop/look4sat/feature/map/MaidenheadGridOverlay.kt +++ b/feature/map/src/main/java/com/rtbishop/look4sat/feature/map/MaidenheadGridOverlay.kt @@ -201,9 +201,10 @@ class MaidenheadGridOverlay : Overlay() { // Roamed/activated grid stripes: blue 45° zebra (GridMaster style) over // every cell the station operated from. Drawn AFTER the worked fills so // a worked+roamed cell shows blue stripes with green between them — the - // stripe paint is nearly opaque, so the two colors never alpha-blend + // stripe paint is fully opaque, so the two colors never alpha-blend // into a teal/green mix. Same geometry as the worked fills (per-4-char - // cell at both zoom levels). + // cell at both zoom levels). The station's OWN grid is excluded: it + // already carries the bold outline and must not be striped (user req). if (roamedGrids.isNotEmpty()) { if (zoom >= GRID_ZOOM_SUB) { for (row in firstRow..lastRow) { @@ -220,13 +221,16 @@ class MaidenheadGridOverlay : Overlay() { val xLeft = xLeftBase + turn * worldWidthPx.toFloat() val xRight = xRightBase + turn * worldWidthPx.toFloat() if (xRight < 0f || xLeft > canvas.width) continue - if (cellLabel(lat, lon, zoom) in roamedGrids) { + val label = cellLabel(lat, lon, zoom) + if (label in roamedGrids && label != ownGrid) { drawStripes(canvas, xLeft, yTop, xRight, yBottom) } } } } else { for (grid in roamedGrids) { + // The own grid keeps only its bold outline — no stripes. + if (grid == ownGrid) continue val cell = gridCellBounds(grid) ?: continue for (turn in -colRepeats..colRepeats) { val dLon = turn * 360.0 diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 93e1cec7..1e8a05b1 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -2,7 +2,7 @@ #noinspection UnusedVersionCatalogEntry appVersionCode = "468" #noinspection UnusedVersionCatalogEntry -appVersionName = "4.4.6-ba7opf.9.19" +appVersionName = "4.4.6-ba7opf.10" #noinspection UnusedVersionCatalogEntry compileSdk = "37" #noinspection UnusedVersionCatalogEntry