From 9aa83a152715ed396d32ad31df55ffea834fda6c Mon Sep 17 00:00:00 2001 From: Skalaw Date: Sat, 25 Feb 2017 09:29:05 +0100 Subject: [PATCH] Fix issue #13 --- .../github/florent37/camerafragment/sample/MainActivity.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/com/github/florent37/camerafragment/sample/MainActivity.java b/app/src/main/java/com/github/florent37/camerafragment/sample/MainActivity.java index 83de9c4..c3589b7 100644 --- a/app/src/main/java/com/github/florent37/camerafragment/sample/MainActivity.java +++ b/app/src/main/java/com/github/florent37/camerafragment/sample/MainActivity.java @@ -159,7 +159,7 @@ public class MainActivity extends AppCompatActivity { .setCamera(Configuration.CAMERA_FACE_REAR).build()); getSupportFragmentManager().beginTransaction() .replace(R.id.content, cameraFragment, FRAGMENT_TAG) - .commit(); + .commitAllowingStateLoss(); if (cameraFragment != null) { //cameraFragment.setResultListener(new CameraFragmentResultListener() {