[android-developers] Re: Using Custom buttons. *Help*

2012-02-23 Thread Jaison Brooks
Thank you for the quick response and the link. It did help me out
figuring out what I need to do.
-Thanks again

On Feb 23, 7:49 am, Kookamonga  wrote:
> This may 
> help:http://groups.google.com/group/android-developers/browse_thread/threa...
>
> It sounds like you need the images in both /drawable and /drawable-
> ldpi (at different resolutions, of course) and the system itself will
> pick the appropriate icon.
>
> On Feb 23, 12:49 am, Jaison Brooks  wrote:
>
>
>
> > I am working on using a few custom 9patch buttons I've created for my
> > app. I'm having troubles find the best way to do this. I have created
> > 3 versions if each button for my ldpi mdpi and hdpi folders. Each
> > button has the same name and there is no mix up. And from what I've
> > research. I created a new xml file name mybuttonbackground.xml with my
> > code for when the button is normal, pressed and focused. But in this
> > xml file my code is having errors with the resources .
> > Example:
>
> > The error is here " @android:drawable/
> > grey_button_background_pressed_blue"
> > And is the same for each line where I reference the PNG reference.
> > I know u could just place the 3 button PNGs in the main drawable
> > folder and fix it. But I want to have the density folder the android
> > system will use for high or low density resolutions. Can someone help
> > me re write this or give me the proper way to do this in my
> > buttonbackground xml file.
>
> >    > xmlns:android="http://schemas.android.com/apk/res/android";>  > android:state_focused="true" android:state_pressed="false"
> > android:drawable="@android:drawable/
> > grey_button_background_focus_blue" />  > android:state_focused="true" android:state_pressed="true"
> > android:drawable="@android:drawable/
> > grey_button_background_pressed_blue" />  > android:state_focused="false" android:state_pressed="true"
> > android:drawable="@android:drawable/
> > grey_button_background_pressed_blue" />  > android:drawable="@android:drawable/grey_button_background_normal" />
> > 

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


[android-developers] Re: Using Custom buttons. *Help*

2012-02-23 Thread Kookamonga
This may help: 
http://groups.google.com/group/android-developers/browse_thread/thread/bedff1b9bbfdd9f3

It sounds like you need the images in both /drawable and /drawable-
ldpi (at different resolutions, of course) and the system itself will
pick the appropriate icon.

On Feb 23, 12:49 am, Jaison Brooks  wrote:
> I am working on using a few custom 9patch buttons I've created for my
> app. I'm having troubles find the best way to do this. I have created
> 3 versions if each button for my ldpi mdpi and hdpi folders. Each
> button has the same name and there is no mix up. And from what I've
> research. I created a new xml file name mybuttonbackground.xml with my
> code for when the button is normal, pressed and focused. But in this
> xml file my code is having errors with the resources .
> Example:
>
> The error is here " @android:drawable/
> grey_button_background_pressed_blue"
> And is the same for each line where I reference the PNG reference.
> I know u could just place the 3 button PNGs in the main drawable
> folder and fix it. But I want to have the density folder the android
> system will use for high or low density resolutions. Can someone help
> me re write this or give me the proper way to do this in my
> buttonbackground xml file.
>
>    xmlns:android="http://schemas.android.com/apk/res/android";>  android:state_focused="true" android:state_pressed="false"
> android:drawable="@android:drawable/
> grey_button_background_focus_blue" />  android:state_focused="true" android:state_pressed="true"
> android:drawable="@android:drawable/
> grey_button_background_pressed_blue" />  android:state_focused="false" android:state_pressed="true"
> android:drawable="@android:drawable/
> grey_button_background_pressed_blue" />  android:drawable="@android:drawable/grey_button_background_normal" />
> 

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