SharedElement
Closed this issue · 2 comments
joxad commented
Hi,
I am currently using transition with SharedElement, and I have not found a way to add Options to make transition.
For exemple, if I want to share my icon user :
Intent intent = new Intent(context, ActivityUser.class);
ActivityOptionsCompat options = ActivityOptionsCompat.
makeSceneTransitionAnimation((Activity) context, binding.ivUser, context.getString(R.string.transition_activity_profile));
ActivityCompat.startActivity((Activity) context, intent, options.toBundle());
Is there a way to add something like :
activity.startActivity(Henson.with(activity).gotoActivityUser().withOptions(options).build());
dlemures commented
Hi @joxad ,
Henson is used to create the intent.
That bundle with options for the transition is not part of the Intent, so It has nothing to do with Henson:
Intent intent = Henson.with(activity).gotoActivityUser().build();
startActivity(intent, options.toBundle());
joxad commented
Ah yes stupid me ! TU