关于Android ListView组件中android:drawSelectorOnTop含义
When set to true, the selector will be drawn over the selected item. Otherwise the selector is drawn behind the selected item. The default value is false.
android:drawSelectorOnTop="true" 点击某一条记录,颜色会显示在最上面,记录上的文字被遮住,所以点击文字不放,文字就看不到
android:drawSelectorOnTop="false" 点击某条记录不放,颜色会在记录的后面,成为背景色,但是记录内容的文字是可见的
本文详细介绍了Android ListView中android:drawSelectorOnTop属性的作用。该属性设置为true时,选择器的颜色会覆盖在选中项之上,可能导致文字被遮挡;设置为false时,选择器颜色作为背景置于内容之下,确保文字始终可见。

309

被折叠的 条评论
为什么被折叠?



