Fixed toolbar account selector

This commit is contained in:
M66B 2024-05-28 17:14:37 +02:00
parent 662b39d3fd
commit 10deff8c7e
1 changed files with 4 additions and 2 deletions

View File

@ -134,10 +134,12 @@ public class FragmentBase extends Fragment {
if (actionbar == null)
return;
if ((actionbar.getDisplayOptions() & DISPLAY_SHOW_CUSTOM) == 0)
Toolbar toolbar = activity.findViewById(R.id.toolbar);
if ((actionbar.getDisplayOptions() & DISPLAY_SHOW_CUSTOM) == 0 && toolbar == null)
return;
final View custom = actionbar.getCustomView();
View custom = (toolbar == null ? actionbar.getCustomView() : toolbar);
if (custom == null)
return;