use of de.westnordost.streetcomplete.view.dialogs.AlertDialogBuilder in project StreetComplete by westnordost.
the class AddRoadSurfaceForm method onClickOk.
@Override
protected void onClickOk() {
final Bundle answer = new Bundle();
Item surface = getSelectedItem();
if (surface != null) {
answer.putString(SURFACE, surface.value);
if (surface.isGroup()) {
new AlertDialogBuilder(getContext()).setMessage(R.string.quest_surface_generic_surface_confirmation).setNegativeButton(R.string.quest_generic_confirmation_no, null).setPositiveButton(R.string.quest_generic_confirmation_yes, (dialog, which) -> applyFormAnswer(answer)).show();
return;
}
}
applyFormAnswer(answer);
}
Aggregations