From 6f3da83640173a624307ed28f1c9d6e997c204e9 Mon Sep 17 00:00:00 2001 From: Medhat Date: Sun, 7 Aug 2022 11:08:38 +0200 Subject: [PATCH] hide Veil recyclerView with gone --- .../java/com/skydoves/androidveil/VeilRecyclerFrameView.kt | 4 ++-- .../src/main/java/com/skydoves/androidveil/ViewExtension.kt | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/androidveil/src/main/java/com/skydoves/androidveil/VeilRecyclerFrameView.kt b/androidveil/src/main/java/com/skydoves/androidveil/VeilRecyclerFrameView.kt index a4fd6d3..a806328 100644 --- a/androidveil/src/main/java/com/skydoves/androidveil/VeilRecyclerFrameView.kt +++ b/androidveil/src/main/java/com/skydoves/androidveil/VeilRecyclerFrameView.kt @@ -248,14 +248,14 @@ class VeilRecyclerFrameView : RelativeLayout { private fun visibleVeilRecyclerView() { this.veiledRecyclerView.visible() this.veiledRecyclerView.bringToFront() - this.userRecyclerView.invisible() + this.userRecyclerView.gone() } /** Invisible veiledRecyclerView and Visible userRecyclerView. */ private fun visibleUserRecyclerView() { this.userRecyclerView.visible() this.userRecyclerView.bringToFront() - this.veiledRecyclerView.invisible() + this.veiledRecyclerView.gone() } /** Apply overscrollModel of parent to veiled and user recyclerview. */ diff --git a/androidveil/src/main/java/com/skydoves/androidveil/ViewExtension.kt b/androidveil/src/main/java/com/skydoves/androidveil/ViewExtension.kt index 3c291c1..8ef9841 100644 --- a/androidveil/src/main/java/com/skydoves/androidveil/ViewExtension.kt +++ b/androidveil/src/main/java/com/skydoves/androidveil/ViewExtension.kt @@ -24,6 +24,11 @@ internal fun View.visible() { this.visibility = View.VISIBLE } +@JvmSynthetic +internal fun View.gone() { + this.visibility = View.GONE +} + /** Makes invisible a view. */ @JvmSynthetic internal fun View.invisible() {