[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnash-commit] gnash ChangeLog testsuite/misc-ming.all/DefineE...
From: |
Sandro Santilli |
Subject: |
[Gnash-commit] gnash ChangeLog testsuite/misc-ming.all/DefineE... |
Date: |
Thu, 21 Sep 2006 08:27:49 +0000 |
CVSROOT: /sources/gnash
Module name: gnash
Changes by: Sandro Santilli <strk> 06/09/21 08:27:49
Modified files:
. : ChangeLog
testsuite/misc-ming.all: DefineEditTextVariableNameTest.c
Log message:
put the TextField inside a movieclip and it's associated
variable on the root. This is to ensure that using
the variable name as an instance name would clearly NOT work.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/ChangeLog?cvsroot=gnash&r1=1.884&r2=1.885
http://cvs.savannah.gnu.org/viewcvs/gnash/testsuite/misc-ming.all/DefineEditTextVariableNameTest.c?cvsroot=gnash&r1=1.2&r2=1.3
Patches:
Index: ChangeLog
===================================================================
RCS file: /sources/gnash/gnash/ChangeLog,v
retrieving revision 1.884
retrieving revision 1.885
diff -u -b -r1.884 -r1.885
--- ChangeLog 21 Sep 2006 06:26:47 -0000 1.884
+++ ChangeLog 21 Sep 2006 08:27:49 -0000 1.885
@@ -1,5 +1,9 @@
2006-09-21 Sandro Santilli <address@hidden>
+ * testsuite/misc-ming.all/DefineEditTextVariableNameTest.c:
+ put the TextField inside a movieclip and it's associated
+ variable on the root. This is to ensure that using
+ the variable name as an instance name would clearly NOT work.
* server/dlist.{cpp,h}: dump() method made public, print
character "name" as part of the dump.
Index: testsuite/misc-ming.all/DefineEditTextVariableNameTest.c
===================================================================
RCS file:
/sources/gnash/gnash/testsuite/misc-ming.all/DefineEditTextVariableNameTest.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -b -r1.2 -r1.3
--- testsuite/misc-ming.all/DefineEditTextVariableNameTest.c 20 Sep 2006
16:50:33 -0000 1.2
+++ testsuite/misc-ming.all/DefineEditTextVariableNameTest.c 21 Sep 2006
08:27:49 -0000 1.3
@@ -42,6 +42,12 @@
* and "World" by accessing the VariableName. After every
* variable set it also traces the value of the VariableName.
*
+ * The EditText character is stored inside a MovieClip, and
+ * it's variable is set on the root. Note that the ActionScript
+ * code also tries to *move* the character trough the variable
+ * (incdement varname._x).
+ * The correct behaviour is for the character to NOT move
+ *
* run as ./DefineEditTextVariableNameTest
*/
@@ -52,10 +58,10 @@
#define OUTPUT_VERSION 7
#define OUTPUT_FILENAME "DefineEditTextVariableNameTest.swf"
-void add_text_field(SWFMovie mo, SWFBlock font, const char* varname, const
char* text);
+void add_text_field(SWFMovieClip mo, SWFBlock font, const char* varname, const
char* text);
void
-add_text_field(SWFMovie mo, SWFBlock font, const char* varname,
+add_text_field(SWFMovieClip mo, SWFBlock font, const char* varname,
const char* text)
{
SWFTextField tf;
@@ -69,13 +75,15 @@
// Give the textField a variablename
SWFTextField_setVariableName(tf, varname);
- SWFMovie_add(mo, (SWFBlock)tf);
+ SWFMovieClip_add(mo, (SWFBlock)tf);
}
int
main(int argc, char** argv)
{
SWFMovie mo;
+ SWFMovieClip mc;
+ SWFDisplayItem it;
const char *srcdir=".";
char fdbfont[256];
@@ -106,6 +114,14 @@
/*********************************************
*
+ * Add a new MovieClip
+ *
+ *********************************************/
+
+ mc = newSWFMovieClip();
+
+ /*********************************************
+ *
* Add the textfield
*
*********************************************/
@@ -113,7 +129,7 @@
/*
* The variable name
*/
- char* varName = "testName";
+ char* varName = "_root.testName";
char buf[256];
/* This is with embedded fonts, not working */
@@ -126,9 +142,13 @@
}
/*SWFBrowserFont bfont = newSWFBrowserFont("_sans");*/
SWFFont bfont = loadSWFFontFromFile(font_file);
- add_text_field(mo, (SWFBlock)bfont, varName, "Hello World");
+ add_text_field(mc, (SWFBlock)bfont, varName, "Hello World");
+ SWFMovieClip_nextFrame(mc);
}
+ it = SWFMovie_add(mo, (SWFBlock)mc);
+ SWFDisplayItem_setName(it, "mc1");
+
/*********************************************
*
* Access the value of the variablename
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Gnash-commit] gnash ChangeLog testsuite/misc-ming.all/DefineE...,
Sandro Santilli <=