blob: a99a8cbb3f3c3009259e44f61712547d06c94e71 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
|
<?xml version="1.0" encoding="utf-8"?>
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity">
<!-- Main Content Area -->
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginBottom="56dp"> <!-- Space for BottomNav -->
<org.maplibre.android.maps.MapView
android:id="@+id/mapView"
android:layout_width="match_parent"
android:layout_height="match_parent" />
<org.terst.nav.ui.map.ParticleWindView
android:id="@+id/particle_wind_view"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clickable="false"
android:focusable="false" />
<!-- Overlay Fragment Container (for Log, Safety, Help) -->
<FrameLayout
android:id="@+id/fragment_container"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone"
android:background="?attr/colorSurface" />
<!-- Track stats bar — shown only while recording -->
<TextView
android:id="@+id/tv_track_stats"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="top|center_horizontal"
android:layout_marginTop="12dp"
android:paddingHorizontal="14dp"
android:paddingVertical="6dp"
android:background="#CC000000"
android:textColor="#FFFFFFFF"
android:textSize="13sp"
android:fontFamily="monospace"
android:text=""
android:visibility="gone"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintEnd_toEndOf="parent" />
</androidx.constraintlayout.widget.ConstraintLayout>
<!-- Collapsible Instrument Bottom Sheet -->
<androidx.cardview.widget.CardView
android:id="@+id/instrument_bottom_sheet"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:behavior_hideable="false"
app:behavior_peekHeight="120dp"
app:cardElevation="16dp"
app:cardCornerRadius="24dp"
app:layout_behavior="com.google.android.material.bottomsheet.BottomSheetBehavior">
<include
layout="@layout/layout_instruments_sheet"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</androidx.cardview.widget.CardView>
<!-- Bottom Navigation -->
<com.google.android.material.bottomnavigation.BottomNavigationView
android:id="@+id/bottom_navigation"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:background="?attr/colorSurface"
app:menu="@menu/bottom_nav_menu" />
<!-- Persistent MOB Button (Crucial for safety, always on top) -->
<com.google.android.material.floatingactionbutton.FloatingActionButton
android:id="@+id/fab_mob"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="16dp"
android:clickable="true"
android:focusable="true"
android:contentDescription="Man Overboard"
app:srcCompat="@android:drawable/ic_dialog_alert"
app:backgroundTint="@color/mob_button_background"
app:layout_anchor="@id/instrument_bottom_sheet"
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/instrument_bottom_sheet"
app:layout_anchorGravity="top|end" />
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|