gnash-commit
[Top][All Lists]
Advanced

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

[Gnash-commit] gnash/server Function.cpp


From: strk
Subject: [Gnash-commit] gnash/server Function.cpp
Date: Wed, 26 Apr 2006 13:12:53 +0000

CVSROOT:        /sources/gnash
Module name:    gnash
Branch:         
Changes by:     strk <address@hidden>   06/04/26 13:12:53

Modified files:
        server         : Function.cpp 

Log message:
        Added some comments

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/server/Function.cpp.diff?tr1=1.10&tr2=1.11&r1=text&r2=text

Patches:
Index: gnash/server/Function.cpp
diff -u gnash/server/Function.cpp:1.10 gnash/server/Function.cpp:1.11
--- gnash/server/Function.cpp:1.10      Mon Apr 24 23:05:56 2006
+++ gnash/server/Function.cpp   Wed Apr 26 13:12:53 2006
@@ -48,6 +48,26 @@
 
 namespace gnash {
 
+/* 
+ * This function returns the singleton
+ * instance of the ActionScript Function object
+ * prototype, which is what the AS Function class
+ * exports, thus what each AS function instance inherit.
+ *
+ * The returned object can be accessed by ActionScript
+ * code through Function.__proto__.prototype.
+ * User AS code can add or modify members of this object
+ * to modify behaviour of all Function AS instances.
+ *
+ * FIXME: do not use a static specifier for the proto
+ * object, as multiple runs of a single movie should
+ * each use a 'clean', unmodified, version of the
+ * prototype. What should really happen is that this
+ * prototype gets initializated by initialization of
+ * the Function class itself, which would be a member
+ * of the _global object for each movie instance.
+ * 
+ */
 static as_object* getFunctionPrototype()
 {
        static as_object* proto = NULL;
@@ -63,7 +83,9 @@
 
 }
 
-
+/*
+ * Initialize the "Function" member of a _global object.
+ */
 void function_init(as_object* global)
 {
        // This is going to be the global Function "class"/"function"




reply via email to

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