mirror of
https://github.com/nextcloud/android.git
synced 2024-11-23 05:35:39 +03:00
Merge pull request #5754 from nextcloud/empty
Show loading instead of empty content
This commit is contained in:
commit
f8a5643eca
3 changed files with 3 additions and 2 deletions
|
@ -1432,7 +1432,8 @@ public class FileDisplayActivity extends FileActivity
|
|||
private void setBackgroundText() {
|
||||
final OCFileListFragment ocFileListFragment = getListOfFilesFragment();
|
||||
if (ocFileListFragment != null) {
|
||||
if (mSyncInProgress) {
|
||||
if (mSyncInProgress ||
|
||||
getFile().getFileLength() > 0 && getStorageManager().getFolderContent(getFile(), false).isEmpty()) {
|
||||
ocFileListFragment.setEmptyListLoadingMessage();
|
||||
} else {
|
||||
ocFileListFragment.setEmptyListMessage(ExtendedListFragment.SearchType.NO_SEARCH);
|
||||
|
|
|
@ -257,7 +257,6 @@ public class ExtendedListFragment extends Fragment implements
|
|||
|
||||
if (currentVisibility != oldVisibility) {
|
||||
if (currentVisibility == View.VISIBLE) {
|
||||
|
||||
setEmptyListMessage(SearchType.REGULAR_FILTER);
|
||||
} else {
|
||||
setEmptyListMessage(SearchType.NO_SEARCH);
|
||||
|
|
|
@ -943,6 +943,7 @@ public class OCFileListFragment extends ExtendedListFragment implements
|
|||
} else {
|
||||
// update state and view of this fragment
|
||||
searchFragment = false;
|
||||
setEmptyListLoadingMessage();
|
||||
listDirectory(file, MainApp.isOnlyOnDevice(), false);
|
||||
// then, notify parent activity to let it update its state and view
|
||||
mContainerActivity.onBrowsedDownTo(file);
|
||||
|
|
Loading…
Reference in a new issue