opening slide up bottomsheet by below code
VillazBottomSheet villazBottomSheet=new VillazBottomSheet(); villazBottomSheet.setArguments(bundle); villazBottomSheet.show(getSupportFragmentManager(),"VillazList");//slideup and open sheet
Now i want to slide down this fragment by backpressed
@Override public void onBackPressed() { villazBottomSheet.slidedown()// I want to do this }
How can I do this ? what i had tried
Try this:
BottomSheetBehavior.from(villazBottomSheet).setState(BottomSheetBehavior.STATE_COLLAPSED)
1.4m articles
1.4m replys
5 comments
57.0k users