New option in fab: go to top.

This commit is contained in:
Docile-Alligator
2022-12-25 16:05:04 -08:00
parent 24b33bb05d
commit b74fc9354c
10 changed files with 132 additions and 46 deletions

View File

@@ -0,0 +1,12 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="@android:color/white"
android:pathData="M6,17.59l1.41,1.41l4.59,-4.58l4.59,4.58l1.41,-1.41l-6,-6z"/>
<path
android:fillColor="@android:color/white"
android:pathData="M6,11l1.41,1.41l4.59,-4.58l4.59,4.58l1.41,-1.41l-6,-6z"/>
</vector>

View File

@@ -201,6 +201,25 @@
android:focusable="true"
android:background="?attr/selectableItemBackground" />
<TextView
android:id="@+id/go_to_top_text_view_fab_more_options_bottom_sheet_fragment"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:paddingStart="32dp"
android:paddingEnd="32dp"
android:text="@string/go_to_top"
android:textColor="?attr/primaryTextColor"
android:textSize="?attr/font_default"
android:fontFamily="?attr/font_family"
app:drawableStartCompat="@drawable/ic_keyboard_double_arrow_up_24"
android:drawablePadding="48dp"
android:clickable="true"
android:focusable="true"
android:background="?attr/selectableItemBackground" />
</LinearLayout>
</androidx.core.widget.NestedScrollView>

View File

@@ -400,6 +400,7 @@
<item>@string/random</item>
<item>@string/hide_read_posts</item>
<item>@string/filter_posts</item>
<item>@string/go_to_top</item>
</string-array>
<string-array name="settings_bottom_app_bar_fab_options_anonymous">
@@ -411,6 +412,7 @@
<item>@string/go_to_user</item>
<item>@string/random</item>
<item>@string/filter_posts</item>
<item>@string/go_to_top</item>
</string-array>
<string-array name="settings_swipe_action_threshold">