Skip to content

Instantly share code, notes, and snippets.

@Shivamdhuria
Created August 18, 2020 16:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Shivamdhuria/403074e823a3f7523b91df3f009b7926 to your computer and use it in GitHub Desktop.
Save Shivamdhuria/403074e823a3f7523b91df3f009b7926 to your computer and use it in GitHub Desktop.
override fun itemClickedClicked(view: View, dog: Dog) {
exitTransition = Hold().apply {
duration = resources.getInteger(R.integer.motion_duration_large).toLong()
}
reenterTransition = MaterialElevationScale(true).apply {
duration = resources.getInteger(R.integer.motion_duration_small).toLong()
}
val toDogDetailsFragment = DogListFragmentDirections.actionDogListFragmentToDogDetailFragment(dog.imageUrl.toString(), dog.breed)
val extras = FragmentNavigatorExtras(view to dog.imageUrl.toString())
navigate(toDogDetailsFragment, extras)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment