Index: content/browser/android/child_process_launcher_android.cc |
diff --git a/content/browser/android/child_process_launcher_android.cc b/content/browser/android/child_process_launcher_android.cc |
index d3e8ee589ef18186b95e8061c41e73e07cb11a59..725ae9a8f5a6d57f1f3e87074ec7a529d1eef83a 100644 |
--- a/content/browser/android/child_process_launcher_android.cc |
+++ b/content/browser/android/child_process_launcher_android.cc |
@@ -14,6 +14,7 @@ |
#include "base/android/jni_android.h" |
#include "base/android/jni_array.h" |
#include "base/logging.h" |
+#include "content/browser/android/scoped_surface_request_manager.h" |
#include "content/browser/file_descriptor_info_impl.h" |
#include "content/browser/frame_host/render_frame_host_impl.h" |
#include "content/browser/media/android/browser_media_player_manager.h" |
@@ -236,6 +237,18 @@ void EstablishSurfacePeer(JNIEnv* env, |
&SetSurfacePeer, jsurface, pid, primary_id, secondary_id)); |
} |
+void CompleteScopedSurfaceRequest(JNIEnv* env, |
+ const JavaParamRef<jclass>& clazz, |
+ jlong request_token, |
+ const JavaParamRef<jobject>& surface) { |
+ ScopedJavaGlobalRef<jobject> jsurface; |
+ jsurface.Reset(env, surface); |
+ gl::ScopedJavaSurface scoped_surface(jsurface); |
+ |
+ ScopedSurfaceRequestManager::GetInstance()->FulfillScopedSurfaceRequest( |
+ request_token, std::move(scoped_surface)); |
+} |
+ |
void RegisterViewSurface(int surface_id, jobject j_surface) { |
JNIEnv* env = AttachCurrentThread(); |
DCHECK(env); |