Skip to content

Commit

Permalink
[MOD/#301] SearchDialogDepartmentFragment warning 보완
Browse files Browse the repository at this point in the history
  • Loading branch information
minju1459 committed Oct 15, 2023
1 parent 6c3a841 commit db0b2fd
Showing 1 changed file with 10 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -144,14 +144,18 @@ class SearchDialogDepartmentFragment :
}

private fun recyclerviewScroll() {
binding.rvDepartmentList.setOnTouchListener { view, motionEvent ->
when (motionEvent.action) {
MotionEvent.ACTION_MOVE -> {
binding.layoutDepartmentDialog.requestDisallowInterceptTouchEvent(true)
binding.rvDepartmentList.addOnItemTouchListener(object : RecyclerView.OnItemTouchListener {
override fun onInterceptTouchEvent(rv: RecyclerView, e: MotionEvent): Boolean {
when (e.action) {
MotionEvent.ACTION_MOVE -> {
binding.layoutDepartmentDialog.requestDisallowInterceptTouchEvent(true)
}
}
return false
}
return@setOnTouchListener false
}
override fun onTouchEvent(rv: RecyclerView, e: MotionEvent) {}
override fun onRequestDisallowInterceptTouchEvent(disallowIntercept: Boolean) {}
})
}

override fun onDestroyView() {
Expand Down

0 comments on commit db0b2fd

Please sign in to comment.