mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-12 02:39:05 +01:00
Fix Contacts Item always beeing selected if Back is pressed in the NavMenu
Signed-off-by: goapunk <noobie@goapunks.net>
This commit is contained in:
@@ -193,14 +193,14 @@ public class NavDrawerActivity extends BriarFragmentActivity implements
|
||||
|
||||
@Override
|
||||
public void onBackPressed() {
|
||||
// Check the Contacts item because we always return to Contacts here
|
||||
NavigationView navigation = (NavigationView) findViewById(R.id.navigation);
|
||||
navigation.getMenu().findItem(R.id.nav_btn_contacts).setChecked(true);
|
||||
if (getSupportFragmentManager().getBackStackEntryCount() == 0
|
||||
&& drawerLayout.isDrawerOpen(START)) {
|
||||
drawerLayout.closeDrawer(START);
|
||||
return;
|
||||
}
|
||||
// Check the Contacts item because we always return to Contacts here
|
||||
NavigationView navigation = (NavigationView) findViewById(R.id.navigation);
|
||||
navigation.getMenu().findItem(R.id.nav_btn_contacts).setChecked(true);
|
||||
super.onBackPressed();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user