Changeset 730 for java/installer2/src
- Timestamp:
- Mar 21, 2013, 6:25:39 PM (12 years ago)
- Location:
- java/installer2/src/net/oni2/aeinstaller
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
java/installer2/src/net/oni2/aeinstaller/AEInstaller.properties
r720 r730 1 1 appname=AE Installer 2 2 appversion=0.99 v2 appversion=0.99w -
java/installer2/src/net/oni2/aeinstaller/AEInstaller2.java
r720 r730 32 32 import net.oni2.platformtools.PlatformInformation; 33 33 import net.oni2.platformtools.PlatformInformation.Platform; 34 import net.oni2.platformtools.applicationinvoker.ApplicationInvoker; 34 35 import net.oni2.platformtools.applicationinvoker.DotNet; 36 import net.oni2.platformtools.applicationinvoker.EExeType; 37 import net.oni2.svnaccess.SVN; 35 38 36 39 import org.javabuilders.swing.SwingJavaBuilder; … … 64 67 } 65 68 } 66 69 67 70 private static void initBundles() { 68 File localesDir = CaseInsensitiveFile.getCaseInsensitiveFile(Paths.getInstallerPath(), "locales"); 71 File localesDir = CaseInsensitiveFile.getCaseInsensitiveFile( 72 Paths.getInstallerPath(), "locales"); 69 73 if (localesDir.isDirectory()) 70 74 addClassPath(localesDir); … … 121 125 } 122 126 } 123 127 124 128 initBundles(); 125 129 … … 173 177 System.out.println("ValidPath: " + Installer.verifyRunningDirectory()); 174 178 System.out.println("Platform: " + PlatformInformation.getPlatform()); 175 System.out.println("Architect: " + PlatformInformation.getArchitecture()); 179 System.out.println("Architect: " 180 + PlatformInformation.getArchitecture()); 176 181 System.out.println(".NET: " + DotNet.isInstalled()); 177 182 System.out.println("OniSplit: " + OniSplit.isOniSplitInstalled()); … … 241 246 SettingsManager.getInstance().setOfflineMode(offline); 242 247 248 if (!offline) { 249 SVN svn = new SVN(); 250 try { 251 int x = svn.checkSVN("http://svn.aei.oni2.net", 252 new File(Paths.getPrefsPath(), "bin")); 253 if (x > 0) { 254 // Update available 255 int res = JOptionPane.showConfirmDialog(null, 256 globalBundle.getString("aeiUpdateAvailable.text"), 257 globalBundle.getString("aeiUpdateAvailable.title"), 258 JOptionPane.YES_NO_OPTION, 259 JOptionPane.INFORMATION_MESSAGE); 260 if (res == JOptionPane.YES_OPTION) { 261 File updater = new File(Paths.getInstallerPath(), 262 "AEInstaller2Updater.jar"); 263 ApplicationInvoker.execute(EExeType.JAR, null, updater, 264 null); 265 return; 266 } 267 } else if (x == 0) { 268 // Up to date 269 } else if (x < 0) { 270 // No WC at given path 271 } 272 } catch (Exception e) { 273 e.printStackTrace(); 274 } 275 } 276 243 277 SwingUtilities.invokeLater(new Runnable() { 244 278 public void run() { -
java/installer2/src/net/oni2/aeinstaller/backend/Paths.java
r720 r730 36 36 return new File(wd); 37 37 } else { 38 String jarPath = SettingsManager.class.getProtectionDomain()38 String jarPath = Paths.class.getProtectionDomain() 39 39 .getCodeSource().getLocation().getPath(); 40 40 String decodedPath = null; … … 44 44 e.printStackTrace(); 45 45 } 46 return new File(decodedPath).getParentFile() ;46 return new File(decodedPath).getParentFile().getParentFile(); 47 47 } 48 48 } -
java/installer2/src/net/oni2/aeinstaller/localization/Global.properties
r658 r730 10 10 offlineModeStartup.title=Offline mode 11 11 offlineModeStartup.text=Connection to the ModDepot could not be established.\nAEI will run in offline mode.\nUpdates or installation of mods not already downloaded will not be possible. 12 13 aeiUpdateAvailable.title=Update available! 14 aeiUpdateAvailable.text=An update for the AEInstaller is available.\nPlease update now by selecting Yes.
Note:
See TracChangeset
for help on using the changeset viewer.