Yes the actual dimensions available to your app are not known until View.onSizeCreated() or SurfaceHolder.Callback.surfaceCreated().
On Wed, May 18, 2011 at 3:26 PM, Leigh McRae <[email protected] > wrote: > Hi, > > My game isn't handling Honeycomb correctly it seems. I get the > DisplayMetrics in Activity.onCreate and setup my game expecting to be > able to use the full screen. So I'm guessing that I need to go > through the process of creating a View and getting it's size in order > for it to work on Honeycomb. > > The problem is, from what I'm seeing, is that the view isn't created > and fully measured until sometime after Activity.onResume. The first > shot I get at it with valid dimensions is in my > SurfaceHolder.Callback. Right now my game is setup to pretty much > have a one to one mapping of the Android Activity lifecycle and I need > my screen size pretty early on. Is there anyway around this? All I > can think to do is not create my app until the first time the surface > is created. > > -- > 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 > -- Dianne Hackborn Android framework engineer [email protected] Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- 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

