Code example for DialogFragment

Methods: onDetach

0
		} 
	} 
 
	@Override 
	public void onDetach() { 
		super.onDetach(); 
		this.listener = null;
	} 
 
	@Override 
	public Dialog onCreateDialog(Bundle savedInstanceState) {
		AlertDialog.Builder builder = new AlertDialog.Builder(
				this.getActivity());
		Bundle bundle = this.getArguments();
		int resId;
		if (Constants.AlarmTypeSign.SIGN_PLUS == bundle
				.getInt(Constants.ArgumentKey.SIGN)) {
			resId = R.string.targetDatePlusString;
		} else { 
			resId = R.string.targetDateMinusString;
		}