gnash-commit
[Top][All Lists]
Advanced

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

[Gnash-commit] [SCM] Gnash branch, master, updated. release_0_8_9_start-


From: Benjamin Wolsey
Subject: [Gnash-commit] [SCM] Gnash branch, master, updated. release_0_8_9_start-502-g7708095
Date: Sun, 03 Apr 2011 08:55:38 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Gnash".

The branch, master has been updated
       via  7708095e73bd1d5827ac25d65a6a440e065f24a3 (commit)
       via  44c82afe99bd02696c3d79731da18c5c55e7a7b3 (commit)
       via  c6470ee08a5edb0706e0332c9a646951ccfc86a4 (commit)
      from  fe94887b8c648fd3eb4b1030091e5b45a54c15d1 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://git.savannah.gnu.org/cgit//commit/?id=7708095e73bd1d5827ac25d65a6a440e065f24a3


commit 7708095e73bd1d5827ac25d65a6a440e065f24a3
Author: Benjamin Wolsey <address@hidden>
Date:   Sun Apr 3 10:16:43 2011 +0200

    Don't use an exception for exclusively local error handling.

diff --git a/libbase/GnashException.h b/libbase/GnashException.h
index 288fef7..c05b214 100644
--- a/libbase/GnashException.h
+++ b/libbase/GnashException.h
@@ -197,28 +197,6 @@ public:
 
 };
 
-/// An unhandled exception in ActionScript, which should
-/// interrupt code execution.
-class ActionScriptException: public ActionException
-{
-
-public:
-
-       ActionScriptException(const std::string& s)
-               :
-               ActionException(s)
-       {}
-
-       ActionScriptException()
-               :
-               ActionException("Unhandled ActionScript exception")
-       {}
-
-       virtual ~ActionScriptException() throw() {}
-
-};
-
-
 } // namespace gnash
 
 #endif // def GNASH_GNASHEXCEPTION_H
diff --git a/libcore/vm/ActionExec.cpp b/libcore/vm/ActionExec.cpp
index a653e60..00e7f4b 100644
--- a/libcore/vm/ActionExec.cpp
+++ b/libcore/vm/ActionExec.cpp
@@ -183,7 +183,15 @@ ActionExec::operator()()
                         // Stop execution if an exception
                         // is still on the stack and there is nothing
                         // left to catch it.
-                        throw ActionScriptException();
+                        cleanupAfterRun();
+
+                        // Forceably clear the stack.
+                        // - Fixes misc-mtasc.all/exception.swf
+                        // By commenting the line above, we get an XPASS in
+                        // - swfdec/catch-in-caller.swf
+                        env.drop(env.stack_size());
+
+                        return;
                     }
                     break;
                 }
@@ -319,18 +327,6 @@ ActionExec::operator()()
         cleanupAfterRun(); // we expect inconsistencies here
         throw;
     }
-    catch (const ActionScriptException&) {
-        // An unhandled ActionScript exception was thrown.
-        cleanupAfterRun();
-
-        // Forceably clear the stack.
-        // - Fixes misc-mtasc.all/exception.swf
-        // By commenting the line above, we get an XPASS in
-        // - swfdec/catch-in-caller.swf
-        env.drop(env.stack_size());
-
-        return;
-    }
 
     cleanupAfterRun();
 

http://git.savannah.gnu.org/cgit//commit/?id=44c82afe99bd02696c3d79731da18c5c55e7a7b3


commit 44c82afe99bd02696c3d79731da18c5c55e7a7b3
Author: Benjamin Wolsey <address@hidden>
Date:   Sun Apr 3 10:11:26 2011 +0200

    Don't declare or include as_environment where not needed.

diff --git a/libcore/PropertyList.h b/libcore/PropertyList.h
index 91e5c21..99c4552 100644
--- a/libcore/PropertyList.h
+++ b/libcore/PropertyList.h
@@ -37,7 +37,6 @@
 // Forward declaration
 namespace gnash {
     class as_object;
-    class as_environment;
     class as_function;
     struct ObjectURI;
     class as_value;
@@ -159,7 +158,7 @@ public:
         }
     }
 
-    /// Enumerate all non-hidden properties to the given as_environment.
+    /// Enumerate all non-hidden properties to the given container.
     //
     /// Follows enumeration order. Note that this enumeration does not
     /// access the values. Accessing the values can result in changes to
