1
0
mirror of https://codeberg.org/tom79/Fedilab synced 2024-12-11 10:46:01 +01:00

prepare settings

This commit is contained in:
Thomas 2022-09-12 09:35:44 +02:00
parent 4220338374
commit 2092119475

View File

@ -1122,6 +1122,14 @@ public abstract class BaseMainActivity extends BaseActivity implements NetworkSt
public void redrawPinned(List<MastodonList> mastodonLists) {
int currentItem = binding.viewPager.getCurrentItem();
SharedPreferences sharedpreferences = PreferenceManager.getDefaultSharedPreferences(BaseMainActivity.this);
boolean singleBar = sharedpreferences.getBoolean(getString(R.string.SET_USE_SINGLE_TOPBAR), false);
//Hiding/Showing bottom menu depending of settings
if (singleBar) {
binding.bottomNavView.setVisibility(View.GONE);
} else {
binding.bottomNavView.setVisibility(View.VISIBLE);
}
new ViewModelProvider(BaseMainActivity.this).get(TopBarVM.class).getDBPinned()
.observe(this, pinned -> {
this.pinned = pinned;