Changeset 282 in josm for src/org/openstreetmap/josm/plugins/PluginDownloader.java
- Timestamp:
- 2007-07-08T00:32:06+02:00 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/org/openstreetmap/josm/plugins/PluginDownloader.java
r277 r282 75 75 } 76 76 77 public static voiddownloadPlugin(PluginDescription pd) {77 public static boolean downloadPlugin(PluginDescription pd) { 78 78 File file = new File(Main.pref.getPreferencesDir()+"plugins/"+pd.name+".jar"); 79 79 try { … … 85 85 out.close(); 86 86 in.close(); 87 try { 88 PluginInformation.findPlugin(pd.name); 89 return true; 90 } catch (Exception e) { 91 e.printStackTrace(); 92 JOptionPane.showMessageDialog(Main.parent, tr("The plugin {0} seem to be broken or could not be downloaded automatically.", pd.name)); 93 } 87 94 } catch (Exception e) { 88 if (file.exists())89 file.delete();90 95 JOptionPane.showMessageDialog(Main.parent, tr("Could not download plugin: {0} from {1}", pd.name, pd.resource)); 91 96 } 97 if (file.exists()) 98 file.delete(); 99 return false; 92 100 } 93 101 }
Note:
See TracChangeset
for help on using the changeset viewer.