Merge pull request #2662 from deltachat/adb/webxdc-rounded-corners

set rounded corners for webxdc app icons
This commit is contained in:
Asiel Díaz Benítez
2023-09-25 14:49:48 +02:00
committed by GitHub
3 changed files with 12 additions and 4 deletions
+4 -2
View File
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<merge xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
xmlns:app="http://schemas.android.com/apk/res-auto"
tools:context="org.thoughtcrime.securesms.components.WebxdcView">
<LinearLayout android:id="@+id/webxdc_container"
@@ -11,14 +12,15 @@
android:gravity="center_vertical"
android:orientation="horizontal">
<androidx.appcompat.widget.AppCompatImageView
<com.google.android.material.imageview.ShapeableImageView
android:id="@+id/webxdc_icon"
android:padding="4dp"
android:layout_width="40dp"
android:layout_height="40dp"
android:layout_marginLeft="5dp"
android:layout_marginRight="5dp"
android:scaleType="centerCrop"/>
android:scaleType="centerCrop"
app:shapeAppearanceOverlay="@style/ShapeAppearanceOverlay.App.CornerSize10Percent" />
<LinearLayout android:layout_width="match_parent"
android:layout_height="wrap_content"
+5 -2
View File
@@ -12,12 +12,15 @@
android:gravity="center_vertical"
android:orientation="vertical">
<androidx.appcompat.widget.AppCompatImageView
<!-- android:padding="0.1dp" is needed to remove transparent background -->
<com.google.android.material.imageview.ShapeableImageView
android:id="@+id/webxdc_icon"
android:padding="0.1dp"
android:layout_marginTop="2dp"
android:layout_width="128dp"
android:layout_height="128dp"
android:scaleType="centerCrop"/>
android:scaleType="centerCrop"
app:shapeAppearanceOverlay="@style/ShapeAppearanceOverlay.App.CornerSize10Percent" />
<TextView android:id="@+id/webxdc_app_name"
android:layout_width="match_parent"
+3
View File
@@ -113,4 +113,7 @@
<item name="colorControlActivated">#ff2090ea</item>
</style>
<style name="ShapeAppearanceOverlay.App.CornerSize10Percent" parent="">
<item name="cornerSize">7%</item>
</style>
</resources>