Skip to content

Commit 3ab52bf

Browse files
committed
fix bug on hide
1 parent 07149fc commit 3ab52bf

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

.idea/misc.xml

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

QuickState/src/main/java/com/erif/quickstate/QuickState.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,12 +151,12 @@ private void createState(String name) {
151151
}
152152

153153
public void hide() {
154-
if (stateView != null)
154+
if (stateView != null && stateView.getVisibility() == View.VISIBLE)
155155
stateView.hide();
156156
}
157157

158158
public void hideAndShowLoader() {
159-
if (stateView != null)
159+
if (stateView != null && stateView.getVisibility() == View.VISIBLE)
160160
stateView.hideAndShowLoader();
161161
}
162162

0 commit comments

Comments
 (0)