[cc'ing John, who IIRC wrote the resizable widgets]

That does indeed sound like a bad thing. At the very least, it would be
important to get that list cleared out so that it's not growing without
bound. And yes, onLoad/onUnload would be the right time to do it.

I'm also curious about your usage of these widgets. Are they used in such a
way that it would be relatively easy to hook the window's resize event and
iterate over them to give them a chance to resize? And do you think that
would be sufficient to capture the times when they actually *need* to
resize? I ask because I've always been slightly uncomfortable with the idea
of resizing based upon a timer, but there's no better way to do so in the
general case -- because any change to the DOM, text, CSS, or what have you
can, in theory, cause a widget to resize. But I'm wondering if providing
somewhat more limited semantics (along the lines of "this widget needs to be
told when its size changes, but it's up to the application to do so") would
allow us to get rid of the timers altogether.

Cheers,
joel.

On Thu, Mar 5, 2009 at 3:33 AM, stuckagain <[email protected]> wrote:

>
> GWT Incubator People,
>
> Since I don't know where to start a discussion on design decisions for
> the incubator, I'll do it here.
>
> There is a fundamental problem in incubator that leads to memory leaks
> and reduced performance.
>
> For example the ScrollTable (now in AbstractScrollTable) and
> ProgressBar add themselfs to the ResizableWidgetCollection in the
> constructor.
>
> The problem is that they are NEVER removed.
>
> Would'nt it be beter that these kind of components only add to the
> ResizableWidgetCollection in the onLoad and remove automatically in
> the onUnload ?
>
> We are using Progress Bars in Tables and many ScrollTables as well.
> Every time that table is reconstructed, the memory usage increases.
> After some time we also notice that the CPU usage goes up even when
> the user is not doing anything.
>
> David
> >
>

--~--~---------~--~----~------------~-------~--~----~
http://groups.google.com/group/Google-Web-Toolkit-Contributors
-~----------~----~----~----~------~----~------~--~---

Reply via email to