1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2024-12-26 17:57:16 +00:00

Save drawer toggle state

This commit is contained in:
M66B 2018-08-23 18:44:23 +00:00
parent 679b16dc5d
commit 7922434ff5

View file

@ -204,6 +204,9 @@ public class ActivityView extends ActivityBase implements FragmentManager.OnBack
fragmentTransaction.commit();
}
if (savedInstanceState != null)
drawerToggle.setDrawerIndicatorEnabled(savedInstanceState.getBoolean("toggle"));
new SimpleTask<Long>() {
@Override
protected Long onLoad(Context context, Bundle args) throws Throwable {
@ -292,6 +295,12 @@ public class ActivityView extends ActivityBase implements FragmentManager.OnBack
checkIntent(getIntent());
}
@Override
protected void onSaveInstanceState(Bundle outState) {
super.onSaveInstanceState(outState);
outState.putBoolean("toggle", drawerToggle.isDrawerIndicatorEnabled());
}
@Override
protected void onPostCreate(Bundle savedInstanceState) {
super.onPostCreate(savedInstanceState);