SimpleAlertDialog-for-Android icon indicating copy to clipboard operation
SimpleAlertDialog-for-Android copied to clipboard

Single choice dialog doesn't call onCreateSingleChoiceArray

Open pablobaldez opened this issue 9 years ago • 1 comments

my fragment implements SimpleAlertDialog.SingleChoiceArrayItemProvider and i call a dialog with this code:

new SimpleAlertDialogFragment.Builder()
                .setTitle(BUTTON_MENU_LABEL.get(v.getId()))
                .setSingleChoiceCheckedItem(0)
                .setRequestCode(ENABLE_DISABLE_DIALOG_REQUEST_CODE)
                .create()
                .show(getFragmentManager(), "tag");

can i try other approach?

pablobaldez avatar May 14 '15 15:05 pablobaldez

Maybe you should add .setTargetFragment(fragmentObject) in builder chain. (Replace fragmentObject to your fragment object.) SimpleAlertDialog must know the target object (dialog's parent), and this method will tell it.

ksoichiro avatar May 15 '15 12:05 ksoichiro