Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix class not found when unmarshalling for Samsung devices #332

Merged
merged 1 commit into from
Jul 6, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
import android.graphics.RectF;
import android.net.Uri;
import android.os.Build;
import android.os.Bundle;
import android.os.Parcel;
import android.os.Parcelable;
import android.provider.MediaStore;
Expand Down Expand Up @@ -453,8 +454,10 @@ public Intent getIntent(@NonNull Context context, @Nullable Class<?> cls) {

Intent intent = new Intent();
intent.setClass(context, cls);
intent.putExtra(CROP_IMAGE_EXTRA_SOURCE, mSource);
intent.putExtra(CROP_IMAGE_EXTRA_OPTIONS, mOptions);
Bundle b = new Bundle();
b.putParcelable(CROP_IMAGE_EXTRA_SOURCE, mSource);
b.putParcelable(CROP_IMAGE_EXTRA_OPTIONS, mOptions);
intent.putExtra("bundle", b);
return intent;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,9 @@ public void onCreate(Bundle savedInstanceState) {

mCropImageView = (CropImageView) findViewById(R.id.cropImageView);

Intent intent = getIntent();
mCropImageUri = intent.getParcelableExtra(CropImage.CROP_IMAGE_EXTRA_SOURCE);
mOptions = intent.getParcelableExtra(CropImage.CROP_IMAGE_EXTRA_OPTIONS);
Bundle bundle = getIntent().getBundleExtra("bundle");
mCropImageUri = bundle.getParcelable(CropImage.CROP_IMAGE_EXTRA_SOURCE);
mOptions = bundle.getParcelable(CropImage.CROP_IMAGE_EXTRA_OPTIONS);

if (savedInstanceState == null) {
if (mCropImageUri == null || mCropImageUri.equals(Uri.EMPTY)) {
Expand Down