I am using a RecyclerView with 2 view types. I want to handle click events on individual types seperately. I can do this within my Adapter, in the onBindViewHolder method. But one of my view type has to rerender the activity because it changes the RecyclerView data.
Basically it is a file explorer application, one view type is for Files, the other is for Folders. If user taps on Folders, I want to rerender the RecyclerView with "folder path".
I researched this issue, but I feel like I got lost with different onItemClickListener implementations for RecyclerView and invoking Activity methods from the adapter which I think it creates quite a mess.
ListView seems to be the way to go for my situation with its simple onItemClickListener method but it is not optimized as the RecyclerView.
What might be the cleanest approach for this?