Skip to content

Commit

Permalink
Merge pull request nextcloud#11522 from nextmcloud/nmc/1943-avoidSear…
Browse files Browse the repository at this point in the history
…chCollapse

Avoid search collapse after page refresh
  • Loading branch information
tobiasKaminsky authored Aug 30, 2023
2 parents 0402673 + 905222c commit 5af5350
Showing 1 changed file with 0 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1340,22 +1340,6 @@ public void listDirectory(OCFile directory, OCFile file, boolean onlyOnDevice, b
}
}

if (searchView != null && !searchView.isIconified() && !fromSearch) {
searchView.post(() -> {
searchView.setQuery("", false);
searchView.onActionViewCollapsed();
Activity activity;
if ((activity = getActivity()) != null && activity instanceof FileDisplayActivity) {
FileDisplayActivity fileDisplayActivity = (FileDisplayActivity) activity;
fileDisplayActivity.hideSearchView(fileDisplayActivity.getCurrentDir());
if (getCurrentFile() != null) {
fileDisplayActivity
.setDrawerIndicatorEnabled(fileDisplayActivity.isRoot(getCurrentFile()));
}
}
});
}

mAdapter.swapDirectory(
accountManager.getUser(),
directory,
Expand Down

0 comments on commit 5af5350

Please sign in to comment.