开发者

Getting orange highlight color in the padding space of gridView on click

开发者 https://www.devze.com 2023-02-12 18:39 出处:网络
I am getting a orange highlight color in the GridView, when i press it. As I have specified the padding, this highlight appears in that a开发者_开发知识库rea.

I am getting a orange highlight color in the GridView, when i press it. As I have specified the padding, this highlight appears in that a开发者_开发知识库rea.

Can somebody please help me to know, how to avoid it?

I have used OnKeyDown event for the GridView, but call does not comes to that. As such the adapter provides images for the region which is left without the padding.


Wanted to add a non-link answer:

In the xml for the gridView, add the following attribute

android:listSelector="@android:color/transparent"

That will make the selected state color of the gridView transparent, and will, in effect remove the orange highlighting.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号