recyclerviewhelper icon indicating copy to clipboard operation
recyclerviewhelper copied to clipboard

Allow swipe to dismiss to be cancelled from within the adapter

Open PawanHegde opened this issue 8 years ago • 1 comments

I have a view in the recyclerview that I'd like to be undismissable. While I'd prefer that I have an option to disable swipe to dismiss for particular views, I'd be okay with the swiped-away view bouncing back in if onItemDismiss returns false.

Currently onItemDismiss does not return anything. Maybe it could be made to return a boolean like onItemMove to indicate if the view should be dismissed or not.

PawanHegde avatar Aug 07 '16 17:08 PawanHegde

Hey, I know this is kinda late but for those who still need it just add notifyItemChanged(position); in onItemDismiss without deleting the element from your collection .

haithamsboui avatar Nov 18 '17 05:11 haithamsboui