diff --git a/libcore/TextField.cpp b/libcore/TextField.cpp
index 0abf88c..a5f0915 100644
--- a/libcore/TextField.cpp
+++ b/libcore/TextField.cpp
@@ -1987,7 +1987,6 @@ TextField::registerTextVariable()
     as_value val;
     if (target->get_member(key, &val)) {
         // TODO: pass environment to to_string ?
-        // as_environment& env = get_environment();
         setTextValue(utf8::decodeCanonicalString(val.to_string(), version));
     }
     else if (_textDefined) {
diff --git a/libcore/builtin_function.h b/libcore/builtin_function.h
index 1e62cf9..8906800 100644
--- a/libcore/builtin_function.h
+++ b/libcore/builtin_function.h
@@ -20,7 +20,6 @@
 #define GNASH_BUILTIN_FUNCTION_H
 
 #include "UserFunction.h" 
-#include "as_environment.h"
 #include "fn_call.h"
 
 #include <cassert>
diff --git a/libcore/parser/action_buffer.h b/libcore/parser/action_buffer.h
index 14a2e96..10420ca 100644
--- a/libcore/parser/action_buffer.h
+++ b/libcore/parser/action_buffer.h
@@ -29,7 +29,6 @@
 
 // Forward declarations
 namespace gnash {
-       class as_environment;
        class as_value;
        class movie_definition;
        class SWFStream; // for read signature
diff --git a/libcore/vm/ASHandlers.h b/libcore/vm/ASHandlers.h
index 2483ac4..b599f9d 100644
--- a/libcore/vm/ASHandlers.h
+++ b/libcore/vm/ASHandlers.h
@@ -26,7 +26,6 @@
 // Forward declarations
 namespace gnash {
     class ActionExec;
-    class as_environment;
 }
 
 namespace gnash {

http://git.savannah.gnu.org/cgit//commit/?id=c6470ee08a5edb0706e0332c9a646951ccfc86a4


commit c6470ee08a5edb0706e0332c9a646951ccfc86a4
Author: Benjamin Wolsey <address@hidden>
Date:   Sun Apr 3 10:11:15 2011 +0200

    Get movie_root in the most direct way.

diff --git a/libcore/DisplayObject.cpp b/libcore/DisplayObject.cpp
index cf87308..f859829 100644
--- a/libcore/DisplayObject.cpp
+++ b/libcore/DisplayObject.cpp
@@ -133,11 +133,12 @@ ObjectURI
 DisplayObject::getNextUnnamedInstanceName()
 {
     assert(_object);
-    movie_root& mr = getRoot(*_object);
+    movie_root& mr = stage();
+
     std::ostringstream ss;
     ss << "instance" << mr.nextUnnamedInstance();
 
-    VM& vm = getVM(*_object);
+    VM& vm = mr.getVM();
     return getURI(vm, ss.str(), true);
 }
 
@@ -145,9 +146,8 @@ DisplayObject::getNextUnnamedInstanceName()
 int
 DisplayObject::getWorldVolume() const
 {
-    int volume=_volume;
-    if (_parent != NULL)
-    {
+    int volume = _volume;
+    if (_parent) {
         volume = int(volume*_parent->getVolume()/100.0);
     }
 
@@ -329,7 +329,7 @@ DisplayObject::set_visible(bool visible)
     // invisible (see Selection.as).
     if (_visible && !visible) {
         assert(_object);
-        movie_root& mr = getRoot(*_object);
+        movie_root& mr = stage();
         if (mr.getFocus() == this) {
             mr.setFocus(0);
         }

-----------------------------------------------------------------------

Summary of changes:
 libbase/GnashException.h       |   22 ----------------------
 libcore/DisplayObject.cpp      |   12 ++++++------
 libcore/PropertyList.h         |    3 +--
 libcore/TextField.cpp          |    1 -
 libcore/builtin_function.h     |    1 -
 libcore/parser/action_buffer.h |    1 -
 libcore/vm/ASHandlers.h        |    1 -
 libcore/vm/ActionExec.cpp      |   22 +++++++++-------------
 8 files changed, 16 insertions(+), 47 deletions(-)


hooks/post-receive
-- 
Gnash



reply via email to

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