Added top bar

This commit is contained in:
Bipin
2020-12-14 13:35:16 +01:00
parent 8c25197967
commit 64f76f46c0
2 changed files with 45 additions and 0 deletions

View File

@@ -30,4 +30,39 @@
app:menu="@menu/navmenu"
/>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/topBar"
android:layout_width="match_parent"
android:layout_height="50dp"
android:layout_marginTop="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/infoButton"
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/topBar"
app:layout_constraintBottom_toBottomOf="@id/topBar"
android:tint="@color/white"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:layout_constraintStart_toEndOf="@id/infoButton"
app:layout_constraintTop_toTopOf="@id/topBar"
app:layout_constraintBottom_toBottomOf="@id/topBar"
android:text="@string/app_name"
android:textSize="25dp"
android:textColor="@color/white"
/>
</androidx.constraintlayout.widget.ConstraintLayout>