1 /*
2 * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
3 */
4 #include "config.h"
5
6 #include <wtf/java/JavaEnv.h>
7 #include <wtf/java/JavaRef.h>
8 #include <wtf/MainThread.h>
9
10 namespace WTF {
11 void scheduleDispatchFunctionsOnMainThread()
12 {
13 AttachThreadAsNonDaemonToJavaEnv autoAttach;
14 JNIEnv* env = autoAttach.env();
15 static JGClass jMainThreadCls(env->FindClass("com/sun/webkit/MainThread"));
16
17 static jmethodID mid = env->GetStaticMethodID(
18 jMainThreadCls,
19 "fwkScheduleDispatchFunctions",
20 "()V");
21
22 ASSERT(mid);
|
1 /*
2 * Copyright (c) 2012, 2018, Oracle and/or its affiliates. All rights reserved.
3 */
4 #include "config.h"
5
6 #include <wtf/java/JavaEnv.h>
7 #include <wtf/java/JavaRef.h>
8 #include <wtf/MainThread.h>
9
10 namespace WTF {
11 void scheduleDispatchFunctionsOnMainThread()
12 {
13 AttachThreadAsNonDaemonToJavaEnv autoAttach;
14 JNIEnv* env = autoAttach.env();
15 static JGClass jMainThreadCls(env->FindClass("com/sun/webkit/MainThread"));
16
17 static jmethodID mid = env->GetStaticMethodID(
18 jMainThreadCls,
19 "fwkScheduleDispatchFunctions",
20 "()V");
21
22 ASSERT(mid);
|