forked from I2P_Developers/i2p.i2p
- Fix spacing in summary bar
- Add start() in UpdateTask so things happen in the right order - Add toString() in UpdateTask for better debugging - Fix getID() for plugin UpdateTasks
This commit is contained in:
@ -47,7 +47,6 @@ class UpdateHandler implements Updater {
|
||||
return null;
|
||||
UpdateRunner update = new UpdateRunner(_context, _umgr, _smgr, updateSources, newVersion);
|
||||
_umgr.notifyProgress(update, "<b>" + _smgr.util().getString("Updating") + "</b>");
|
||||
update.start();
|
||||
return update;
|
||||
}
|
||||
}
|
||||
|
@ -77,11 +77,6 @@ class UpdateRunner implements UpdateTask, CompleteListener {
|
||||
* If it is, get the whole thing.
|
||||
*/
|
||||
private void update() {
|
||||
if (_urls.isEmpty()) {
|
||||
_umgr.notifyTaskFailed(this, "", null);
|
||||
return;
|
||||
}
|
||||
|
||||
for (URI uri : _urls) {
|
||||
_currentURI = uri;
|
||||
String updateURL = uri.toString();
|
||||
@ -102,7 +97,9 @@ class UpdateRunner implements UpdateTask, CompleteListener {
|
||||
new Timeout();
|
||||
break;
|
||||
}
|
||||
} catch (IllegalArgumentException iae) {}
|
||||
} catch (IllegalArgumentException iae) {
|
||||
_log.error("Invalid update URL", iae);
|
||||
}
|
||||
}
|
||||
if (_snark == null)
|
||||
fatal("No valid URLs");
|
||||
@ -232,4 +229,9 @@ class UpdateRunner implements UpdateTask, CompleteListener {
|
||||
private void updateStatus(String s) {
|
||||
_umgr.notifyProgress(this, s);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return getClass().getName() + ' ' + getType() + ' ' + getID() + ' ' + getMethod() + ' ' + getURI();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user