Skip to content

Comments

Added Line Of Sight Feature for repeater placement, Added app wide Units Setting#198

Merged
wel97459 merged 6 commits intozjs81:mainfrom
just-stuff-tm:main
Feb 21, 2026
Merged

Added Line Of Sight Feature for repeater placement, Added app wide Units Setting#198
wel97459 merged 6 commits intozjs81:mainfrom
just-stuff-tm:main

Conversation

@just-stuff-tm
Copy link
Contributor

@just-stuff-tm just-stuff-tm commented Feb 19, 2026

Summary

This PR adds a full Line of Sight (LOS) workflow to the map, introduces an app-wide metric/imperial unit system, fixes BLE debug build-phase notifier issues, hardens notification initialization, and improves map labeling/overflow behavior across map experiences.

It also includes LOS service tests, localization improvements.

What Changed

1. New LOS feature

Added LOS screen:

  • lib/screens/line_of_sight_map_screen.dart

Added LOS computation service:

  • lib/services/line_of_sight_service.dart

Added tests:

  • test/services/line_of_sight_service_test.dart

LOS capabilities:

  • LOS button next to Path Trace in map header.
  • Select A/B from dropdown and map-node taps.
  • Long press on map to add custom points.
  • Rename/delete custom points.
  • Toggle to hide/show display nodes.
  • Clear action in header uses trash icon and clears all points/selections.
  • Collapsible LOS menu.
  • Graph at top of HUD; compact status text under graph.
  • Antenna height controls up to 400 ft (imperial), equivalent cap in metric.
  • Bottom navigation matches regular map experience.
  • LOS markers preserve node-type icon/color styling.

2. Global unit system (app-wide)

Added global setting unitSystem (metric/imperial) with backward compatibility for older stored key/value reads:

  • lib/models/app_settings.dart
  • lib/services/app_settings_service.dart
  • lib/screens/app_settings_screen.dart

Unit setting now applied in:

  • LOS distances/heights.
  • Path trace distance formatting:
    • lib/screens/path_trace_map.dart
    • lib/screens/map_screen.dart
    • lib/screens/channel_message_path_screen.dart
  • Telemetry temperature display:
    • lib/screens/telemetry_screen.dart

3. BLE debug log runtime fix

Prevented notifyListeners() during build by deferring notification safely post-frame:

  • lib/services/ble_debug_log_service.dart

Fixes runtime error:

  • setState() or markNeedsBuild() called during build

4. Notification stability hardening

Added Windows initialization settings and guarded notification show paths against uninitialized plugin usage:

  • lib/services/notification_service.dart

Notes:

  • Uses project-generic Windows app id (no personal identifier).

5. Map label UX improvements

Added node-name label pills on:

  • Main map: lib/screens/map_screen.dart
  • LOS map: lib/screens/line_of_sight_map_screen.dart
  • Path Trace result map: lib/screens/path_trace_map.dart
  • Channel Message Path result map: lib/screens/channel_message_path_screen.dart

Behavior:

  • Labels auto-fit long names.
  • Labels auto-hide/show by zoom level to reduce clutter.
  • Visibility threshold adjusted to remain visible farther out.

Validation Performed

  • flutter analyze passed.
  • flutter test passed.
  • Manual checks completed for:
    • LOS flow (selection, custom points, clear/reset, HUD behavior)
    • Unit switching across relevant screens
    • Contact list tile no-overflow behavior
    • Label visibility/auto-fit behavior across map screens

Notes

  • No BLE protocol command/frame format changes.
  • Path tracing remains separate from LOS flow.

Checklist

  • Feature implemented
  • Existing behavior checked for regressions
  • Tests added for LOS service
  • Analyzer/test suite passing

…rflow fixes

Squashes prior PR commits into one changeset including: LOS map/service/tests, global metric/imperial unit system adoption, notification/BLE safety fixes, app-wide localization backfill/mojibake cleanup, and responsive UI title/overflow hardening.
@just-stuff-tm just-stuff-tm marked this pull request as ready for review February 19, 2026 22:10
@just-stuff-tm
Copy link
Contributor Author

Im gonna have to resolve some issues it looks like our prs conflicted @wel97459

@just-stuff-tm
Copy link
Contributor Author

This PR has been rebased/cleaned to align with latest upstream merges and keep only the intended LOS + app-wide units work.

What’s included:

  • Kept the Line of Sight workflow and map entry flow.
  • Kept app-wide unit settings (metric/imperial) and wired them through LOS/path distance displays.
  • Regenerated localization outputs to keep translation files in sync.
  • Resolved conflicts against upstream updates (including prior merged overlapping work) without reintroducing the adaptive app bar title behavior.

Validation:

  • flutter gen-l10n
  • flutter analyze --fatal-infos --fatal-warnings
  • flutter test test/services/line_of_sight_service_test.dart

@just-stuff-tm just-stuff-tm changed the title Added Line Of Sight Feature for repeater placement, Fixed Translation Errors, Fixed Multiple Widget Overflow issues Added Line Of Sight Feature for repeater placement, Added app wide Units Setting Feb 21, 2026
@wel97459 wel97459 merged commit f4b18d9 into zjs81:main Feb 21, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants