HorizontalVariableListView icon indicating copy to clipboard operation
HorizontalVariableListView copied to clipboard

How to set cell selected colour?

Open bencallis opened this issue 11 years ago • 4 comments

I am having trouble setting the cell selected colour.

I have tried in XML by setting the listSelector attribute as follows:

        android:listSelector="@drawable/selected_background"

The selected_background is a simple shape containing a solid colour

Unfortunately the item selected colour is still the standard Holo Light blue.

It seems in the standard ListView there is a setSelector method. However, this does not seem to be included in the HVLV.

I must be missing something very simple.... :)

bencallis avatar Jul 28 '13 23:07 bencallis

This seems to be a problem I'm encountering as well.

Wavesonics avatar Dec 03 '13 01:12 Wavesonics

I'm having this problem too. Is there any workaround?

AndroidDeveloperLB avatar Mar 17 '14 11:03 AndroidDeveloperLB

Is the default selector color yellow?

premnirmal avatar May 30 '14 18:05 premnirmal

if anyone reads this, you can set the selector programmatically with .setSelector(Int ResId) it.sephiroth.android.library.widget.HListView hListView = (it.sephiroth.android.library.widget.HListView) findViewById(R.id.myHorizontalListView); hListView.setSelector(R.drawable.mySelector); Cheers

ObjectiveTruth avatar Aug 17 '14 17:08 ObjectiveTruth