changeset 4183:9ceb29c29665

RT-31381 Apps using WebView don't work with default build setting
author peterz
date Thu, 04 Jul 2013 20:31:13 +0400
parents 62160d20258a
children 4d91fcff597d
files build.gradle
diffstat 1 files changed, 14 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/build.gradle	Thu Jul 04 15:16:14 2013 +0200
+++ b/build.gradle	Thu Jul 04 20:31:13 2013 +0400
@@ -1665,7 +1665,6 @@
              "modules/graphics/build/resources/jsl-prism");
         if (COMPILE_SWING) from ("modules/swing/build/classes/main", "modules/swing/build/resources/main")
         if (COMPILE_SWT) from ("modules/swt/build/classes/main", "modules/swt/build/resources/main")
-        ///if (COMPILE_WEBKIT)
         if (t.name != 'android') {
             from ("modules/web/build/classes/main", "modules/web/build/resources/main")
         } else {
@@ -2312,6 +2311,7 @@
         }
     }
 
+    compileJava.enabled = COMPILE_WEBKIT
     if (BUILD_CLOSED && COMPILE_GSTREAMER) {
         compileJava.dependsOn compileMediaJava
         compileJava.classpath += files(
@@ -2474,9 +2474,20 @@
         }
     }
 
-    if (COMPILE_WEBKIT) {
-        jar.dependsOn compileGenerated
+    task copyClassesFromBinaryStub << {
+        copy {
+            from zipTree(BINARY_STUB.getSingleFile())
+            into "build/classes/main"
+            include("javafx/scene/web/**",
+                "com/sun/javafx/scene/web/**",
+                "com/sun/webkit/**",
+                "com/sun/javafx/webkit/**",
+                "netscape/javascript/**",
+                "com/sun/javafx/sg/prism/NGWebView*")
+        }
     }
+
+    jar.dependsOn (COMPILE_WEBKIT ? compileGenerated : copyClassesFromBinaryStub)
     
     clean << {
         project.delete(