summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--WebCore/bridge/jni/v8/JavaInstanceV8.cpp17
-rw-r--r--WebCore/bridge/jni/v8/JavaInstanceV8.h4
2 files changed, 13 insertions, 8 deletions
diff --git a/WebCore/bridge/jni/v8/JavaInstanceV8.cpp b/WebCore/bridge/jni/v8/JavaInstanceV8.cpp
index 3a2cb8b..59aa104 100644
--- a/WebCore/bridge/jni/v8/JavaInstanceV8.cpp
+++ b/WebCore/bridge/jni/v8/JavaInstanceV8.cpp
@@ -32,14 +32,9 @@
#include "JavaClassV8.h"
#include <assert.h>
-#include <utils/Log.h>
#define LOG_TAG "v8binding"
-
-// ANDROID
-#include <cutils/log.h>
-#define LOG_TAG JavaInstanceV8.cpp
-// END ANDROID
+#include <utils/Log.h>
using namespace JSC::Bindings;
@@ -55,6 +50,16 @@ JavaInstance::~JavaInstance()
delete m_class;
}
+#define NUM_LOCAL_REFS 64
+
+void JavaInstance::virtualBegin() {
+ getJNIEnv()->PushLocalFrame(NUM_LOCAL_REFS);
+}
+
+void JavaInstance::virtualEnd() {
+ getJNIEnv()->PopLocalFrame(0);
+}
+
JavaClass* JavaInstance::getClass() const
{
if (!m_class)
diff --git a/WebCore/bridge/jni/v8/JavaInstanceV8.h b/WebCore/bridge/jni/v8/JavaInstanceV8.h
index c928c05..4f009a5 100644
--- a/WebCore/bridge/jni/v8/JavaInstanceV8.h
+++ b/WebCore/bridge/jni/v8/JavaInstanceV8.h
@@ -89,8 +89,8 @@ protected:
RefPtr<JObjectWrapper> m_instance;
mutable JavaClass* m_class;
- virtual void virtualBegin() {}
- virtual void virtualEnd() {}
+ virtual void virtualBegin();
+ virtual void virtualEnd();
};
} // namespace Bindings