add a Snooze button to Reminder activity

This commit is contained in:
tibbi
2018-03-14 19:21:03 +01:00
parent 10c5b07c90
commit 3c5fe3b935
4 changed files with 42 additions and 13 deletions

View File

@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
<android.support.constraint.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:id="@+id/reminder_holder"
android:layout_width="match_parent"
@ -10,29 +11,50 @@
android:id="@+id/reminder_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_marginTop="100dp"
android:textSize="@dimen/extra_big_text_size"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.5"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:text="Timer expired"/>
<com.simplemobiletools.commons.views.MyTextView
android:id="@+id/reminder_text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/reminder_title"
android:layout_centerHorizontal="true"
android:paddingTop="@dimen/activity_margin"
android:textSize="@dimen/big_text_size"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/reminder_title"
tools:text="14:00"/>
<ImageView
android:id="@+id/reminder_snooze"
style="@style/MyBorderlessBackgroundStyle"
android:layout_width="@dimen/stopwatch_button_small_size"
android:layout_height="@dimen/stopwatch_button_small_size"
android:layout_alignParentBottom="true"
android:layout_toLeftOf="@+id/reminder_stop"
android:padding="@dimen/normal_margin"
android:src="@drawable/ic_snooze"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="@+id/reminder_stop"
app:layout_constraintEnd_toStartOf="@+id/reminder_stop"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@+id/reminder_stop"/>
<ImageView
android:id="@+id/reminder_stop"
android:layout_width="@dimen/stopwatch_button_size"
android:layout_height="@dimen/stopwatch_button_size"
android:layout_alignParentBottom="true"
android:layout_centerHorizontal="true"
android:layout_marginBottom="@dimen/big_margin"
android:padding="@dimen/normal_margin"
android:src="@drawable/ic_stop"/>
android:src="@drawable/ic_stop"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.5"
app:layout_constraintStart_toStartOf="parent"/>
</RelativeLayout>
</android.support.constraint.ConstraintLayout>

View File

@ -105,7 +105,6 @@
style="@style/MyBorderlessBackgroundStyle"
android:layout_width="wrap_content"
android:layout_height="@dimen/stopwatch_button_small_size"
android:layout_alignParentBottom="true"
android:gravity="center"
android:letterSpacing="0.1"
android:paddingLeft="@dimen/activity_margin"