Fixed
Status Update
Comments
he...@gmail.com <he...@gmail.com> #2
After couple of hours trying to fix this I finally got a solution for this problem.
I made it with the style attribute android:dropDownListViewStyle. Therefore I used a ListView style with a custom listSelector:
styles.xml:
<resources>
<style name="Theme.MyTheme" parent="@android:style/Theme.Holo.Light">
<item name="android:dropDownListViewStyle">@style/Theme.MyListView</item>
</style>
<style name="Theme.MyListView" parent="@android:style/Widget.Holo.Light.ListView">
<item name="android:listSelector">@drawable/orange_list</item>
</style>
</resources>
orange_list.xml:
<selector xmlns:android="http://schemas.android.com/apk/res/android ">
<item android:state_pressed="true" android:drawable="@color/light_orange" />
<item android:state_activated="true" android:drawable="@color/light_orange" />
<item android:state_selected="true" android:drawable="@color/light_grey" />
</selector>
I made it with the style attribute android:dropDownListViewStyle. Therefore I used a ListView style with a custom listSelector:
styles.xml:
<resources>
<style name="Theme.MyTheme" parent="@android:style/Theme.Holo.Light">
<item name="android:dropDownListViewStyle">@style/Theme.MyListView</item>
</style>
<style name="Theme.MyListView" parent="@android:style/Widget.Holo.Light.ListView">
<item name="android:listSelector">@drawable/orange_list</item>
</style>
</resources>
orange_list.xml:
<selector xmlns:android="
<item android:state_pressed="true" android:drawable="@color/light_orange" />
<item android:state_activated="true" android:drawable="@color/light_orange" />
<item android:state_selected="true" android:drawable="@color/light_grey" />
</selector>
od...@gmail.com <od...@gmail.com> #3
I ran into this problem twice... :)
I have inspected the android 4.2 source code of the Spinner class and guess what: the only usage of android:dropDownSelector is a mention in the comments.
I have inspected the android 4.2 source code of the Spinner class and guess what: the only usage of android:dropDownSelector is a mention in the comments.
al...@android.com <al...@android.com> #4
Confirmed that Spinner still does not correctly apply this attribute.
hu...@gmail.com <hu...@gmail.com> #5
it does not work
[Deleted User] <[Deleted User]> #6
what's the point of having an attribute for more than 3 years that does nothing?
no...@gmail.com <no...@gmail.com> #7
I think al... was fired.
os...@gmail.com <os...@gmail.com> #8
al...@android.com <al...@android.com>
da...@gmail.com <da...@gmail.com> #9
I read your full article. This is a very impotent topic. I’m really loving your <strong><a href="https://sellshop.com.bd/seo-tools/ "><em>blog</em></a></strong>.
I have a very small blog. There I try to write something similar. Please visit <strong><em><a href="https://sellshop.com.bd/link-spinner/ ">my site</a></em></strong> & do you have any suggestions.
I have a very small blog. There I try to write something similar. Please visit <strong><em><a href="
ku...@gmail.com <ku...@gmail.com> #10
The dropdownSelector still does nothing in 2023 ... and yet it's marked as fixed in 2016. Well done.
Description
while developing Android applications. Use the Tools templates for issues
with the developer tools.
Please describe the problem in detail. Be sure to include:
- Steps to reproduce the problem (including sample code if appropriate).
Attempt to apply a style to the Selector, that includes a valid value for the android:dropDownSelector attribute.
- What happened.
The value is not applied in the ctor. Looking at the source, the path for Selectors of type "dropdown" does not contain any code to obtain the value from android:dropDownSelector.
- What you think the correct behavior should be.
The value should be correctly applied.
Don't forget to mention which version of Android you're using, and/or which device the problem appears on (model and Android version).
ICS 4.0.2
Please also run "adb bugreport" and archive the output.