Search in sources :

Example 6 with PrefsViewImpl

use of com.eveningoutpost.dexdrip.UtilityModels.PrefsViewImpl in project xDrip by NightscoutFoundation.

the class DoubleCalibrationActivity method onCreate.

@Override
protected void onCreate(Bundle savedInstanceState) {
    xdrip.checkForcedEnglish(this);
    super.onCreate(savedInstanceState);
    if (CollectionServiceStarter.isBTShare(getApplicationContext())) {
        Intent intent = new Intent(this, Home.class);
        startActivity(intent);
        finish();
    }
    ActivityDoubleCalibrationBinding binding = ActivityDoubleCalibrationBinding.inflate(getLayoutInflater());
    binding.setPrefs(new PrefsViewImpl());
    setContentView(binding.getRoot());
    addListenerOnButton();
}
Also used : PrefsViewImpl(com.eveningoutpost.dexdrip.UtilityModels.PrefsViewImpl) ActivityDoubleCalibrationBinding(com.eveningoutpost.dexdrip.databinding.ActivityDoubleCalibrationBinding) Intent(android.content.Intent)

Example 7 with PrefsViewImpl

use of com.eveningoutpost.dexdrip.UtilityModels.PrefsViewImpl in project xDrip by NightscoutFoundation.

the class DepositActivity method onCreate.

@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) {
        binding = ActivityDepositActivityBinding.inflate(getLayoutInflater());
        binding.setVm(new ViewModel(this));
        binding.setPrefs(new PrefsViewImpl());
        setContentView(binding.getRoot());
        JoH.fixActionBar(this);
    } else {
        JoH.static_toast_long("Needs Android 7+");
        finish();
    }
}
Also used : PrefsViewImpl(com.eveningoutpost.dexdrip.UtilityModels.PrefsViewImpl)

Example 8 with PrefsViewImpl

use of com.eveningoutpost.dexdrip.UtilityModels.PrefsViewImpl in project xDrip-plus by jamorham.

the class DepositActivity method onCreate.

@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) {
        binding = ActivityDepositActivityBinding.inflate(getLayoutInflater());
        binding.setVm(new ViewModel(this));
        binding.setPrefs(new PrefsViewImpl());
        setContentView(binding.getRoot());
        JoH.fixActionBar(this);
    } else {
        JoH.static_toast_long("Needs Android 7+");
        finish();
    }
}
Also used : PrefsViewImpl(com.eveningoutpost.dexdrip.UtilityModels.PrefsViewImpl)

Aggregations

PrefsViewImpl (com.eveningoutpost.dexdrip.UtilityModels.PrefsViewImpl)8 AlertDialog (android.app.AlertDialog)2 ActivityNotFoundException (android.content.ActivityNotFoundException)2 Intent (android.content.Intent)2 BgGraphBuilder (com.eveningoutpost.dexdrip.UtilityModels.BgGraphBuilder)2 ActivityDisplayQrcodeBinding (com.eveningoutpost.dexdrip.databinding.ActivityDisplayQrcodeBinding)2 ActivityDoubleCalibrationBinding (com.eveningoutpost.dexdrip.databinding.ActivityDoubleCalibrationBinding)2 MicroStatusImpl (com.eveningoutpost.dexdrip.ui.MicroStatusImpl)2 GsonBuilder (com.google.gson.GsonBuilder)2 IOException (java.io.IOException)2 ParseException (java.text.ParseException)2