< prev index next >

modules/jdk.packager/src/antplugin/java/com/sun/javafx/tools/ant/DeployFXTask.java

Print this page

        

@@ -238,33 +238,11 @@
                 deployParams.setSwingAppWithEmbeddedJavaFX(app.get().embeddedIntoSwing);
                 deployParams.setVersion(app.get().version);
                 deployParams.setId(app.get().id);
                 deployParams.setServiceHint(app.get().daemon);
 
-                if (runtime != null) {
-                    for (String s : runtime.getAddModules()) {
-                        deployParams.addAddModule(s);
-                    }
-
-                    for (String s : runtime.getLimitModules()) {
-                        deployParams.addLimitModule(s);
-                    }
-
-                    deployParams.setModulePath(runtime.getModulePath());
-
-                    Boolean stripNativeCommands = runtime.getStripNativeCommands();
-
-                    if (stripNativeCommands != null) {
-                        deployParams.setStripNativeCommands(stripNativeCommands);
-                    }
-
-                    Boolean detectModules = runtime.getDetectModules();
-
-                    if (detectModules != null) {
-                        deployParams.setDetectModules(detectModules);
-                    }
-                }
+                setRuntime();
             }
 
             if (appInfo != null) {
                 deployParams.setTitle(appInfo.title);
                 deployParams.setVendor(appInfo.vendor);

@@ -310,10 +288,12 @@
                 deployParams.setFallback(app.get().fallbackApp);
                 deployParams.setSwingAppWithEmbeddedJavaFX(app.get().embeddedIntoSwing);
                 deployParams.setVersion(app.get().version);
                 deployParams.setId(app.get().id);
                 deployParams.setServiceHint(app.get().daemon);
+
+                setRuntime();
             }
 
             if (appInfo != null) {
                 deployParams.setTitle(appInfo.title);
                 deployParams.setVendor(appInfo.vendor);

@@ -382,10 +362,36 @@
         } finally {
             Log.setLogger(null);
         }
     }
 
+    private void setRuntime() {
+        if (runtime != null) {
+            for (String s : runtime.getAddModules()) {
+                deployParams.addAddModule(s);
+            }
+
+            for (String s : runtime.getLimitModules()) {
+                deployParams.addLimitModule(s);
+            }
+
+            deployParams.setModulePath(runtime.getModulePath());
+
+            Boolean stripNativeCommands = runtime.getStripNativeCommands();
+
+            if (stripNativeCommands != null) {
+                deployParams.setStripNativeCommands(stripNativeCommands);
+            }
+
+            Boolean detectModules = runtime.getDetectModules();
+
+            if (detectModules != null) {
+                deployParams.setDetectModules(detectModules);
+            }
+        }
+    }
+
     /**
      * Set to true if we are generating an 'extension' JNLP.
      *
      * @ant.not-required Default is false.
      */
< prev index next >