< prev index next >

modules/javafx.web/src/main/native/Tools/DumpRenderTree/java/WorkQueueItemJava.cpp

Print this page
rev 11020 : 8201563: Update copyright header for files modified in 2018
Reviewed-by:
   1 /*
   2  * Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved.
   3  */
   4 #include "config.h"
   5 #include "JavaEnv.h"
   6 #include <JavaScriptCore/JSRetainPtr.h>
   7 #include <JavaScriptCore/JSStringRef.h>
   8 #include <wtf/java/JavaRef.h>
   9 
  10 #include "WorkQueueItem.h"
  11 
  12 extern jstring JSStringRef_to_jstring(JSStringRef ref, JNIEnv* env);
  13 extern JSStringRef jstring_to_JSStringRef(jstring str, JNIEnv* env);
  14 
  15 bool LoadItem::invoke() const
  16 {
  17     JNIEnv* env = DumpRenderTree_GetJavaEnv();
  18     JLString jUrl(JSStringRef_to_jstring(m_url.get(), env));
  19     env->CallStaticObjectMethod(getDumpRenderTreeClass(), getLoadURLMID(), (jstring)jUrl);
  20     CheckAndClearException(env);
  21 
  22     return true;


   1 /*
   2  * Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
   3  */
   4 #include "config.h"
   5 #include "JavaEnv.h"
   6 #include <JavaScriptCore/JSRetainPtr.h>
   7 #include <JavaScriptCore/JSStringRef.h>
   8 #include <wtf/java/JavaRef.h>
   9 
  10 #include "WorkQueueItem.h"
  11 
  12 extern jstring JSStringRef_to_jstring(JSStringRef ref, JNIEnv* env);
  13 extern JSStringRef jstring_to_JSStringRef(jstring str, JNIEnv* env);
  14 
  15 bool LoadItem::invoke() const
  16 {
  17     JNIEnv* env = DumpRenderTree_GetJavaEnv();
  18     JLString jUrl(JSStringRef_to_jstring(m_url.get(), env));
  19     env->CallStaticObjectMethod(getDumpRenderTreeClass(), getLoadURLMID(), (jstring)jUrl);
  20     CheckAndClearException(env);
  21 
  22     return true;


< prev index next >