|
On Wed, Mar 18, 2015 at 03:58:13PM -0700, Eliot Miranda wrote:
> Hi All,
>
> if one looks at UIManager default toolBuilder one sees the widgets
> dictionary inside the tool builder can hold onto garbage. It would be nice
> if the widgets were cleaned out when ToolBuilder is done opening. Where's
> the right point to do this?
At first glance, I'm inclined to think that the garbage collector should
do it.
The current Project has a UIManager, and that UIManager has a ToolBuilder.
But I don't see an obvious reason why a UIManager needs to have a dedicated
instance of ToolBuilder, as opposed to creating new instances as needed.
Maybe there is some reason that it needs to be set up this way, but my
first inclination would be to see if we can get rid of the toolBuilder
instance variable in UIManager, after which the garbage in the widget
registry would take care of itself.
Dave
|