- Timestamp:
- Mar 26, 2013, 6:26:41 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
java/installer2/src/net/oni2/aeinstaller/backend/packages/Package.java
r720 r749 14 14 import net.oni2.aeinstaller.backend.CaseInsensitiveFile; 15 15 import net.oni2.aeinstaller.backend.Paths; 16 import net.oni2.aeinstaller.backend.depot.DepotConfig; 17 import net.oni2.aeinstaller.backend.depot.DepotManager; 18 import net.oni2.aeinstaller.backend.depot.model.NodeMod; 19 import net.oni2.aeinstaller.backend.depot.model.TaxonomyTerm; 20 import net.oni2.aeinstaller.backend.oni.Installer; 16 import net.oni2.aeinstaller.backend.oni.management.ToolsManager; 17 import net.oni2.moddepot.DepotConfig; 18 import net.oni2.moddepot.ECompatiblePlatform; 19 import net.oni2.moddepot.model.NodeMod; 21 20 import net.oni2.platformtools.PlatformInformation; 22 21 import net.oni2.platformtools.PlatformInformation.Platform; … … 43 42 private int zipSize = 0; 44 43 private NodeMod node = null; 45 private net.oni2. aeinstaller.backend.depot.model.File file = null;44 private net.oni2.moddepot.model.File file = null; 46 45 47 46 private File exeFile = null; … … 68 67 platform = nm.getPlatform(); 69 68 tool = nm.isTool(); 70 for ( TaxonomyTerm tt: nm.getTypes()) {71 Type t = PackageManager.getInstance().getTypeByName( tt.getName());69 for (String nType : nm.getTypes()) { 70 Type t = PackageManager.getInstance().getTypeByName(nType); 72 71 types.add(t); 73 72 if (!tool && !isCorePackage() && isValidOnPlatform()) … … 82 81 description = "<p>" + description + "</p>"; 83 82 } 84 file = DepotManager.getInstance().getFile( 85 nm.getUploads().firstElement().getFid()); 83 file = nm.getUploads().firstElement(); 86 84 zipSize = file.getFilesize(); 87 85 … … 107 105 */ 108 106 public void updateLocalData() { 109 File config = CaseInsensitiveFile.getCaseInsensitiveFile(getLocalPath(), "Mod_Info.cfg"); 107 File config = CaseInsensitiveFile.getCaseInsensitiveFile( 108 getLocalPath(), "Mod_Info.cfg"); 110 109 File aeicfg = new File(getLocalPath(), "aei.cfg"); 111 File plain = CaseInsensitiveFile.getCaseInsensitiveFile(getLocalPath(), "plain"); 110 File plain = CaseInsensitiveFile.getCaseInsensitiveFile(getLocalPath(), 111 "plain"); 112 112 if (config.exists()) { 113 113 Mod_Info mi = new Mod_Info(config, packageNumber); … … 230 230 public boolean isInstalled() { 231 231 if (tool) 232 return Installer.getInstalledTools().contains(packageNumber);232 return ToolsManager.getInstalledTools().contains(packageNumber); 233 233 else 234 234 return PackageManager.getInstance().isModInstalled(this); … … 323 323 */ 324 324 public boolean isCorePackage() { 325 return packageNumber < DepotConfig. getCoreNumberLimit();325 return packageNumber < DepotConfig.corePackageNumberLimit; 326 326 } 327 327 … … 329 329 * @return Get the depot file entry 330 330 */ 331 public net.oni2. aeinstaller.backend.depot.model.File getFile() {331 public net.oni2.moddepot.model.File getFile() { 332 332 return file; 333 333 }
Note:
See TracChangeset
for help on using the changeset viewer.