Skip to content

Instantly share code, notes, and snippets.

@yccheok
Created May 14, 2017 11:04
Show Gist options
  • Save yccheok/d0ea895635febe00709b4f02acfa3d96 to your computer and use it in GitHub Desktop.
Save yccheok/d0ea895635febe00709b4f02acfa3d96 to your computer and use it in GitHub Desktop.
This is how we can customize the card's corners
<?xml version="1.0" encoding="utf-8"?>
<selector android:shape="rectangle"
xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_pressed="true">
<shape>
<corners android:topLeftRadius="0.0dip" android:topRightRadius="0.0dip" android:bottomLeftRadius="@dimen/cardview_default_radius" android:bottomRightRadius="@dimen/cardview_default_radius" />
<solid android:color="@color/pressed_black" />
</shape>
</item>
<item>
<shape android:shape="rectangle">
<corners android:topLeftRadius="0.0dip" android:topRightRadius="0.0dip" android:bottomLeftRadius="@dimen/cardview_default_radius" android:bottomRightRadius="@dimen/cardview_default_radius" />
<solid android:color="@color/rh_white_1" />
</shape>
</item>
</selector>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment