0
materialDialog.dismiss()
をDialogAdapter(mContext,nListId,(ArrayList<String>)imagelist)
の中に呼び出す方法です。そのため、ダイアログボックスはアダプタ経由で終了しますか? Dialogadapter
にパラメータとしてmaterialDialog
を渡そうとしましたが、OnBindViewHolder()
にmaterialDialog.dismiss()
を呼び出すと、NULLポインタ例外が発生します。 これは、材料ダイアログライブラリーへのリンクです:https://github.com/afollestad/material-dialogsそれは呼び出しているアダプタからマテリアルダイアログ(通販)を解除するにはどうすればいいですか?
materialDialog = new MaterialDialog.Builder(mContext)
.title("Choose Node")
.adapter(new DialogAdapter(mContext,nListId,(ArrayList<String>)imagelist,materialDialog), null)
.positiveText("YES")
.negativeText("CANCEL")
.build();
.show();
のリスナーを使用することができます。十分な[評判](https://stackoverflow.com/help/whats-reputation)があれば、[投稿にコメントする]ことができます(https://stackoverflow.com/help/privileges/comment)。代わりに、[質問者からの明確化を必要としない回答を提供する](https://meta.stackexchange.com/questions/214173/why-do-i-need-50-reputation-to-comment-what-can- i-do-代わりに)。 - [レビューの投稿](/レビュー/低品質の投稿/ 17174077) –