Search in sources :

Example 1 with InfoParameter

use of com.biglybt.pif.ui.config.InfoParameter in project BiglyBT by BiglySoftware.

the class ConfigSectionBackupRestoreSWT method updateInfoParams.

private static void updateInfoParams(BackupManager backup_manager, Map<String, ParameterImpl> mapParams) {
    InfoParameter paramInfoLastTime = (InfoParameter) mapParams.get(ConfigSectionBackupRestoreSWT.PP_BACKUP_LAST_TIME);
    InfoParameter paramInfoLastErr = (InfoParameter) mapParams.get(ConfigSectionBackupRestoreSWT.PP_BACKUP_LAST_ERR);
    if (paramInfoLastErr != null && paramInfoLastTime != null) {
        long backup_time = backup_manager.getLastBackupTime();
        paramInfoLastTime.setValue(backup_time == 0 ? "" : String.valueOf(new Date(backup_time)));
        paramInfoLastErr.setValue(backup_manager.getLastBackupError());
    }
}
Also used : InfoParameter(com.biglybt.pif.ui.config.InfoParameter) Date(java.util.Date)

Aggregations

InfoParameter (com.biglybt.pif.ui.config.InfoParameter)1 Date (java.util.Date)1