tweak collapse button

This commit is contained in:
sk
2023-02-06 13:32:34 +01:00
parent bd39ed3754
commit fc1bd14f70
5 changed files with 27 additions and 9 deletions

View File

@@ -0,0 +1,3 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp" android:height="24dp" android:viewportWidth="24" android:viewportHeight="24">
<path android:pathData="M4.293 8.293c0.39-0.39 1.024-0.39 1.414 0L12 14.586l6.293-6.293c0.39-0.39 1.024-0.39 1.414 0 0.39 0.39 0.39 1.024 0 1.414l-7 7c-0.39 0.39-1.024 0.39-1.414 0l-7-7c-0.39-0.39-0.39-1.024 0-1.414z" android:fillColor="@color/fluent_default_icon_tint"/>
</vector>

View File

@@ -41,16 +41,28 @@
android:src="@drawable/ic_visibility"
android:tint="?android:textColorSecondary" />
<ImageView
<FrameLayout
android:id="@+id/collapse_btn"
android:layout_width="36dp"
android:layout_height="36dp"
android:layout_toStartOf="@id/visibility"
android:background="?android:actionBarItemBackground"
android:scaleType="center"
android:src="@drawable/ic_fluent_chevron_down_20_filled"
android:visibility="gone"
android:tint="?android:textColorSecondary" />
android:visibility="gone">
<!-- wrapping this button so the flip animation doesn't flip the background and the tooltip
isn't displaced by the -1 scale -->
<ImageView
android:id="@+id/collapse_btn_icon"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:importantForAccessibility="no"
android:scaleType="center"
android:src="@drawable/ic_fluent_chevron_down_20_filled"
android:tint="?android:textColorSecondary" />
</FrameLayout>
<ImageView
android:id="@+id/unread_indicator"

View File

@@ -255,5 +255,5 @@
<string name="sk_filtered">Filtered: %s</string>
<string name="sk_expand">Expand</string>
<string name="sk_collapse">Collapse</string>
<string name="sk_settings_collapse_long_posts">Collapse long posts</string>
<string name="sk_settings_collapse_long_posts">Collapse very long posts</string>
</resources>