From 2bc462aa132e019643ccdef37fd2645ab4f5b4a8 Mon Sep 17 00:00:00 2001 From: "Markus M. May" Date: Wed, 1 Aug 2018 20:44:16 +0200 Subject: [PATCH] use correct methods for context handling --- .../plugins/Maintenance/MaintenanceFragment.java | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/Maintenance/MaintenanceFragment.java b/app/src/main/java/info/nightscout/androidaps/plugins/Maintenance/MaintenanceFragment.java index 733a3a5eb1..ad30f33ad4 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/Maintenance/MaintenanceFragment.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/Maintenance/MaintenanceFragment.java @@ -18,6 +18,22 @@ import info.nightscout.utils.ImportExportPrefs; */ public class MaintenanceFragment extends Fragment { + private Fragment f; + + @Override + public void onResume() { + super.onResume(); + + this.f = this; + } + + @Override + public void onPause() { + super.onPause(); + + this.f = null; + } + @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {