xDrip plugin depend filtering on source

This commit is contained in:
AdrianLxM 2018-04-19 17:44:52 +02:00 committed by GitHub
parent 6942a3d4b8
commit 938040ae6b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -12,6 +12,8 @@ import info.nightscout.androidaps.interfaces.PluginType;
public class SourceXdripPlugin extends PluginBase implements BgSourceInterface { public class SourceXdripPlugin extends PluginBase implements BgSourceInterface {
private static SourceXdripPlugin plugin = null; private static SourceXdripPlugin plugin = null;
boolean advancedFiltering;
public static SourceXdripPlugin getPlugin() { public static SourceXdripPlugin getPlugin() {
if (plugin == null) if (plugin == null)
@ -29,6 +31,10 @@ public class SourceXdripPlugin extends PluginBase implements BgSourceInterface {
@Override @Override
public boolean advancedFilteringSupported() { public boolean advancedFilteringSupported() {
return false; return advancedFiltering;
}
public void setSource(String source) {
this.advancedFiltering = "G5 Native".equals(source);
} }
} }