[org-vaadin-support~subversion:26] For pre 2.0 versions of GWT, download an OS-specific GWT dev JAR,

  • From: GWiel@kenai.com
  • To: commits@org-vaadin-support.kenai.com
  • Subject: [org-vaadin-support~subversion:26] For pre 2.0 versions of GWT, download an OS-specific GWT dev JAR,
  • Date: Sun, 17 Oct 2010 21:34:31 +0000

Project:    org-vaadin-support
Repository: subversion
Revision:   26
Author:     GWiel
Date:       2010-10-17 21:34:30 UTC
Link:       

Log Message:
------------
For pre 2.0 versions of GWT, download an OS-specific GWT dev JAR,


Revisions:
----------
26


Modified Paths:
---------------
VaadinFramework/src/org/vaadin/framework/VaadinConfigurationPanelVisual.java


Diffs:
------
Index: 
VaadinFramework/src/org/vaadin/framework/VaadinConfigurationPanelVisual.java
===================================================================
--- 
VaadinFramework/src/org/vaadin/framework/VaadinConfigurationPanelVisual.java  
      (revision 25)
+++ 
VaadinFramework/src/org/vaadin/framework/VaadinConfigurationPanelVisual.java  
      (revision 26)
@@ -318,7 +318,7 @@
         }
 
         public void run() {
-            
+
             ProgressHandle handle = ProgressHandleFactory.createHandle(
                     "Downloading " + vaadinFile.getName() + "...");
             handle.start();
@@ -328,7 +328,7 @@
                 Exceptions.printStackTrace(ex);
             }
             handle.finish();
-            
+
             chosenVersionModel.addElement(vaadinFile.getName());
             jListVersion.setSelectedValue(vaadinFile.getName(), true);
 
@@ -338,7 +338,6 @@
             URL gwtDevURL;
             try {
                 gwtUserURL = new 
URL("http://vaadin.com/download/external/gwt/" + gwtVersion + ;
"/gwt-user.jar");
-                gwtDevURL = new 
URL("http://vaadin.com/download/external/gwt/" + gwtVersion + "/gwt-dev.jar";);
                 FileObject gwtFolder = 
FileUtil.getConfigFile("VaadinSupportDownloads");
                 if (gwtFolder == null) {
                     
FileUtil.getConfigRoot().createFolder("VaadinSupportDownloads");
@@ -350,19 +349,31 @@
                 }
                 FileObject gwtUserJAR = 
FileUtil.getConfigFile("VaadinSupportDownloads/" + 
gwtVersion).getFileObject("gwt-user", "jar");
                 FileObject gwtDevJAR = 
FileUtil.getConfigFile("VaadinSupportDownloads/" + 
gwtVersion).getFileObject("gwt-dev", "jar");
-                //Create the file in the version folder if it doesn't exist:
+                //Create the user file in the version folder if it doesn't 
exist:
                 if (gwtUserJAR == null) {
                     gwtUserJAR = 
FileUtil.getConfigFile("VaadinSupportDownloads/" + 
gwtVersion).createData("gwt-user", "jar");
                     File gwtUserJARFile = FileUtil.toFile(gwtUserJAR);
                     Thread downloadGwtUserThread = new Thread(new 
DownloadGwtJarsRunnable(gwtVersion, gwtUserURL.toString(), gwtUserJARFile));
                     downloadGwtUserThread.start();
                 }
-                //Create the file in the version folder if it doesn't exist:
+                //Create the dev file in the version folder if it doesn't 
exist:
                 if (gwtDevJAR == null) {
-                    gwtDevJAR = 
FileUtil.getConfigFile("VaadinSupportDownloads/" + 
gwtVersion).createData("gwt-dev", "jar");
-                    File gwtDevJARFile = FileUtil.toFile(gwtDevJAR);
-                    Thread downloadGwtUserThread = new Thread(new 
DownloadGwtJarsRunnable(gwtVersion, gwtDevURL.toString(), gwtDevJARFile));
-                    downloadGwtUserThread.start();
+                    if (gwtVersion.startsWith("2")) {
+                        gwtDevURL = new 
URL("http://vaadin.com/download/external/gwt/" + gwtVersion + "/gwt-dev.jar";);
+                        gwtDevJAR = 
FileUtil.getConfigFile("VaadinSupportDownloads/" + 
gwtVersion).createData("gwt-dev", "jar");
+                        File gwtDevJARFile = FileUtil.toFile(gwtDevJAR);
+                        Thread downloadGwtUserThread = new Thread(new 
DownloadGwtJarsRunnable(gwtVersion, gwtDevURL.toString(), gwtDevJARFile));
+                        downloadGwtUserThread.start();
+                    } else {
+                        String[] devJars = new String[]{"gwt-dev-linux", 
"gwt-dev-mac", "gwt-dev-windows"};
+                        for (String devJar : devJars) {
+                            gwtDevURL = new 
URL("http://vaadin.com/download/external/gwt/" + gwtVersion + "/" + devJar + ;
".jar");
+                            gwtDevJAR = 
FileUtil.getConfigFile("VaadinSupportDownloads/" + 
gwtVersion).createData(devJar, "jar");
+                            File gwtDevJARFile = FileUtil.toFile(gwtDevJAR);
+                            Thread downloadGwtUserThread = new Thread(new 
DownloadGwtJarsRunnable(gwtVersion, gwtDevURL.toString(), gwtDevJARFile));
+                            downloadGwtUserThread.start();
+                        }
+                    }
                 }
             } catch (IOException ex) {
                 Exceptions.printStackTrace(ex);
@@ -467,7 +478,6 @@
         File folder = new File(jtFolder.getText());
         return folder;
     }
-    
     // Variables declaration - do not modify//GEN-BEGIN:variables
     private javax.swing.JButton downloadButton;
     private javax.swing.JComboBox jComboBoxURLPattern;





[org-vaadin-support~subversion:26] For pre 2.0 versions of GWT, download an OS-specific GWT dev JAR,

GWiel 10/17/2010
  • Mysql
  • Glassfish
  • Jruby
  • Rails
  • Nblogo
Terms of Use; Privacy Policy;
© 2010, Oracle Corporation and/or its affiliates
(revision 20120518.3c65429)
 
 
Close
loading
Please Confirm
Close