[Android] Refresh root browser
Geoffrey Métais
git at videolan.org
Wed Jul 18 16:38:58 CEST 2018
vlc-android | branch: 3.0.x | Geoffrey Métais <geoffrey.metais at gmail.com> | Wed Jul 18 15:10:05 2018 +0200| [cfa84c9601c4b9f78aa9f516c7276cced9c42273] | committer: Geoffrey Métais
Refresh root browser
> https://code.videolan.org/videolan/vlc-android/commit/cfa84c9601c4b9f78aa9f516c7276cced9c42273
---
.../src/org/videolan/vlc/gui/browser/BaseBrowserFragment.java | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/vlc-android/src/org/videolan/vlc/gui/browser/BaseBrowserFragment.java b/vlc-android/src/org/videolan/vlc/gui/browser/BaseBrowserFragment.java
index 3cae82df9..7397712ce 100644
--- a/vlc-android/src/org/videolan/vlc/gui/browser/BaseBrowserFragment.java
+++ b/vlc-android/src/org/videolan/vlc/gui/browser/BaseBrowserFragment.java
@@ -214,9 +214,12 @@ public abstract class BaseBrowserFragment extends SortableFragment<BaseBrowserAd
super.onHiddenChanged(hidden);
if (hidden) {
releaseBrowser();
- } else if (mFabPlay != null) {
- mFabPlay.setImageResource(R.drawable.ic_fab_play);
- updateFab();
+ } else {
+ if (mFabPlay != null) {
+ mFabPlay.setImageResource(R.drawable.ic_fab_play);
+ updateFab();
+ }
+ if (mRoot && this instanceof NetworkBrowserFragment) refresh();
}
}
@@ -378,7 +381,7 @@ public abstract class BaseBrowserFragment extends SortableFragment<BaseBrowserAd
@Override
public void refresh() {
- if (!isResumed()) return;
+ if (!isResumed() || isHidden()) return;
if (isSortEnabled()) {
refreshList = new ArrayList<>();
refreshing = true;
More information about the Android
mailing list