diff --git a/core/java/android/app/DialogFragment.java b/core/java/android/app/DialogFragment.java index 2fb8cc207da80..9caf752abe4e3 100644 --- a/core/java/android/app/DialogFragment.java +++ b/core/java/android/app/DialogFragment.java @@ -230,6 +230,15 @@ public class DialogFragment extends Fragment ft.commit(); } + /** {@hide} */ + public void showAllowingStateLoss(FragmentManager manager, String tag) { + mDismissed = false; + mShownByMe = true; + FragmentTransaction ft = manager.beginTransaction(); + ft.add(this, tag); + ft.commitAllowingStateLoss(); + } + /** * Display the dialog, adding the fragment using an existing transaction * and then committing the transaction.