[android-developers] Re: ToggleButton image

2010-02-21 Thread scastria
I found a way that works perfectly! 1. Use a regular ToggleButton 2. Set your desired drawable on the toggle button using either drawable_top or drawable_bottom. Don't use left or right as the image won't be centered. 3. Now, you have both the text and an image. I just wanted the image so I

[android-developers] Simple LinearLayout Question

2010-01-31 Thread scastria
Maybe I am missing something here: I have a simple horizontal LinearLayout with fill_parent set containing 3 TextViews inside it. I have set each of the TextViews to have 1.0 weight. My goal was to get each TextView to take up 33% of the LinearLayout. This sort of works, but the TextView sizes

[android-developers] Problem with TabHost

2010-01-30 Thread scastria
I have followed the ApiDemos example in Tabs1 where the tab content is inflated at runtime with code and a TabActivity is used. Everything works except when the TabActivity becomes active, I can see the content of both tabs at the same time overlaying each other. All of my tab content has

[android-developers] Re: Problem with TabHost

2010-01-30 Thread scastria
it several different ways until I find something that works. I am a very experienced Swing developer so I should know what I am doing. I am hoping it is just that the android SDK is still in its infancy and has some bugs to work out? On Jan 30, 7:50 pm, scastria scastria...@gmail.com wrote: I

[android-developers] Builtin layout xml source code?

2010-01-30 Thread scastria
Anyway to see the source xml for android.R.layout.simple_expandable_list_item_2 ?? -- 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,

[android-developers] Confusion with activity stack and restoring state

2010-01-10 Thread scastria
I have a start activity page for my game (which is the root activity for my app) that just lists Play, Help, and About TextViews on the screen. Each TextView has a click listener which start the appropriate Activity for each. The GameActivity (started with explicit intent from clicking Play) has

[android-developers] Detect finger going off screen?

2010-01-03 Thread scastria
I have a motion listener to detect finger down, finger drag, and finger up. I start my action at finger down and finish my action at finger up. When the action is finished, I store it in a stack for allowing undo. My problem is that if I don't get a finger up event, I can't finish my action to

[android-developers] Re: Detect finger going off screen?

2010-01-03 Thread scastria
preference is to receive ACTION_UP events (as I am currently getting) when the finger leaves the screen, so great! On Jan 3, 2:31 am, Romain Guy romain...@android.com wrote: You should receive an ACTION_CANCEL if that happens. On Sun, Jan 3, 2010 at 12:27 AM, scastria scastria...@gmail.com wrote: I

[android-developers] Has anyone written a 2D scene graph yet?

2010-01-01 Thread scastria
I am struggling with drawing on my custom View. I can make it all work but just not very efficiently. I am using invalidate causing the entire screen to be redrawn. I only need to redraw a small portion of the screen. I tried calling invalidate with a rectangle but that left everything else black.

[android-developers] visual layout designer crashing

2009-03-03 Thread scastria
I had problems with the eclipse visual layout designer crashing with 1.0_r2 and the same thing with 1.1_r1. Everything works fine when I create a brand new project, but as soon as I save and exit and come back, I always get this crash below. Any help would be much appreciated.