public abstract void onClick (DialogInterface dialog, int which)
Since: API Level 1
This method will be invoked when a button in the dialog is clicked.
Parameters
dialog The dialog that received the click.
which The button that was clicked (e.g. BUTTON1) or the position of the item clicked.
不过这个还是来响应button的,实现不了你的要求
Dialog dialog = new Dialog(mContext){
public void dialog.setOnClickListener(OnClickListener() {
public void onClick() {
// Add something you want to do
}
});