hi,

I have some TextViews that are clickable and focusable and I tried to
set their background with a selector:

<TextView style="@style/tv_style1"/>

<style name="tv_style1">
  <item name="android:layout_width">fill_parent</item>
  <item name="android:layout_height">fill_parent</item>
  <item name="android:clickable">true</item>
  <item name="android:focusable">true</item>
  <item name="android:background">@drawable/tv_bcg_selector</item>
</style>

in file drawable/tv_bcg_selector.xml
<selector xmlns:android="http://schemas.android.com/apk/res/android";>
  <item android:state_selected="true" android:color="#0000FF"/>
  <item android:color="#00FF00"/>
</selector>

but whenever I run the application it stops unexpectedly, I tried to
run with the selector empty and it does run, but not with it filled,
maybe I'm missing something about selectors

thanks

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to