Skip to content

Commit

Permalink
Fix back arrow appearing as hamburger icon. NC PR: nextcloud#11769
Browse files Browse the repository at this point in the history
  • Loading branch information
surinder-tsys committed Aug 5, 2024
1 parent cf222d4 commit 6182041
Showing 1 changed file with 12 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1530,13 +1530,23 @@ protected void setTitle() {
setTitle(R.string.drawer_item_shared);
break;
default:
setTitle(themeUtils.getDefaultDisplayNameForRootFolder(getContext()), false);
setTitle(themeUtils.getDefaultDisplayNameForRootFolder(getContext()), isRoot());
break;
}
}

}

//NMC Customization
//for NMC we are using defaultToolbar instead searchToolbar for which we needed customization
private boolean isRoot() {
Activity activity;
if ((activity = getActivity()) != null && activity instanceof FileDisplayActivity) {
return ((FileDisplayActivity) activity).isRoot(((FileDisplayActivity) activity).getFile());
}
return false;
}

protected void prepareActionBarItems(SearchEvent event) {
if (event != null) {
switch (event.getSearchType()) {
Expand Down Expand Up @@ -1597,7 +1607,7 @@ public void onMessageEvent(ChangeMenuEvent changeMenuEvent) {
((FileDisplayActivity) activity).initSyncBroadcastReceiver();
}

setTitle(themeUtils.getDefaultDisplayNameForRootFolder(getContext()), false);
setTitle(themeUtils.getDefaultDisplayNameForRootFolder(getContext()), isRoot());
activity.getIntent().removeExtra(OCFileListFragment.SEARCH_EVENT);
}

Expand Down

0 comments on commit 6182041

Please sign in to comment.