summaryrefslogtreecommitdiff
path: root/android-app/app/src/main/res/layout
diff options
context:
space:
mode:
authorPeter Stone <thepeterstone@gmail.com>2026-03-25 18:09:53 +0000
committerPeter Stone <thepeterstone@gmail.com>2026-03-25 18:09:53 +0000
commitca57e40adc0b89e7dc5409475f7510c0c188d715 (patch)
treed1fd636e0bdd67e36870ae891ed55d7d764689cf /android-app/app/src/main/res/layout
parentb5ab0c5236d7503dc002b7bf04e0e33b9c7ff9fa (diff)
feat(track): implement GPS track recording with map overlay
- TrackRepository + TrackPoint wired into MainViewModel: isRecording/trackPoints StateFlows, startTrack/stopTrack/addGpsPoint - MapHandler.updateTrackLayer(): lazily initialises a red LineLayer and updates GeoJSON polyline from List<TrackPoint> - fab_record_track FAB in activity_main.xml (top|end of bottom nav); icon toggles between ic_track_record and ic_close while recording - MainActivity feeds every GPS fix into viewModel.addGpsPoint() and observes trackPoints to redraw the polyline in real time - ic_track_record.xml vector drawable (red record dot) - 8 TrackRepositoryTest tests all GREEN Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'android-app/app/src/main/res/layout')
-rw-r--r--android-app/app/src/main/res/layout/activity_main.xml13
1 files changed, 13 insertions, 0 deletions
diff --git a/android-app/app/src/main/res/layout/activity_main.xml b/android-app/app/src/main/res/layout/activity_main.xml
index 66d1abe..552bf99 100644
--- a/android-app/app/src/main/res/layout/activity_main.xml
+++ b/android-app/app/src/main/res/layout/activity_main.xml
@@ -68,4 +68,17 @@
app:layout_anchor="@id/bottom_navigation"
app:layout_anchorGravity="top|start" />
+ <!-- Record Track Button -->
+ <com.google.android.material.floatingactionbutton.FloatingActionButton
+ android:id="@+id/fab_record_track"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_margin="16dp"
+ android:clickable="true"
+ android:focusable="true"
+ android:contentDescription="Record Track"
+ app:srcCompat="@drawable/ic_track_record"
+ app:layout_anchor="@id/bottom_navigation"
+ app:layout_anchorGravity="top|end" />
+
</androidx.coordinatorlayout.widget.CoordinatorLayout>