MartinWittemann wrote: > > What I don't like at the whole idea that the container should destroy > objects he did not create. Usually, the object creating another objects is > responsible for destroying them. With that in mind, i think that a > removeAll including a destroy all could be done in the client code with a > couple of lines: > > var children = container.getChildren(); > container.removeAll(); > qx.util.DisposeUtil.disposeArray(children); > > But i have to admit that removeAll should return an array containing all > returned children. That would make it to a single line of code. > > qx.util.DisposeUtil.disposeArray(container.removeAll()); > > What do you think about such a solution? That way, the dispose is kept at > its place and its still a pretty nice API. >
That seems fine. It would also be great to have an additional page somewhere in the QooxDoo documentation outlining best practices for memory management, including coverage of IE's peculiarities and existing tools for tracking down leaks. Chrome's heap analyzer seems like the only reasonable tool out there right now, but I notice that dynaTrace Ajax has memory profiling on the list for the next release -- so maybe that will become another useful tool. Dave -- View this message in context: http://qooxdoo.678.n2.nabble.com/Reclaiming-memory-from-widgets-tp5764047p5770535.html Sent from the qooxdoo mailing list archive at Nabble.com. ------------------------------------------------------------------------------ Increase Visibility of Your 3D Game App & Earn a Chance To Win $500! Tap into the largest installed PC base & get more eyes on your game by optimizing for Intel(R) Graphics Technology. Get started today with the Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs. http://p.sf.net/sfu/intelisp-dev2dev _______________________________________________ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
