From: Damyan Ivanov Date: Thu, 28 Feb 2019 07:09:21 +0000 (+0000) Subject: collapse profile list when drawer is closed X-Git-Tag: v0.7~36 X-Git-Url: https://git.ktnx.net/?a=commitdiff_plain;h=4bd21d1274260bf0a97d599a659dc1c0350e70d3;p=mobile-ledger.git collapse profile list when drawer is closed --- diff --git a/app/src/main/java/net/ktnx/mobileledger/ui/activity/MainActivity.java b/app/src/main/java/net/ktnx/mobileledger/ui/activity/MainActivity.java index b1328148..6d52dfc0 100644 --- a/app/src/main/java/net/ktnx/mobileledger/ui/activity/MainActivity.java +++ b/app/src/main/java/net/ktnx/mobileledger/ui/activity/MainActivity.java @@ -268,6 +268,14 @@ public class MainActivity extends CrashReportingActivity { profileListHeadMore.setOnClickListener((v) -> mProfileListAdapter.startEditingProfiles()); profileListHeadCancel.setOnClickListener((v) -> mProfileListAdapter.stopEditingProfiles()); + + drawer.addDrawerListener(new DrawerLayout.SimpleDrawerListener() { + @Override + public void onDrawerClosed(View drawerView) { + super.onDrawerClosed(drawerView); + collapseProfileList(); + } + }); } private void profileThemeChanged() { setupProfileColors();