Nick Owens wrote:
> I'm wondering if there's any way to switch out the application icon the main
> category, when the focus scrolls over it.  I'm not sure if I could send a
> screenshot through this user group; if I could, you would see that our
> design guys in their infinite wisdom chose Droid Hover orange as the logo
> color.  When not hovered on, it looks like a series of orange swoops.  But
> when hovered, it looks exactly like an orange square!  Crap, crappity crap
> crap, help me please!

I haven't tried using a StateListDrawable for the application icon,
though it might work.

You'd have something like:

<selector xmlns:android="http://schemas.android.com/apk/res/android";>
        <item
                android:state_focused="true"
                android:drawable="@drawable/icon_focused"
        />
        <item
                android:drawable="@drawable/icon"
        />
</selector>

in res/drawable/the_real_icon.xml, and reference that in your manifest.
Then, have two PNGs, one for the unfocused icon and one that will be
used when it's focused.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://twitter.com/commonsguy

Android 2.0 Programming Books: http://commonsware.com/books

-- 
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