比如可以这样写代码,CardView就变成普通的FrameLayout:
<?xml version="1.0" encoding="utf-8"?> <android.support.v7.widget.CardView xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:card_view="http://schemas.android.com/apk/res-auto" android:layout_width="match_parent" android:layout_height="wrap_content" android:background="?attr/selectableItemBackground" app:cardCornerRadius="0dp" app:cardElevation="0dp" app:cardPreventCornerOverlap="true" app:cardUseCompatPadding="true" card_view:contentPadding="0dp"> </android.support.v7.widget.CardView>
原创文章,作者:Maggie-Hunter,如若转载,请注明出处:https://blog.ytso.com/3137.html