Close thread on changing base view

This commit is contained in:
M66B 2020-10-22 16:16:06 +02:00
parent a6a9b1f29e
commit 696016bc36
1 changed files with 3 additions and 2 deletions

View File

@ -715,9 +715,10 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB
drawerToggle.setDrawerIndicatorEnabled(count == 1);
if (content_pane != null) {
boolean thread = "thread".equals(getSupportFragmentManager().getBackStackEntryAt(count - 1).getName());
Fragment fragment = getSupportFragmentManager().findFragmentById(R.id.content_pane);
content_separator.setVisibility(fragment == null ? View.GONE : View.VISIBLE);
content_pane.setVisibility(fragment == null ? View.GONE : View.VISIBLE);
content_separator.setVisibility(!thread || fragment == null ? View.GONE : View.VISIBLE);
content_pane.setVisibility(!thread || fragment == null ? View.GONE : View.VISIBLE);
}
}
}