Android Api 21 이상부터 Ripple Effect
를 제공합니다.
효과를 넣어주고 싶은 View
의 Background
속성에 추가해 줍니다.
android:background="?attr/selectableItemBackgroundBorderless"
사용시 부모의 View
까지 Effect 효과가 퍼져 나갑니다.
퍼져나가는 효과의 색상은 Theme
의 colorControlHighlight
를 통해서 변경가능합니다 !
예전에 작성된 Tistory 게시글을 velog로 이전 하였습니다.