<?xml version="1.0" encoding="utf-8"?> <layout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto"> <data> <variable name="mainViewModel" type="jackall.moncalc.viewmodel.MainViewModel" /> </data> <android.support.constraint.ConstraintLayout android:layout_width="match_parent" android:layout_height="match_parent"> <Button android:id="@+id/start_service_button" android:layout_width="match_parent" android:layout_height="wrap_content" android:onClick="@{mainViewModel.onClickServiceButton}" android:text="@={mainViewModel.serviceButtonText}" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" /> <android.support.design.widget.TabLayout android:id="@+id/main_tab_layout" android:layout_width="match_parent" android:layout_height="50dp" app:tabMinWidth="100dp" app:tabMode="scrollable" /> <View android:id="@+id/main_tab_layout_shadow" android:layout_width="match_parent" android:layout_height="4dp" android:background="@drawable/shadow" app:layout_constraintTop_toBottomOf="@id/main_tab_layout" /> <android.support.v4.view.ViewPager android:id="@+id/main_view_pager" android:layout_width="0dp" android:layout_height="0dp" app:layout_constraintBottom_toTopOf="@+id/start_service_button" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toBottomOf="@+id/main_tab_layout_shadow"> </android.support.v4.view.ViewPager> </android.support.constraint.ConstraintLayout> </layout>