Search in sources :

Example 1 with StandardBolusMessage

use of sugar.free.sightparser.applayer.messages.remote_control.StandardBolusMessage in project SightRemote by TebbeUbben.

the class StandardBolusActivity method onClick.

@Override
public void onClick(View view) {
    StandardBolusMessage message = new StandardBolusMessage();
    message.setAmount(bolusAmountPicker.getPickerValue());
    final SingleMessageTaskRunner taskRunner = new SingleMessageTaskRunner(getServiceConnector(), message);
    (confirmationDialog = new ConfirmationDialog(this, HTMLUtil.getHTML(R.string.standard_bolus_confirmation, UnitFormatter.formatUnits(bolusAmountPicker.getPickerValue())), () -> {
        showLoadingIndicator();
        taskRunner.fetch(StandardBolusActivity.this);
    })).show();
}
Also used : StandardBolusMessage(sugar.free.sightparser.applayer.messages.remote_control.StandardBolusMessage) SingleMessageTaskRunner(sugar.free.sightparser.handling.SingleMessageTaskRunner) ConfirmationDialog(sugar.free.sightremote.dialogs.ConfirmationDialog)

Aggregations

StandardBolusMessage (sugar.free.sightparser.applayer.messages.remote_control.StandardBolusMessage)1 SingleMessageTaskRunner (sugar.free.sightparser.handling.SingleMessageTaskRunner)1 ConfirmationDialog (sugar.free.sightremote.dialogs.ConfirmationDialog)1