Skip to content

Commit

Permalink
bug: 修复ripple在低版本不兼容的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
Lesion committed Jul 25, 2022
1 parent f1d445d commit 20acc80
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 16 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:color="#ffffff"
tools:ignore="NewApi">
<item android:drawable="@drawable/image_edit_click_ripple"/>
</ripple>
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<solid android:color="@color/image_editor_main_backgroud" />
<corners android:radius="2dp" />
</shape>
10 changes: 5 additions & 5 deletions imageeditlibrary/src/main/res/drawable/image_edit_ripple.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
<selector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:color="#ffffff"
tools:ignore="NewApi">
<item android:drawable="@drawable/image_edit_click_ripple"/>
</ripple>
android:color="#ffffff">
<item android:drawable="@drawable/image_edit_click_ripple" android:state_pressed="true"/>
<item android:drawable="@drawable/image_edit_click_ripple_normal"/>
</selector>

This file was deleted.

1 change: 1 addition & 0 deletions imageeditlibrary/src/main/res/values/colors.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<resources>
<color name="image_editor_white">#ffffff</color>
<color name="image_editor_main_backgroud">#4f000000</color>
<color name="image_editor_main_backgroud_normal">#33000000</color>
<color name="image_editor_materialcolorpicker__white">#ffffff</color>
<color name="image_editor_materialcolorpicker__red">#f44336</color>
<color name="image_editor_materialcolorpicker__green">#4caf50</color>
Expand Down

0 comments on commit 20acc80

Please sign in to comment.