use of yuku.ambilwarna.AmbilWarnaDialog.OnAmbilWarnaListener in project KeepScore by nolanlawson.
the class DialogHelper method showCustomColorDialog.
private static void showCustomColorDialog(Context context, int initialColor, final Callback<PlayerColor> onColorChanged, final Runnable onColorSelected) {
AmbilWarnaDialog dialog = new AmbilWarnaDialog(context, initialColor, new OnAmbilWarnaListener() {
@Override
public void onOk(AmbilWarnaDialog dialog, int color) {
onColorChanged.onCallback(new CustomPlayerColor(color));
onColorSelected.run();
}
@Override
public void onCancel(AmbilWarnaDialog dialog) {
// do nothing
}
});
dialog.show();
}
Aggregations