Implement the rendering hooks for Java compositor integration. Currently segfaulting, so ifdef'd out.

This commit is contained in:
Patrick Walton
2012-02-09 23:55:13 -08:00
parent a986e4bb7a
commit 8c95b641e1
6 changed files with 56 additions and 12 deletions

View File

@@ -694,8 +694,22 @@ AndroidGeckoGLLayerClient::Init(jobject jobj)
void
AndroidLayerRendererFrame::Init(jobject jobj)
{
NS_ASSERTION(wrapped_obj == nsnull, "Init called on non-null wrapped_obj!");
wrapped_obj = jobj;
if (!isNull()) {
Dispose();
}
wrapped_obj = GetJNIForThread()->NewGlobalRef(jobj);
}
void
AndroidLayerRendererFrame::Dispose()
{
if (isNull()) {
return;
}
GetJNIForThread()->DeleteGlobalRef(wrapped_obj);
wrapped_obj = 0;
}
void