Search in sources :

Example 6 with DexCollectionType

use of com.eveningoutpost.dexdrip.utils.DexCollectionType in project xDrip-plus by jamorham.

the class MegaStatus method populateSectionList.

private void populateSectionList() {
    if (sectionList.isEmpty()) {
        addAsection("Classic Status Page", "Legacy System Status");
        final DexCollectionType dexCollectionType = DexCollectionType.getDexCollectionType();
        // probably want a DexCollectionService related set
        if (DexCollectionType.usesDexCollectionService(dexCollectionType)) {
            addAsection(G4_STATUS, "Bluetooth Collector Status");
        }
        if (dexCollectionType.equals(DexcomG5)) {
            if (Pref.getBooleanDefaultFalse(Ob1G5CollectionService.OB1G5_PREFS)) {
                addAsection(G5_STATUS, "OB1 G5/G6 Collector and Transmitter Status");
            } else {
                addAsection(G5_STATUS, "G5 Collector and Transmitter Status");
            }
        } else if (dexCollectionType.equals(Medtrum)) {
            addAsection(MEDTRUM_STATUS, "Medtrum A6 Status");
        }
        if (BlueJayEntry.isEnabled()) {
            addAsection(BLUEJAY_STATUS, "BlueJay Watch Status");
        }
        if (DexCollectionType.getDexCollectionType() == DexCollectionType.LibreReceiver) {
            addAsection(XDRIP_LIBRE2, "Libre 2 Patched App Status");
        }
        if (DexCollectionType.hasWifi()) {
            addAsection(IP_COLLECTOR, dexCollectionType == DexCollectionType.Mock ? "FAKE / MOCK DATA SOURCE" : "Wifi Wixel / Parakeet Status");
        }
        if (InPenEntry.isEnabled()) {
            addAsection(INPEN_STATUS, "InPen Status");
        }
        if (Home.get_master_or_follower()) {
            addAsection(XDRIP_PLUS_SYNC, "xDrip+ Sync Group");
        }
        if (Pref.getBooleanDefaultFalse("cloud_storage_mongodb_enable") || Pref.getBooleanDefaultFalse("cloud_storage_api_enable") || Pref.getBooleanDefaultFalse("share_upload") || (Pref.getBooleanDefaultFalse("wear_sync") && Home.get_engineering_mode())) {
            addAsection(UPLOADERS, "Cloud Uploader Queues");
        }
        if (LeFunEntry.isEnabled()) {
            addAsection(LEFUN_STATUS, "Lefun Watch Status");
        }
        if (MiBandEntry.isEnabled()) {
            addAsection(MIBAND_STATUS, "MiBand Watch Status");
        }
        if (dexCollectionType.equals(NSFollow)) {
            addAsection(NIGHTSCOUT_FOLLOW, "Nightscout Follow Status");
        }
        if (dexCollectionType.equals(SHFollow)) {
            addAsection(SHARE_FOLLOW, "Dex Share Follow Status");
        }
    // addAsection("Misc", "Currently Empty");
    } else {
        UserError.Log.d(TAG, "Section list already populated");
    }
}
Also used : DexCollectionType(com.eveningoutpost.dexdrip.utils.DexCollectionType)

Aggregations

DexCollectionType (com.eveningoutpost.dexdrip.utils.DexCollectionType)6 Activity (android.app.Activity)2 ActivityNotFoundException (android.content.ActivityNotFoundException)2 SharedPreferences (android.content.SharedPreferences)2 PowerManager (android.os.PowerManager)2 TextView (android.widget.TextView)2 UpdateActivity (com.eveningoutpost.dexdrip.UtilityModels.UpdateActivity)2 EmergencyAssistActivity (com.eveningoutpost.dexdrip.eassist.EmergencyAssistActivity)2 IOException (java.io.IOException)2 ParseException (java.text.ParseException)2 Date (java.util.Date)2