2017-03-13 2 views
0

나는 Switch에 대한 사용자 정의 드로어 블을 생성하지만 적용 할 때 그것은 다음과 같습니다 android:drawableRight="@drawable/switch_selector"를 사용하여 항목을 전환 : enter image description here enter image description here안드로이드 기본 당김 하나

어떻게 그 기본보기 없애? 누구든지 나를 도울 수 있습니까? 미리 감사드립니다!

답변

1

Android Switch의 경우 각 부품에 Drawable을 설정해야합니다. 첫 번째 부분은 왼쪽에서 오른쪽으로 이동하는 Drawable 인 android:thumb입니다. enter image description here 두 번째 부분은 android:thumb이 슬라이드되는 Drawable 인 android:track입니다. enter image description here 애니메이션이 없어도 기본보기를 제거하는 android:thumbTint="@color/transparentandroid:trackTint="@color/transparent을 설정할 수 있습니다.