Skip to content

Commit

Permalink
Fix clinometer size on small screens
Browse files Browse the repository at this point in the history
  • Loading branch information
kylecorry31 committed Dec 26, 2023
1 parent d67ac95 commit d360542
Showing 1 changed file with 18 additions and 10 deletions.
28 changes: 18 additions & 10 deletions app/src/main/res/layout/fragment_clinometer.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,34 +20,41 @@

<com.kylecorry.trail_sense.tools.clinometer.ui.ClinometerView
android:id="@+id/clinometer"
android:layout_width="250dp"
android:layout_height="250dp"
android:layout_marginTop="64dp"
android:layout_width="0dp"
android:layout_height="0dp"
android:layout_marginStart="16dp"
android:layout_marginTop="16dp"
android:layout_marginEnd="16dp"
android:layout_marginBottom="16dp"
app:layout_constraintBottom_toTopOf="@id/data_points"
app:layout_constraintDimensionRatio="1:1"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/clinometer_title" />


<LinearLayout
android:id="@+id/camera_view_holder"
android:layout_width="match_parent"
android:layout_width="0dp"
android:layout_height="0dp"
app:layout_constraintDimensionRatio="1:1"
android:layout_marginStart="16dp"
android:layout_marginTop="16dp"
android:layout_marginEnd="16dp"
android:layout_marginTop="64dp"
android:layout_marginBottom="16dp"
android:background="@drawable/rounded_rectangle"
android:orientation="horizontal"
android:visibility="gone"
app:layout_constraintBottom_toTopOf="@id/data_points"
app:layout_constraintDimensionRatio="1:1"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/clinometer_title"
tools:visibility="visible">

<FrameLayout
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="match_parent">
android:layout_height="match_parent"
android:layout_weight="1">

<com.kylecorry.trail_sense.shared.views.CameraView
android:id="@+id/camera"
Expand All @@ -56,9 +63,9 @@

<com.kylecorry.trail_sense.tools.augmented_reality.AugmentedRealityView
android:id="@+id/ar_view"
android:layout_gravity="center"
android:layout_width="match_parent"
android:layout_height="match_parent"/>
android:layout_height="match_parent"
android:layout_gravity="center" />

<View
android:layout_width="60dp"
Expand All @@ -76,6 +83,7 @@


<LinearLayout
android:id="@+id/data_points"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="16dp"
Expand Down

0 comments on commit d360542

Please sign in to comment.