From 7cb78d64fa9ad71acdb83eab55ea159a673fb8bf Mon Sep 17 00:00:00 2001 From: zoff99 Date: Sun, 24 Mar 2024 14:09:54 +0100 Subject: [PATCH] show correct menuitem text after resuming activity --- .../com/zoffcc/applications/trifa/MainActivity.java | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/android-refimpl-app/app/src/main/java/com/zoffcc/applications/trifa/MainActivity.java b/android-refimpl-app/app/src/main/java/com/zoffcc/applications/trifa/MainActivity.java index 3ea2b2986..8c0e8eef4 100644 --- a/android-refimpl-app/app/src/main/java/com/zoffcc/applications/trifa/MainActivity.java +++ b/android-refimpl-app/app/src/main/java/com/zoffcc/applications/trifa/MainActivity.java @@ -1380,8 +1380,15 @@ public void onNothingSelected(AdapterView parentView) R.string.MainActivity_profile).withIcon(GoogleMaterial.Icon.gmd_face); PrimaryDrawerItem item2 = new PrimaryDrawerItem().withIdentifier(2).withName( R.string.MainActivity_settings).withIcon(GoogleMaterial.Icon.gmd_settings); - PrimaryDrawerItem item3 = new PrimaryDrawerItem().withIdentifier(3).withName( - R.string.MainActivity_manually_logged_out_false).withIcon(GoogleMaterial.Icon.gmd_refresh); + PrimaryDrawerItem item3; + if (manually_logged_out) + { + item3 = new PrimaryDrawerItem().withIdentifier(3).withName(R.string.MainActivity_manually_logged_out_true).withIcon(GoogleMaterial.Icon.gmd_refresh); + } + else + { + item3 = new PrimaryDrawerItem().withIdentifier(3).withName(R.string.MainActivity_manually_logged_out_false).withIcon(GoogleMaterial.Icon.gmd_refresh); + } PrimaryDrawerItem item4 = new PrimaryDrawerItem().withIdentifier(4).withName( R.string.MainActivity_maint).withIcon(GoogleMaterial.Icon.gmd_build); PrimaryDrawerItem item5 = new PrimaryDrawerItem().withIdentifier(5).withName(