Code example for DialogFragment

Methods: onAttach

0
 
        @Override 
        public void onAttach(Activity activity) {
            transcript.add("onAttach");
            onAttachActivity = activity;
            super.onAttach(activity);
        } 
 
        @Override 
        public void onCreate(Bundle savedInstanceState) {
            transcript.add("onCreate");
            super.onCreate(savedInstanceState);
        } 
 
        @Override 
        public Dialog onCreateDialog(Bundle savedInstanceState) {
            transcript.add("onCreateDialog");
            return returnThisDialogFromOnCreateDialog == null
                    ? super.onCreateDialog(savedInstanceState)
                    : returnThisDialogFromOnCreateDialog;
        }