gnash-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnash-commit] gnash ChangeLog testsuite/misc-ming.all/display...


From: Sandro Santilli
Subject: [Gnash-commit] gnash ChangeLog testsuite/misc-ming.all/display...
Date: Thu, 10 May 2007 09:49:53 +0000

CVSROOT:        /sources/gnash
Module name:    gnash
Changes by:     Sandro Santilli <strk>  07/05/10 09:49:53

Modified files:
        .              : ChangeLog 
        testsuite/misc-ming.all: displaylist_depths_test2.c 

Log message:
                * testsuite/misc-ming.all/displaylist_depths_test2.c: target
                  SWF7, use getInstanceAtDepth() to verify Gnash succeeds the
                  test, despite the fact it's "soft references" implementation
                  is bogus (thanks to zou for the tip!). We might still want a
                  MovieTester based runner to check for rendering in any case,
                  but less urgent...

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/ChangeLog?cvsroot=gnash&r1=1.3149&r2=1.3150
http://cvs.savannah.gnu.org/viewcvs/gnash/testsuite/misc-ming.all/displaylist_depths_test2.c?cvsroot=gnash&r1=1.1&r2=1.2

Patches:
Index: ChangeLog
===================================================================
RCS file: /sources/gnash/gnash/ChangeLog,v
retrieving revision 1.3149
retrieving revision 1.3150
diff -u -b -r1.3149 -r1.3150
--- ChangeLog   10 May 2007 09:26:56 -0000      1.3149
+++ ChangeLog   10 May 2007 09:49:52 -0000      1.3150
@@ -1,5 +1,11 @@
 2007-05-10 Sandro Santilli <address@hidden>
 
+       * testsuite/misc-ming.all/displaylist_depths_test2.c: target
+         SWF7, use getInstanceAtDepth() to verify Gnash succeeds the
+         test, despite the fact it's "soft references" implementation 
+         is bogus (thanks to zou for the tip!). We might still want a
+         MovieTester based runner to check for rendering in any case,
+         but less urgent...
        * server/sprite_instance.{cpp,h}: Implemented
          MovieClip.getInstanceAtDepth() and MovieClip.getSWFVersion();
          stubbed MovieClip.getTextSnapshot().

Index: testsuite/misc-ming.all/displaylist_depths_test2.c
===================================================================
RCS file: 
/sources/gnash/gnash/testsuite/misc-ming.all/displaylist_depths_test2.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -b -r1.1 -r1.2
--- testsuite/misc-ming.all/displaylist_depths_test2.c  9 May 2007 21:23:38 
-0000       1.1
+++ testsuite/misc-ming.all/displaylist_depths_test2.c  10 May 2007 09:49:53 
-0000      1.2
@@ -41,7 +41,8 @@
 #include <stdio.h>
 #include <ming.h>
 
-#define OUTPUT_VERSION 6
+// We need version 7 to use getInstanceAtDepth()
+#define OUTPUT_VERSION 7
 #define OUTPUT_FILENAME "displaylist_depths_test2.swf"
 
 SWFDisplayItem add_static_mc(SWFMovie mo, const char* name, int depth, int x, 
int y, int width, int height);
@@ -63,7 +64,17 @@
        SWFDisplayItem_setDepth(it, depth); 
        SWFDisplayItem_moveTo(it, x, y); 
        SWFDisplayItem_setName(it, name);
-       SWFDisplayItem_addAction(it, newSWFAction("_root.note(this+' 
onClipConstruct'); _root.depth3constructed++;"), SWFACTION_CONSTRUCT);
+       SWFDisplayItem_addAction(it, newSWFAction(
+                       "_root.note(this+' onClipConstruct');"
+                       " _root.check_equals(typeof(_root), 'movieclip');"
+                       " if ( isNaN(_root.depth3Constructed) ) {"
+                       "       _root.depth3Constructed=1; "
+                       "       _root.note('_root.depth3Constructed set to 
'+_root.depth3Constructed);"
+                       " } else {"
+                       "       _root.depth3Constructed++;"
+                       "       _root.note('_root.depth3Constructed set to 
'+_root.depth3Constructed);"
+                       " }"
+                       ), SWFACTION_CONSTRUCT);
 
        return it;
 }
@@ -162,9 +173,13 @@
                "xcheck_equals(dynRef.myThing, 'guess');"
                "xcheck_equals(dynRef.getDepth(), 10);" 
 
+               // Luckly we can query for depth chars with getInstanceAtDepth
+               "check_equals(typeof(getInstanceAtDepth(-16381)), 'movieclip');"
+               "check_equals(typeof(getInstanceAtDepth(10)), 'movieclip');"
+
                "check_equals(static3.getDepth(), -16381);" 
                "check_equals(static3._x, 50);" 
-               "check_equals(depth3constructed, 2);" 
+               "check_equals(depth3Constructed, 2);" 
                "totals();"
                );
        SWFMovie_nextFrame(mo); 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]