Kent Olsson schrieb:
win is a window. Does the following function
win.close();
clean up the memory by
doc.remove(win);
and thereafter
dispose of the win component, or do I have to do the following:
doc.add(win);
win.open();
win.close()
doc.remove(win);
win.dispose();
win = null;
to complete the cycle? Actually I think it should be built-into the
widgets QxWindow, QxFrame and QxDialog if a property like dynamicMemory
in the QxWidget class is set to true. After testing myself I can see
that the total performance does not change, it actually adds a little
bit, but it is spread in time and the user feels less delay at running.
Additionally, startup time of the application and possibly the class
library will be shorter.
the first two lines (add and open) do you need in both cases. These have
not to do anything with the later dispose job.
To complete the cycle (after a close) you can also dispose a window, if
you are really sure, that you don't need it anymore. The problem in this
case is, that JS itself has no possibilities to do a real garbage
collection. The only thing the qooxdoo disposer do, is to decouple
objects and html nodes from each other to allow the (buggy) garbage
collector to do its work (generally after leaving the page). So if you
open many QxWindows and dispose them (like for simple confirm dialogs)
it would be probably the best the reuse them. Otherwise the memory used
by the browser will grow and grow until you leave the page or there is
another event which starts the garbage collector.
Sebastian
Kent
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
Qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
Qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel