Files
Next-Location/app/src/main/res/layout/activity_main.xml
2021-01-12 10:12:17 +01:00

68 lines
2.8 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout 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"
android:id="@+id/mainActivity"
tools:context=".MainActivity">
<FrameLayout
android:id="@+id/fragment_layout"
android:layout_width="match_parent"
android:layout_height="0dp"
app:layout_constraintTop_toBottomOf="@+id/top_bar"
app:layout_constraintBottom_toTopOf="@id/navigation_bar"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintEnd_toEndOf="parent"
/>
<com.google.android.material.bottomnavigation.BottomNavigationView
android:showAsAction="always|withText"
android:id="@+id/navigation_bar"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:background="@color/primaryColour"
app:itemIconTint="@color/secondaryColour"
app:itemTextColor="@color/secondaryColour"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:menu="@menu/navmenu"
/>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/top_bar"
android:layout_width="match_parent"
android:layout_height="50dp"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toTopOf="@id/fragment_layout"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintEnd_toEndOf="parent"
android:background="@color/primaryColour"/>
<ImageButton
android:id="@+id/info_button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/ic_baseline_info_24"
android:backgroundTint="@color/primaryColour"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@id/top_bar"
app:layout_constraintBottom_toBottomOf="@id/top_bar"
android:tint="@color/secondaryColour"
/>
<TextView
android:id="@+id/text_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/app_name"
android:textColor="@color/secondaryColour"
android:textSize="25sp"
app:layout_constraintBottom_toBottomOf="@id/top_bar"
app:layout_constraintStart_toEndOf="@id/info_button"
app:layout_constraintTop_toTopOf="@id/top_bar" />
</androidx.constraintlayout.widget.ConstraintLayout>