mirror of https://github.com/NekoX-Dev/NekoX.git
remember the status of showing accounts
This commit is contained in:
parent
5ca6f284e4
commit
b3e16dca87
|
@ -57,7 +57,7 @@ public class DrawerLayoutAdapter extends RecyclerListView.SelectionAdapter imple
|
||||||
public DrawerLayoutAdapter(Context context, SideMenultItemAnimator animator) {
|
public DrawerLayoutAdapter(Context context, SideMenultItemAnimator animator) {
|
||||||
mContext = context;
|
mContext = context;
|
||||||
itemAnimator = animator;
|
itemAnimator = animator;
|
||||||
accountsShown = UserConfig.getActivatedAccountsCount() > 1 && MessagesController.getGlobalMainSettings().getBoolean("accountsShown", true);
|
accountsShown = MessagesController.getGlobalMainSettings().getBoolean("accountsShown", true);
|
||||||
Theme.createCommonDialogResources(context);
|
Theme.createCommonDialogResources(context);
|
||||||
resetItems();
|
resetItems();
|
||||||
try {
|
try {
|
||||||
|
@ -85,6 +85,7 @@ public class DrawerLayoutAdapter extends RecyclerListView.SelectionAdapter imple
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
accountsShown = value;
|
accountsShown = value;
|
||||||
|
MessagesController.getGlobalMainSettings().edit().putBoolean("accountsShown", accountsShown).apply();
|
||||||
if (profileCell != null) {
|
if (profileCell != null) {
|
||||||
profileCell.setAccountsShown(accountsShown, animated);
|
profileCell.setAccountsShown(accountsShown, animated);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue