Android Question CheckList Class by Informatix - Question about Color

adriano.freitas

Active Member
Hi!

Before my doubts, I would like to congratulate and thank @Informatix for the contribution given through its CheckList library.

I have a question that I think is simple, but I haven't been able to solve it yet.

When using the list with checkboxes when pressing on an item or even a longpress, it is marked in orange. The application that I'm producing and that uses the class has another color pattern. I would like to know how to change this orange color...

Thank you very much!
 

DonManfred

Expert
Licensed User
Longtime User
The Class is a class (means the source is available).
Adapt it to your needs
 
Upvote 0

asales

Well-Known Member
Licensed User
Longtime User
As DonManfred said, you can change the source code.

Try to change this line:
B4X:
PressedDrawable = r.RunMethod2("getDrawable", ID_PressedDrawable, "java.lang.int")
to this
B4X:
Dim cd As ColorDrawable
cd.Initialize(Colors.Yellow, 0)
        
PressedDrawable = cd
 
Upvote 0

adriano.freitas

Active Member
Hi! Thank you all for your attention to me. I know I can (and should) adapt classes, however, I'm new here and I've been using B4X, B4A for a very short time, I come from other language structures, which makes some details still strange to me and often despite simple for those who already know, for me sometimes I lose hours or days trying. B4X is great, @Erel is fantastic and you guys who help beginners are wonderful. Thank you very much!
 
Upvote 0
Top