history UI imrovements

This commit is contained in:
Bnyro 2022-07-01 21:17:23 +02:00
parent 7f130dedb7
commit 0e9f3ad96f
5 changed files with 49 additions and 17 deletions

View File

@ -0,0 +1,22 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:tint="?android:attr/colorControlNormal"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M21.25,12C21.25,17.108 17.109,21.25 12,21.25C6.892,21.25 2.75,17.108 2.75,12C2.75,6.891 6.892,2.75 12,2.75C17.109,2.75 21.25,6.891 21.25,12Z"
android:strokeLineJoin="round"
android:strokeWidth="2.5"
android:fillColor="#00000000"
android:fillType="evenOdd"
android:strokeColor="#130F26"
android:strokeLineCap="round"/>
<path
android:pathData="M16.191,12.767L11.661,12.693V7.846"
android:strokeLineJoin="round"
android:strokeWidth="2.5"
android:fillColor="#00000000"
android:strokeColor="#130F26"
android:strokeLineCap="round"/>
</vector>

View File

@ -17,13 +17,22 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:padding="10dp" android:padding="10dp"
android:background="?attr/selectableItemBackground" android:background="?attr/selectableItemBackground"
android:orientation="vertical"> android:orientation="horizontal">
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="10dp"
android:src="@drawable/ic_time_outlined"
android:layout_gravity="center"/>
<TextView <TextView
android:layout_width="match_parent" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginLeft="15dp"
android:text="@string/watch_history" android:text="@string/watch_history"
android:textSize="20sp"/> android:textStyle="bold"
android:textSize="18sp"/>
</LinearLayout> </LinearLayout>

View File

@ -7,22 +7,23 @@
<LinearLayout <LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:paddingHorizontal="8dp" android:layout_marginBottom="8dp"
android:layout_marginBottom="8dp" > android:paddingHorizontal="8dp">
<TextView <TextView
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="@string/watch_history" android:layout_weight="1"
android:layout_weight="1" android:text="@string/watch_history"
android:textSize="16sp" /> android:textSize="16sp" />
<ImageButton <ImageView
android:id="@+id/clearHistory" android:id="@+id/clearHistory"
android:layout_gravity="center"
android:layout_width="16dp" android:layout_width="16dp"
android:layout_height="16dp" android:layout_height="16dp"
android:src="@drawable/ic_trash"/> android:layout_marginRight="5dp"
android:layout_gravity="center"
android:src="@drawable/ic_reset" />
</LinearLayout> </LinearLayout>
@ -31,6 +32,6 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_margin="8dp" android:layout_margin="8dp"
android:nestedScrollingEnabled="false"/> android:nestedScrollingEnabled="false" />
</LinearLayout> </LinearLayout>

View File

@ -207,5 +207,5 @@
<string name="deleteAccount_summary">Delete your Piped account</string> <string name="deleteAccount_summary">Delete your Piped account</string>
<string name="account">Account</string> <string name="account">Account</string>
<string name="restore">Restore</string> <string name="restore">Restore</string>
<string name="watch_history">Watch history</string> <string name="watch_history">Watch History</string>
</resources> </resources>

View File

@ -50,7 +50,7 @@
<SwitchPreference <SwitchPreference
android:defaultValue="true" android:defaultValue="true"
android:icon="@drawable/ic_history_filled" android:icon="@drawable/ic_time_outlined"
app:key="watch_history_toggle" app:key="watch_history_toggle"
app:title="@string/watch_history" /> app:title="@string/watch_history" />