AlertDialogに、データベースから選択された国のリストをカーソルで表示したいのですが、IDと国名を選択します。次のコードがありますが、選択したアイテムを取得する方法がわかりません。
AlertDialog.Builder ab=new AlertDialog.Builder(this);
ab.setTitle(R.string.msg_title_Pais_Resid);
Locale locale = Locale.getDefault();
final Cursor items = DaoProvider.getListaPaisesCursor(this, (locale.getLanguage()).toUpperCase());
ab.setCursor(items,new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialog, int which) {
//Here: get the selected item object (or id)
}
}, Internacionalizacion.colInternacionalizacionTraduccion)
ありがとう