feat: 容器统一加灰色边框,borderCornerRadius 属性统一管理圆角
创建通用灰色边框 drawable(5 模块各一份):
- bg_container_border.xml:透明填充 + 1dp #B0B0B0 描边
- 自动应用到 80 个无背景容器的布局文件
深色模式 bg_frame 加边框:
- drawable-night/bg_frame.xml(mymessagemanager + aes):
背景 shape 添加 1dp #666666 描边,保留渐变蒙版
统一圆角为 6dp(borderCornerRadius 属性化):
- 5 模块 attrs.xml 声明 borderCornerRadius(dimension)
- 12 个主题(6 普通 + 6 深色)设置 borderCornerRadius=6dp
- 12 个 drawable 文件约 40 处 corners 改用 ?attr/borderCornerRadius
(bg_frame / bg_frame_black/white / bg_shadow / bg_border_round
bg_toolbar_log / acard_frame_main / atoolbar_frame / ohpcts_frame
bg_container_border 等)
- 3 个 Java 自定义控件(AToolbar / ASupportToolbar / AboutView)
从硬编码 px 改为读取 ?attr/borderCornerRadius
受益布局模块:libaes / libappbase / appbase / mymessagemanager / aes / winboll
This commit is contained in:
@@ -10,11 +10,7 @@
|
||||
android:angle="270"
|
||||
android:endColor="#0F000000"
|
||||
android:startColor="#0F000000" />
|
||||
<corners
|
||||
android:bottomLeftRadius="6dip"
|
||||
android:bottomRightRadius="6dip"
|
||||
android:topLeftRadius="6dip"
|
||||
android:topRightRadius="6dip" />
|
||||
<corners android:radius="?attr/borderCornerRadius" />
|
||||
</shape>
|
||||
</item>
|
||||
<item
|
||||
@@ -27,11 +23,10 @@
|
||||
android:angle="270"
|
||||
android:endColor="#00000000"
|
||||
android:startColor="#1AFFFFFF" />
|
||||
<corners
|
||||
android:bottomLeftRadius="6dip"
|
||||
android:bottomRightRadius="6dip"
|
||||
android:topLeftRadius="6dip"
|
||||
android:topRightRadius="6dip" />
|
||||
<stroke
|
||||
android:width="1dp"
|
||||
android:color="#FF666666" />
|
||||
<corners android:radius="?attr/borderCornerRadius" />
|
||||
</shape>
|
||||
</item>
|
||||
</layer-list>
|
||||
|
||||
@@ -12,11 +12,7 @@
|
||||
android:angle="270"
|
||||
android:endColor="#0F000000"
|
||||
android:startColor="#0F000000" />
|
||||
<corners
|
||||
android:bottomLeftRadius="6dip"
|
||||
android:bottomRightRadius="6dip"
|
||||
android:topLeftRadius="6dip"
|
||||
android:topRightRadius="6dip" />
|
||||
<corners android:radius="?attr/borderCornerRadius" />
|
||||
</shape>
|
||||
</item>
|
||||
<!-- 背景部分 -->
|
||||
@@ -31,11 +27,7 @@
|
||||
android:angle="270"
|
||||
android:endColor="#0FFFFFFF"
|
||||
android:startColor="#FFFFFFFF" />
|
||||
<corners
|
||||
android:bottomLeftRadius="6dip"
|
||||
android:bottomRightRadius="6dip"
|
||||
android:topLeftRadius="6dip"
|
||||
android:topRightRadius="6dip" />
|
||||
<corners android:radius="?attr/borderCornerRadius" />
|
||||
</shape>
|
||||
</item>
|
||||
</layer-list>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:orientation="vertical"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
android:layout_height="match_parent" android:background="@drawable/bg_container_border">
|
||||
|
||||
<cc.winboll.studio.libaes.views.ASupportToolbar
|
||||
android:layout_width="match_parent"
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:orientation="vertical"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
android:layout_height="match_parent" android:background="@drawable/bg_container_border">
|
||||
|
||||
<cc.winboll.studio.libaes.views.ADsControlView
|
||||
android:id="@+id/ads_control_view"
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:orientation="vertical"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
android:layout_height="match_parent" android:background="@drawable/bg_container_border">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
|
||||
Reference in New Issue
Block a user