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_final-


From: Sandro Santilli
Subject: [Gnash-commit] [SCM] Gnash branch, master, updated. release_0_8_9_final-473-g29aa95c
Date: Tue, 12 Jul 2011 21:31:39 +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  29aa95ca3ed88d5e68fd57d9ac53ebf985040804 (commit)
      from  db597f4b39ff84f50e74ce5e277de0940ed06c9d (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=29aa95ca3ed88d5e68fd57d9ac53ebf985040804


commit 29aa95ca3ed88d5e68fd57d9ac53ebf985040804
Author: Sandro Santilli <address@hidden>
Date:   Tue Jul 12 23:31:16 2011 +0200

    I guess you need ConstantPool class files too...

diff --git a/libcore/ConstantPool.cpp b/libcore/ConstantPool.cpp
new file mode 100644
index 0000000..f88832c
--- /dev/null
+++ b/libcore/ConstantPool.cpp
@@ -0,0 +1,55 @@
+// ConstantPool.h: a parsed ConstantPool 
+// 
+//   Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010,
+//   2011 Free Software Foundation, Inc
+// 
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation; either version 3 of the License, or
+// (at your option) any later version.
+// 
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details.
+// 
+// You should have received a copy of the GNU General Public License
+// along with this program; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+//
+
+#include <vector>
+#include <iostream>
+
+#include "ConstantPool.h"
+#include "VM.h"
+
+
+namespace gnash {
+
+std::ostream& 
+operator<<(std::ostream& os, const ConstantPool& p) {
+    for (size_t i=0; i<p.size(); ++i) {
+        if (i) os <<  ", ";
+        os << i << ':' << p[i];
+    }
+    return os;
+}
+
+
+PoolGuard::PoolGuard(VM& vm, const ConstantPool* pool)
+    :
+    _vm(vm),
+    _from(_vm.getConstantPool())
+{
+    _vm.setConstantPool(pool);
+}
+
+
+PoolGuard::~PoolGuard() 
+{
+    _vm.setConstantPool(_from);
+}
+
+
+} // namespace gnash
diff --git a/libcore/ConstantPool.h b/libcore/ConstantPool.h
new file mode 100644
index 0000000..f4c3b01
--- /dev/null
+++ b/libcore/ConstantPool.h
@@ -0,0 +1,52 @@
+// ConstantPool.h: a parsed ConstantPool 
+// 
+//   Copyright (C) 2011 Free Software Foundation, Inc
+// 
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation; either version 3 of the License, or
+// (at your option) any later version.
+// 
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details.
+// 
+// You should have received a copy of the GNU General Public License
+// along with this program; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+
+#ifndef GNASH_CONSTANTPOOL_H
+#define GNASH_CONSTANTPOOL_H
+
+#include <vector>
+#include <iosfwd>
+
+namespace gnash {
+
+class VM;
+
+/// An indexed list of strings (must match the definition in action_buffer.h)
+typedef std::vector<const char*> ConstantPool;
+
+std::ostream& operator<<(std::ostream& os, const ConstantPool& p);
+
+class PoolGuard
+{
+public:
+
+       // @param pool : ConstantPool to set temporarely
+       PoolGuard(VM& vm, const ConstantPool* pool);
+       ~PoolGuard();
+
+private:
+
+    VM& _vm;
+    const ConstantPool* _from;
+
+};
+
+} // namespace gnash
+
+
+#endif 

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

Summary of changes:
 .../GnashImageGif.h => libcore/ConstantPool.cpp    |   45 +++++++++++--------
 .../{swf/SoundStreamHeadTag.h => ConstantPool.h}   |   47 ++++++++++----------
 2 files changed, 49 insertions(+), 43 deletions(-)
 copy libbase/GnashImageGif.h => libcore/ConstantPool.cpp (63%)
 copy libcore/{swf/SoundStreamHeadTag.h => ConstantPool.h} (58%)


hooks/post-receive
-- 
Gnash



reply via email to

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