[Laszlo-checkins] r11752 - openlaszlo/trunk/WEB-INF/lps/lfc/kernel/swf9

max@openlaszlo.org max at openlaszlo.org
Thu Nov 13 07:30:38 PST 2008


Author: max
Date: 2008-11-13 07:30:37 -0800 (Thu, 13 Nov 2008)
New Revision: 11752

Modified:
   openlaszlo/trunk/WEB-INF/lps/lfc/kernel/swf9/LzSprite.as
Log:
Change 20081112-maxcarlson-j by maxcarlson at Bank.local on 2008-11-12 15:39:33 PST
    in /Users/maxcarlson/openlaszlo/trunk-clean
    for http://svn.openlaszlo.org/openlaszlo/trunk

Summary: Fix sendInFrontOf() in swf9

Bugs Fixed: LPP-7321 - sendInFrontOf() works once well, and second wrong, third well, and so on...

Technical Reviewer: hminsky
QA Reviewer: promanik

Details: Test to make sure the sprite is behind the current one before bringing to the front.

Tests: See LPP-7321.



Modified: openlaszlo/trunk/WEB-INF/lps/lfc/kernel/swf9/LzSprite.as
===================================================================
--- openlaszlo/trunk/WEB-INF/lps/lfc/kernel/swf9/LzSprite.as	2008-11-13 15:29:35 UTC (rev 11751)
+++ openlaszlo/trunk/WEB-INF/lps/lfc/kernel/swf9/LzSprite.as	2008-11-13 15:30:37 UTC (rev 11752)
@@ -1207,7 +1207,8 @@
       public function sendInFrontOf( sprite ){
           if (!this.isroot) {
               var i = parent.getChildIndex(sprite);
-              parent.setChildIndex(this, i);
+              var j = parent.getChildIndex(this);
+              if (j < i) parent.setChildIndex(this, i);
           }
       }
 



More information about the Laszlo-checkins mailing list