<html>
<body>
Approved!<br><br>
<blockquote type=cite class=cite cite="">Change 20071209-ptw-k by
<a href="mailto:ptw@dueling-banjos.local">ptw@dueling-banjos.local</a> on
2007-12-09<br>
09:32:18 EST<br>
&nbsp;&nbsp;&nbsp;&nbsp; in /Users/ptw/OpenLaszlo/ringding-2<br>
&nbsp;&nbsp;&nbsp;&nbsp; for
<a href="http://svn.openlaszlo.org/openlaszlo/trunk">
http://svn.openlaszlo.org/openlaszlo/trunk</a><br>
&nbsp;<br>
Summary: Fix Sprite memory Leaks<br>
&nbsp;<br>
Bugs Fixed:<br>
LPP-5217 'windows can leak memory<br>
&nbsp;<br>
Technical Reviewer:
<a href="mailto:a.bargull@intensis.de">a.bargull@intensis.de</a>
(pending) QA Reviewer:
<a href="mailto:philip@pbrdev.com">philip@pbrdev.com</a> (pending) Doc
Reviewer: (pending)<br>
&nbsp;<br>
Details:<br>
&nbsp;&nbsp;&nbsp;&nbsp; LzSprite.*:&nbsp; In #destroy set __LZdeleted
flag to prevent events<br>
&nbsp;&nbsp;&nbsp;&nbsp; from resurrecting you.&nbsp; No need for
recursive sprite destruction<br>
&nbsp;&nbsp;&nbsp;&nbsp; now.<br>
&nbsp;<br>
&nbsp;&nbsp;&nbsp;&nbsp; LzIdle: Be careful to create coi Array on
instance, not prototype.<br>
&nbsp;<br>
&nbsp;&nbsp;&nbsp;&nbsp; LzNode: Add comment to explain importance of
__LzDeleted flag.<br>
&nbsp;<br>
&nbsp;&nbsp;&nbsp;&nbsp; LaszloView: Destroy the sprite _before_ you
check for a recursive<br>
&nbsp;&nbsp;&nbsp;&nbsp; call.<br>
&nbsp;<br>
&nbsp;&nbsp;&nbsp;&nbsp; newcontent, scrollingtext: Remove unused id
(that causes a leak).<br>
&nbsp;<br>
Tests:<br>
&nbsp;&nbsp;&nbsp;&nbsp; I modified Phil's test case to only
create/destroy 1 window per<br>
&nbsp;&nbsp;&nbsp;&nbsp; click.&nbsp; The test methodology is:<br>
&nbsp;<br>
&nbsp;&nbsp;&nbsp;&nbsp; 1. Start test<br>
&nbsp;&nbsp;&nbsp;&nbsp; 2. Click twice to create any shared
substrate<br>
&nbsp;&nbsp;&nbsp;&nbsp; 3. Debug.markObjects()<br>
&nbsp;&nbsp;&nbsp;&nbsp; 4. Click once<br>
&nbsp;&nbsp;&nbsp;&nbsp; 5. Debug.findNewObjects()<br>
&nbsp;&nbsp;&nbsp;&nbsp; 6. Debug.whyAlive()<br>
&nbsp;<br>
&nbsp;&nbsp;&nbsp;&nbsp; Result: Before change, many leaked window
sprites.&nbsp; After change, no<br>
&nbsp;&nbsp;&nbsp;&nbsp; leaked window sprites.<br>
&nbsp;<br>
&nbsp;&nbsp;&nbsp;&nbsp; NOTE: There are still some other minor leaks
that I have not<br>
&nbsp;&nbsp;&nbsp;&nbsp; attempted to address here, but will report as a
separate bug.<br>
&nbsp;<br>
Files:<br>
M&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
WEB-INF/lps/lfc/kernel/swf/LzSprite.as<br>
M&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
WEB-INF/lps/lfc/kernel/dhtml/LzSprite.js<br>
M&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
WEB-INF/lps/lfc/kernel/dhtml/LzInputTextSprite.js<br>
M&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
WEB-INF/lps/lfc/kernel/swf9/LzSprite.lzs<br>
M&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; WEB-INF/lps/lfc/services/LzIdle.lzs<br>
M&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; WEB-INF/lps/lfc/core/LzNode.lzs<br>
M&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; WEB-INF/lps/lfc/views/LaszloView.lzs<br>
M&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
lps/components/debugger/newcontent.lzx<br>
M&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
lps/components/debugger/scrollingtext.lzx<br>
&nbsp;<br>
Changeset:
<a href="http://svn.openlaszlo.org/openlaszlo/patches/20071209-ptw-k.tar">
http://svn.openlaszlo.org/openlaszlo/patches/20071209-ptw-k.tar</a>
</blockquote></body>
</html>