On further investigation I found that I has some custom views, and the
onCreate was being called by setContentView, the problem was there.

On Feb 17, 3:49 pm, Mark Murphy <[email protected]> wrote:
> Marc wrote:
> > My feeling was what I did was bad so your comment of
> > "Oh, heavens, please don't do that. You're begging for a memory leak.
> > "
> > is inline with my feeling about what I did. But I am not 100% sure why
> > I would have a memory leak.
>
> Static data members are bad.
>
> Static data members that may hold onto references to activities,
> services, or other components are really bad.
>
> Since each View knows its Activity, unless make absolutely certain you
> null out that static reference, your static View will hold onto the
> Activity forever, or until the process is terminated, whichever comes first.
>
> > The time is almost all spend in the call to setContentView
>
> I find that exceptionally difficult to believe...at least until I read
> the following:
>
> > What I meant by 4 views was 4 layouts. Each layout has several
> > textViews,editTexts,imageButtons,Buttons and a list view. I use the
> > vewFlipper so that I can animate and the switch between screens.
>
> Make them be separate activities, and your performance problem will be
> solved.
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> _Android Programming Tutorials_ Version 1.0 In Print!

-- 
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

Reply via email to