forked from I2P_Developers/i2p.i2p
Update: Preliminary work for su3 router updates:
- new ROUTER_SIGNED_SU3 UpdateType - Add support for torrent and HTTP - Refactor UpdateRunners to return actual UpdateType - Deal with signed/su3 conflicts - unpack/verify stubbed only
This commit is contained in:
@@ -49,6 +49,7 @@ public class NewsHelper extends ContentHelper {
|
||||
ConsoleUpdateManager mgr = ConsoleUpdateManager.getInstance();
|
||||
if (mgr == null) return false;
|
||||
return mgr.isUpdateInProgress(ROUTER_SIGNED) ||
|
||||
mgr.isUpdateInProgress(ROUTER_SIGNED_SU3) ||
|
||||
mgr.isUpdateInProgress(ROUTER_UNSIGNED) ||
|
||||
mgr.isUpdateInProgress(TYPE_DUMMY);
|
||||
}
|
||||
@@ -60,7 +61,8 @@ public class NewsHelper extends ContentHelper {
|
||||
public static boolean isUpdateAvailable() {
|
||||
ConsoleUpdateManager mgr = ConsoleUpdateManager.getInstance();
|
||||
if (mgr == null) return false;
|
||||
return mgr.getUpdateAvailable(ROUTER_SIGNED) != null;
|
||||
return mgr.getUpdateAvailable(ROUTER_SIGNED) != null ||
|
||||
mgr.getUpdateAvailable(ROUTER_SIGNED_SU3) != null;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -71,6 +73,9 @@ public class NewsHelper extends ContentHelper {
|
||||
public static String updateVersion() {
|
||||
ConsoleUpdateManager mgr = ConsoleUpdateManager.getInstance();
|
||||
if (mgr == null) return null;
|
||||
String rv = mgr.getUpdateAvailable(ROUTER_SIGNED_SU3);
|
||||
if (rv != null)
|
||||
return rv;
|
||||
return mgr.getUpdateAvailable(ROUTER_SIGNED);
|
||||
}
|
||||
|
||||
@@ -82,6 +87,9 @@ public class NewsHelper extends ContentHelper {
|
||||
public static String updateVersionDownloaded() {
|
||||
ConsoleUpdateManager mgr = ConsoleUpdateManager.getInstance();
|
||||
if (mgr == null) return null;
|
||||
String rv = mgr.getUpdateDownloaded(ROUTER_SIGNED_SU3);
|
||||
if (rv != null)
|
||||
return rv;
|
||||
return mgr.getUpdateDownloaded(ROUTER_SIGNED);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user