Use vector drawables instead of PNGs for material icons

For all manually-created images PNG have been kept.
- rename all icon attrs to have a `ic_` prefix
- always use `_24dp` icons, because there is no real difference, since they are vector drawables
- always use the original name found on material.io for icon drawables, as to not create confusion and possibly duplicates. Icon names can still be different from real drawable names, though I have made some of them compliant to this or maybe more meaningul.
- remove duplicate `getIconByAttr()` in ThemeHelper (use `resolveResourceIdFromAttr()`
- use standard icons for `expand_more` and `expand_less` instead of triangles
- use `play_button_outline` instead of custom PNG as play button in VideoDetailFragment (questionable, as there is no shadow anymore)
This commit is contained in:
Stypox 2020-03-25 16:23:47 +01:00
parent b5f508b309
commit c80aba9a88
758 changed files with 1165 additions and 730 deletions

View file

@ -73,7 +73,7 @@
android:focusable="true"
android:scaleType="fitXY"
android:tint="?attr/colorAccent"
android:src="@drawable/ic_close_white_24dp"
app:srcCompat="@drawable/ic_close_white_24dp"
android:background="?android:selectableItemBackground"
tools:ignore="ContentDescription"/>
@ -106,7 +106,7 @@
android:focusable="true"
android:scaleType="fitXY"
android:tint="?attr/colorAccent"
android:src="@drawable/ic_shuffle_white_24dp"
app:srcCompat="@drawable/ic_shuffle_white_24dp"
android:background="?android:selectableItemBackground"
tools:ignore="ContentDescription,RtlHardcoded"/>
</RelativeLayout>
@ -142,7 +142,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:background="@drawable/player_top_controls_bg"
android:background="@drawable/player_controls_top_background"
android:gravity="top"
android:paddingTop="10dp"
android:paddingBottom="10dp"
@ -237,7 +237,7 @@
android:focusable="true"
android:padding="5dp"
android:scaleType="fitXY"
android:src="@drawable/ic_list_white_24dp"
app:srcCompat="@drawable/ic_list_white_24dp"
android:background="?attr/selectableItemBackground"
tools:ignore="ContentDescription,RtlHardcoded"/>
@ -251,7 +251,7 @@
android:clickable="true"
android:focusable="true"
android:scaleType="fitXY"
android:src="@drawable/ic_expand_more_white_24dp"
app:srcCompat="@drawable/ic_expand_more_white_24dp"
android:background="?attr/selectableItemBackgroundBorderless"
tools:ignore="ContentDescription,RtlHardcoded"/>
</RelativeLayout>
@ -314,7 +314,7 @@
android:focusable="true"
android:padding="5dp"
android:scaleType="fitXY"
android:src="@drawable/ic_cast_white_24dp"
app:srcCompat="@drawable/ic_cast_white_24dp"
android:background="?attr/selectableItemBackground"
android:contentDescription="@string/play_with_kodi_title"
android:visibility="gone"
@ -334,7 +334,7 @@
android:focusable="true"
android:padding="5dp"
android:scaleType="fitXY"
android:src="@drawable/ic_share_white_24dp"
app:srcCompat="@drawable/ic_share_white_24dp"
android:background="?attr/selectableItemBackground"
android:contentDescription="@string/share"
tools:ignore="RtlHardcoded"/>
@ -351,7 +351,7 @@
android:focusable="true"
android:padding="5dp"
android:scaleType="fitXY"
android:src="@drawable/ic_screen_rotation_white"
app:srcCompat="@drawable/ic_screen_rotation_white_24dp"
android:background="?attr/selectableItemBackground"
android:contentDescription="@string/toggle_orientation"
tools:ignore="RtlHardcoded"/>
@ -367,7 +367,7 @@
android:clickable="true"
android:focusable="true"
android:scaleType="fitXY"
android:src="@drawable/ic_fullscreen_exit_white"
app:srcCompat="@drawable/ic_fullscreen_exit_white_24dp"
android:background="?attr/selectableItemBackground"
android:contentDescription="@string/switch_to_popup"
tools:ignore="RtlHardcoded"/>
@ -384,7 +384,7 @@
android:focusable="true"
android:padding="5dp"
android:scaleType="fitXY"
android:src="@drawable/ic_headset_white_24dp"
app:srcCompat="@drawable/ic_headset_white_24dp"
android:background="?attr/selectableItemBackground"
android:contentDescription="@string/switch_to_background"
tools:ignore="RtlHardcoded"/>
@ -401,7 +401,7 @@
android:focusable="true"
android:padding="5dp"
android:scaleType="fitXY"
app:srcCompat="@drawable/ic_volume_off_white_72dp"
app:srcCompat="@drawable/ic_volume_off_white_24dp"
android:background="?attr/selectableItemBackground"
android:contentDescription="@string/switch_to_background"
tools:ignore="RtlHardcoded" />
@ -413,7 +413,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:background="@drawable/player_controls_bg"
android:background="@drawable/player_controls_background"
android:gravity="center"
android:orientation="horizontal"
android:paddingLeft="16dp"
@ -477,7 +477,7 @@
android:focusable="true"
android:background="?attr/selectableItemBackgroundBorderless"
android:scaleType="fitXY"
android:src="@drawable/ic_pause_white"
app:srcCompat="@drawable/ic_pause_white_24dp"
tools:ignore="ContentDescription"/>
<ImageButton
@ -544,7 +544,7 @@
android:background="@drawable/background_oval_black_transparent"
android:visibility="gone"
tools:ignore="ContentDescription"
tools:src="@drawable/ic_action_av_fast_rewind"
tools:src="@drawable/ic_fast_rewind_white_24dp"
tools:visibility="visible" />
</LinearLayout>
@ -597,7 +597,7 @@
android:layout_height="wrap_content"
android:layout_centerInParent="true"
tools:ignore="ContentDescription"
tools:src="@drawable/ic_volume_up_white_72dp" />
tools:src="@drawable/ic_volume_up_white_24dp" />
</RelativeLayout>
<RelativeLayout
@ -623,7 +623,7 @@
android:layout_height="wrap_content"
android:layout_centerInParent="true"
tools:ignore="ContentDescription"
tools:src="@drawable/ic_brightness_high_white_72dp" />
tools:src="@drawable/ic_brightness_high_white_24dp" />
</RelativeLayout>
<TextView