Skip to content

Instantly share code, notes, and snippets.

@Shivamdhuria
Last active August 18, 2020 15:13
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/4e30f891c46238c9a44516512c4559ce to your computer and use it in GitHub Desktop.
Save Shivamdhuria/4e30f891c46238c9a44516512c4559ce to your computer and use it in GitHub Desktop.
class DogDetailFragment : Fragment(R.layout.dog_detail_fragment) {
private val args: DogDetailFragmentArgs by navArgs()
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
super.onViewCreated(view, savedInstanceState)
val (imageUrl, breed) = args
ImageLoader.loadImage(requireContext(), imageUrl, image_dog_detail)
textview_dog_breed.text = breed
//Set the unique transition name to the "end" view
detail_container.transitionName = imageUrl
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment