Shared element activity transition on android 5

前端 未结 12 628
我寻月下人不归
我寻月下人不归 2021-01-30 13:20

I wanted to setup a shared element transition when going from one Activity to another.

The first Activity has a RecyclerView with items. When an item is clicked that it

12条回答
  •  醉酒成梦
    2021-01-30 13:53

    As @Fabio Rocha said, make sure that the itemView is retrieved from the ViewHolder.

    You can get the ViewHolder by position via

    mRecyclerView.findViewHolderForAdapterPosition(position);
    

提交回复
热议问题