remove deprecation

This commit is contained in:
Milos Kozak 2020-06-01 00:06:05 +02:00
parent 55bccafef5
commit 4efeb77fdc
5 changed files with 4 additions and 21 deletions

View file

@ -95,13 +95,12 @@ public class AapsOmnipodManager implements OmnipodCommunicationManagerInterface
private final OmnipodManager delegate;
@Deprecated
//TODO: remove and use injection
private static AapsOmnipodManager instance;
private Date lastBolusTime;
private Double lastBolusUnits;
@Deprecated
public static AapsOmnipodManager getInstance() {
return instance;
}

View file

@ -7,7 +7,6 @@ import java.util.Date;
import info.nightscout.androidaps.data.DetailedBolusInfo;
import info.nightscout.androidaps.data.PumpEnactResult;
import info.nightscout.androidaps.logging.L;
import info.nightscout.androidaps.logging.LTag;
import info.nightscout.androidaps.plugins.bus.RxBusWrapper;
import info.nightscout.androidaps.plugins.pump.omnipod.defs.OmnipodPumpPluginInterface;
@ -103,7 +102,7 @@ public class OmnipodUIPostprocessor {
private boolean isLogEnabled() {
return L.isEnabled(LTag.PUMP);
return true; //L.isEnabled(LTag.PUMP);
}
public RxBusWrapper getRxBus() {

View file

@ -12,19 +12,7 @@ class L @Inject constructor(
private var logElements: MutableList<LogElement> = ArrayList()
companion object {
@Deprecated("Use Dagger")
lateinit var instance: L
@Deprecated("Use Dagger")
@JvmStatic
fun isEnabled(ltag: LTag): Boolean {
return instance.findByName(ltag.name).enabled
}
}
init {
instance= this
LTag.values().forEach { logElements.add(LogElement(it, sp)) }
}
@ -46,7 +34,7 @@ class L @Inject constructor(
}
class LogElement {
var sp : SP
var sp: SP
var name: String
var defaultValue: Boolean
var enabled: Boolean

View file

@ -232,8 +232,7 @@ public class NSUpload {
deviceStatus.enacted.put("requested", requested);
}
} else {
if (L.isEnabled(LTag.NSCLIENT))
aapsLogger.debug("OpenAPS data too old to upload, sending iob only");
aapsLogger.debug(LTag.NSCLIENT, "OpenAPS data too old to upload, sending iob only");
IobTotal[] iob = iobCobCalculatorPlugin.calculateIobArrayInDia(profile);
if (iob.length > 0) {
deviceStatus.iob = iob[0].json();

View file

@ -38,8 +38,6 @@ object LocaleHelper {
val configuration = resources.configuration
context.createConfigurationContext(configuration)
configuration.setLocale(locale)
configuration.locale = locale
resources.updateConfiguration(configuration, resources.displayMetrics)
}
fun wrap(ctx: Context): Context {