[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Gnash-commit] gnash ChangeLog server/as_value.cpp server/dlis...
From: |
zou lunkai |
Subject: |
Re: [Gnash-commit] gnash ChangeLog server/as_value.cpp server/dlis... |
Date: |
Mon, 27 Aug 2007 09:26:53 +0800 |
How is the status of Soft Reference now? I see lots of them have been fixed.
On 8/25/07, Sandro Santilli <address@hidden> wrote:
> CVSROOT: /sources/gnash
> Module name: gnash
> Changes by: Sandro Santilli <strk> 07/08/24 16:07:27
>
> Modified files:
> . : ChangeLog
> server : as_value.cpp dlist.cpp dlist.h
> testsuite/actionscript.all: MovieClip.as case.as
> testsuite/misc-ming.all: displaylist_depths_test2.c
>
> Log message:
> * server/dlist.{h,cpp} (replace_character): call unload() on
> replaced
> character and document the fact.
> * server/as_value.cpp: undefine the MOVIECLIP_AS_SOFTREF
> macro, tweak
> equalSameType() and to_sprite() to use MOVIECLIP targets
> only when
> they are unloaded.
> * testsuite/misc-ming.all/displaylist_depths_test2.c: xcheck
> => check
> (no more failures from this test)
> * testsuite/actionscript.all/MovieClip.as: xcheck => check
> (soft-references related)
> * testsuite/actionscript.all/case.as: xcheck => check (soft
> refs).
>
> CVSWeb URLs:
> http://cvs.savannah.gnu.org/viewcvs/gnash/ChangeLog?cvsroot=gnash&r1=1.4098&r2=1.4099
> http://cvs.savannah.gnu.org/viewcvs/gnash/server/as_value.cpp?cvsroot=gnash&r1=1.65&r2=1.66
> http://cvs.savannah.gnu.org/viewcvs/gnash/server/dlist.cpp?cvsroot=gnash&r1=1.77&r2=1.78
> http://cvs.savannah.gnu.org/viewcvs/gnash/server/dlist.h?cvsroot=gnash&r1=1.45&r2=1.46
> http://cvs.savannah.gnu.org/viewcvs/gnash/testsuite/actionscript.all/MovieClip.as?cvsroot=gnash&r1=1.83&r2=1.84
> http://cvs.savannah.gnu.org/viewcvs/gnash/testsuite/actionscript.all/case.as?cvsroot=gnash&r1=1.8&r2=1.9
> http://cvs.savannah.gnu.org/viewcvs/gnash/testsuite/misc-ming.all/displaylist_depths_test2.c?cvsroot=gnash&r1=1.7&r2=1.8
>
> Patches:
> Index: ChangeLog
> ===================================================================
> RCS file: /sources/gnash/gnash/ChangeLog,v
> retrieving revision 1.4098
> retrieving revision 1.4099
> diff -u -b -r1.4098 -r1.4099
> --- ChangeLog 24 Aug 2007 15:52:49 -0000 1.4098
> +++ ChangeLog 24 Aug 2007 16:07:26 -0000 1.4099
> @@ -1,3 +1,16 @@
> +2007-08-24 Sandro Santilli <address@hidden>
> +
> + * server/dlist.{h,cpp} (replace_character): call unload() on replaced
> + character and document the fact.
> + * server/as_value.cpp: undefine the MOVIECLIP_AS_SOFTREF macro, tweak
> + equalSameType() and to_sprite() to use MOVIECLIP targets only when
> + they are unloaded.
> + * testsuite/misc-ming.all/displaylist_depths_test2.c: xcheck => check
> + (no more failures from this test)
> + * testsuite/actionscript.all/MovieClip.as: xcheck => check
> + (soft-references related)
> + * testsuite/actionscript.all/case.as: xcheck => check (soft refs).
> +
> 2007-08-24 Miriam Ruiz <address@hidden>
>
> * plugin/klash/klash_part.cpp: Patch for GNASHEXE.
>
> Index: server/as_value.cpp
> ===================================================================
> RCS file: /sources/gnash/gnash/server/as_value.cpp,v
> retrieving revision 1.65
> retrieving revision 1.66
> diff -u -b -r1.65 -r1.66
> --- server/as_value.cpp 24 Aug 2007 13:55:08 -0000 1.65
> +++ server/as_value.cpp 24 Aug 2007 16:07:27 -0000 1.66
> @@ -44,7 +44,7 @@
>
> // Undefine this to keep MOVIECLIP values by pointer
> // rather then by "target" ref.
> -#define MOVIECLIP_AS_SOFTREF
> +//#define MOVIECLIP_AS_SOFTREF
>
> // Define the macro below to make abstract equality operator verbose
> //#define GNASH_DEBUG_EQUALITY
> @@ -512,9 +512,11 @@
> if ( sp->isUnloaded() )
> {
> log_error(_("MovieClip value is a dangling reference: "
> - "target %s was unloaded (should set to
> NULL?)"),
> + "target %s was unloaded (looking for a
> substitute on the same target))"),
> sp->getTarget().c_str());
> - return NULL;
> + sp = find_sprite_by_target(sp->getTarget());
> + return sp;
> + //return NULL;
> }
> return sp;
> #else
> @@ -847,7 +849,7 @@
> #ifdef MOVIECLIP_AS_SOFTREF
> return m_string_value == v.m_string_value;
> #else
> - return m_object_value == v.m_object_value;
> + return to_sprite() == v.to_sprite(); //
> m_object_value == v.m_object_value;
> #endif
>
> case NUMBER:
>
> Index: server/dlist.cpp
> ===================================================================
> RCS file: /sources/gnash/gnash/server/dlist.cpp,v
> retrieving revision 1.77
> retrieving revision 1.78
> diff -u -b -r1.77 -r1.78
> --- server/dlist.cpp 22 Aug 2007 04:54:56 -0000 1.77
> +++ server/dlist.cpp 24 Aug 2007 16:07:27 -0000 1.78
> @@ -311,6 +311,9 @@
> // remember bounds of old char
> oldch->add_invalidated_bounds(old_ranges, true);
>
> + // Unload old char
> + (*it)->unload();
> +
> // replace existing char
> *it = di;
>
>
> Index: server/dlist.h
> ===================================================================
> RCS file: /sources/gnash/gnash/server/dlist.h,v
> retrieving revision 1.45
> retrieving revision 1.46
> diff -u -b -r1.45 -r1.46
> --- server/dlist.h 1 Jul 2007 10:54:21 -0000 1.45
> +++ server/dlist.h 24 Aug 2007 16:07:27 -0000 1.46
> @@ -98,6 +98,8 @@
> /// Puts a new character at the specified depth, replacing any
> /// existing character.
> //
> + /// Calls unload on the removed character.
> + ///
> /// If use_cxform or use_matrix are false, and a character is
> /// present at the given depth, then keep those respective
> /// properties from the existing character.
>
> Index: testsuite/actionscript.all/MovieClip.as
> ===================================================================
> RCS file: /sources/gnash/gnash/testsuite/actionscript.all/MovieClip.as,v
> retrieving revision 1.83
> retrieving revision 1.84
> diff -u -b -r1.83 -r1.84
> --- testsuite/actionscript.all/MovieClip.as 24 Aug 2007 15:05:23 -0000
> 1.83
> +++ testsuite/actionscript.all/MovieClip.as 24 Aug 2007 16:07:27 -0000
> 1.84
> @@ -20,7 +20,7 @@
> // compile this test case with Ming makeswf, and then
> // execute it like this gnash -1 -r 0 -v out.swf
>
> -rcsid="$Id: MovieClip.as,v 1.83 2007/08/24 15:05:23 strk Exp $";
> +rcsid="$Id: MovieClip.as,v 1.84 2007/08/24 16:07:27 strk Exp $";
>
> #include "check.as"
>
> @@ -393,10 +393,10 @@
> check_equals(typeof(mc4), 'movieclip');
> check_equals(typeof(mc5), 'movieclip');
> // gah.. our "soft references" are bogus :(
> -xcheck_equals(mc4._target, "/changed");
> -xcheck_equals(mc5._target, "/changed/mc5_mc");
> -xcheck_equals(targetPath(mc4), "_level0.changed");
> -xcheck_equals(targetPath(mc5), "_level0.changed.mc5_mc");
> +check_equals(mc4._target, "/changed");
> +check_equals(mc5._target, "/changed/mc5_mc");
> +check_equals(targetPath(mc4), "_level0.changed");
> +check_equals(targetPath(mc5), "_level0.changed.mc5_mc");
> xcheck_equals(mc4.toString(), "[object Object]");
> xcheck_equals(mc5.toString(), "[object Object]");
> check_equals(changed._target, "/changed");
> @@ -452,7 +452,7 @@
> // it's distinct clip !
> sr61.member = 6;
> check_equals(sr61.member, 6);
> -xcheck_equals(typeof(sr62.member), 'undefined');
> +check_equals(typeof(sr62.member), 'undefined');
> check_equals(sr61._name, "hardref");
> check_equals(sr62._name, "hardref");
>
>
> Index: testsuite/actionscript.all/case.as
> ===================================================================
> RCS file: /sources/gnash/gnash/testsuite/actionscript.all/case.as,v
> retrieving revision 1.8
> retrieving revision 1.9
> diff -u -b -r1.8 -r1.9
> --- testsuite/actionscript.all/case.as 23 Aug 2007 16:50:56 -0000 1.8
> +++ testsuite/actionscript.all/case.as 24 Aug 2007 16:07:27 -0000 1.9
> @@ -22,7 +22,7 @@
> * Test case sensitivity
> */
>
> -rcsid="$Id: case.as,v 1.8 2007/08/23 16:50:56 strk Exp $";
> +rcsid="$Id: case.as,v 1.9 2007/08/24 16:07:27 strk Exp $";
>
> #include "check.as"
>
> @@ -133,15 +133,15 @@
> check_equals(mcRef[1]._name, "CLIP");
> check_equals(mcRef[1]._target, "/CLIP");
> #else // OUTPUT_VERSION <= 6
> -// Gnash fails these due to "soft references"
> +// Gnash used to fail these due to "soft references"
> // Basically, a MOVIECLIP as_value stores the clip
> // target, but in SWF<7 the target is insensitive
> // so /clip and /CLIP both resolve to the *same*
> // character.
> //
> -xcheck_equals(mcRef[1].getDepth(), 7);
> -xcheck_equals(mcRef[1]._name, "CLIP");
> -xcheck_equals(mcRef[1]._target, "/CLIP");
> +check_equals(mcRef[1].getDepth(), 7);
> +check_equals(mcRef[1]._name, "CLIP");
> +check_equals(mcRef[1]._target, "/CLIP");
> #endif // OUTPUT_VERSION <= 6
>
>
>
> 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.7
> retrieving revision 1.8
> diff -u -b -r1.7 -r1.8
> --- testsuite/misc-ming.all/displaylist_depths_test2.c 1 Jul 2007 10:54:51
> -0000 1.7
> +++ testsuite/misc-ming.all/displaylist_depths_test2.c 24 Aug 2007 16:07:27
> -0000 1.8
> @@ -188,8 +188,8 @@
> // existance of the old (dynamicized) instance by
> looking
> // at the real DisplayList and at the rendered buffer
> //
> - "xcheck_equals(dynRef.myThing, 'guess');"
> - "xcheck_equals(dynRef.getDepth(), 10);"
> + "check_equals(dynRef.myThing, 'guess');"
> + "check_equals(dynRef.getDepth(), 10);"
>
> // Luckly we can query for depth chars with getInstanceAtDepth
> "check_equals(typeof(getInstanceAtDepth(-16381)),
> 'movieclip');"
>
>
> _______________________________________________
> Gnash-commit mailing list
> address@hidden
> http://lists.gnu.org/mailman/listinfo/gnash-commit
>