- Timestamp:
- Jan 23, 2013, 12:43:13 PM (12 years ago)
- Location:
- AE/installer2/src/net/oni2/aeinstaller/backend/mods/download
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
AE/installer2/src/net/oni2/aeinstaller/backend/mods/download/ModDownloader.java
r638 r646 73 73 if ((state == State.RUNNING) && (currentDownload < downloads.size())) { 74 74 downloads.get(currentDownload).start(); 75 } else if (state == State.RUNNING) {75 } else if (state == State.RUNNING) { 76 76 state = State.LAST_FILE_DOWNLOADED; 77 77 notifyListener(); … … 102 102 103 103 private void notifyListener() { 104 listener.updateStatus(this, state, unpacked, downloads.size(), 105 downloadedComplete + downloadedCurrent, totalSize, 106 getTimeElapsed(), getTimeRemaining(), getDownloadSpeed()); 104 if (currentDownload < downloads.size()) { 105 listener.updateStatus(this, 106 downloads.get(currentDownload).getMod(), state, unpacked, 107 downloads.size(), downloadedComplete + downloadedCurrent, 108 totalSize, getTimeElapsed(), getTimeRemaining(), 109 getDownloadSpeed()); 110 } else { 111 listener.updateStatus(this, null, state, unpacked, 112 downloads.size(), downloadedComplete + downloadedCurrent, 113 totalSize, getTimeElapsed(), getTimeRemaining(), 114 getDownloadSpeed()); 115 } 107 116 } 108 117 -
AE/installer2/src/net/oni2/aeinstaller/backend/mods/download/ModDownloaderListener.java
r605 r646 1 1 package net.oni2.aeinstaller.backend.mods.download; 2 2 3 import net.oni2.aeinstaller.backend.mods.Mod; 3 4 import net.oni2.aeinstaller.backend.mods.download.ModDownloader.State; 4 5 … … 12 13 * @param source 13 14 * Event source 15 * @param currentDownload 16 * Currently downloading mod 14 17 * @param state 15 18 * Current state … … 29 32 * Average download speed in B/s 30 33 */ 31 public void updateStatus(ModDownloader source, State state, int filesDown,32 int filesTotal, int bytesDown, int bytesTotal, int duration,33 int remaining, int speed);34 public void updateStatus(ModDownloader source, Mod currentDownload, 35 State state, int filesDown, int filesTotal, int bytesDown, 36 int bytesTotal, int duration, int remaining, int speed); 34 37 }
Note:
See TracChangeset
for help on using the changeset viewer.