diff options
Diffstat (limited to 'photoviewer')
-rw-r--r-- | photoviewer/src/com/android/ex/photo/fragments/PhotoViewFragment.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/photoviewer/src/com/android/ex/photo/fragments/PhotoViewFragment.java b/photoviewer/src/com/android/ex/photo/fragments/PhotoViewFragment.java index 97ea3b8..4e6296b 100644 --- a/photoviewer/src/com/android/ex/photo/fragments/PhotoViewFragment.java +++ b/photoviewer/src/com/android/ex/photo/fragments/PhotoViewFragment.java @@ -166,7 +166,10 @@ public class PhotoViewFragment extends Fragment implements super.onCreate(savedInstanceState); if (savedInstanceState != null) { - mIntent = new Intent().putExtras(savedInstanceState.getBundle(STATE_INTENT_KEY)); + final Bundle state = savedInstanceState.getBundle(STATE_INTENT_KEY); + if (state != null) { + mIntent = new Intent().putExtras(state); + } } mResolvedPhotoUri = mIntent.getStringExtra(Intents.EXTRA_RESOLVED_PHOTO_URI); |