Problem with 9-patch in <selector> drawable for button

Put problem concerning Views, Layouts and other XML-Resources (like AndroidManifest) here.

Problem with 9-patch in <selector> drawable for button

Postby EveningNewbs » Sun Nov 29, 2009 12:44 am

Hi guys,

I'm having a bit of a problem with a custom button style. I have the button states (9-patch drawables) set up in a <selector> drawable. The style I'm going for is a button that looks like it gets pushed down, i.e., you can see the front edge of the button until you press it. It works fine for the button itself, but the contents of the Button or ImageButton don't move when pressed, even though I have the 9-patch areas set up to move the content area for the depressed button states. It seems like it's keeping the same 9-patch areas no matter which image it's showing.

Here's an animated GIF to help make the problem a little clearer:
Image

Thanks in advance!
EveningNewbs
Junior Developer
Junior Developer
 
Posts: 14
Joined: Mon Nov 17, 2008 4:27 pm

Top

Return to View, Layout & Resource Problems

Who is online

Users browsing this forum: No registered users and 6 guests