我想要为我的 ImageView 添加原生圆形波纹效果。我使用了“selectableItemBackgroundBorderless”,但波纹效果出现在方框中。检查下面的代码以供引用。提前致谢!!
<ImageView
android:id="@+id/ivAnswerListDownVote"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="@dimen/dp_8"
android:clickable="true"
android:focusable="true"
android:foreground="?attr/selectableItemBackgroundBorderless"
android:src="@drawable/ic_outline_thumb_down_alt_24"
tools:targetApi="m" />
最佳答案
你应该使用
android:background="?attr/selectableItemBackgroundBorderless"
关于android - ImageView 的原生圆形波纹效果,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/64151294/