Hi Diane, I took your suggestion and changed our configChanges from:
android:configChanges="keyboardHidden" to android:configChanges="keyboardHidden|orientation" And that solved the problem. Now when one of those popups shows up overtop of our app we get rotated, but we don't get destroyed. The problem was definitely weird though in that in my onPause() method it was as if I had already been detroyed, or was in the process of being recreated or something, everything I wanted to pause was already null. It certainly could be my fault, but I couldn't figure out why it was happening. Thanks for the help though, this stops the worst effects of the error. Matt On Mar 10, 5:43 pm, Dianne Hackborn <[email protected]> wrote: > I am having a little trouble understanding what you are describing -- I > don't see how your own variables can suddenly become null; unless something > really wacky is going on, you are either clearing them somewhere, or you > have a different instance of the activity that didn't initialize them. For > the latter, there could be an issue with the activity being restarted > because the orientation is changing; if you are forcing a particular > orientation, you might want to use android:configChanges="orientation" in > your manifest to prevent the activity from being restarted due to an > orientation change. (In theory when we do this transition it shouldn't see > the orientation change that is going on, but there could certainly be bugs > in some situations causing it to be restarted.) > > > > > > On Tue, Mar 10, 2009 at 12:35 PM, Matt Hall <[email protected]> wrote: > > > Just adding some more info here for any who follow - this only happens > > in one of our games, and the major difference is that the game with > > the problem has it's screen orientation locked to landscape mode. > > Since the home screen intent view appears in portrait orientation I > > suspect this is causing the problem somehow. We still should be > > receiving a proper onPause() before being killed, but maybe because > > we've requested a permanent landscape mode these events aren't being > > triggered properly. > > > Matt > > > On Mar 10, 3:22 pm, Matt Hall <[email protected]> wrote: > > > Hi everyone, > > > > When we're in inPause() in our games we do a few things like stop > > > animations, which normally works perfectly. However, when an app is > > > installed on the phone that causes an intent popup, like a home screen > > > replacement (aHome is what I'm using to test), then in the onPause() > > > suddenly our field variables are null and our game null pointers when > > > trying to stop the animations. As a nasty side effect, this causes a > > > force close loop between our game and the intent handling window. > > > > Has anyone else seen this? For now I'm going to catch and ignore that > > > null pointer, but from the activity life cycle information this > > > situation makes no sense to me. > > > > Thanks very much for any help/info, > > > Matt > > -- > 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. 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 -~----------~----~----~----~------~----~------~--~---

