Dismiss editing when fragment is paused

This commit is contained in:
AdrianLxM 2017-01-01 21:46:25 +01:00 committed by GitHub
parent fded515ac1
commit 9c40e4af34

View file

@ -344,6 +344,12 @@ public class CircadianPercentageProfileFragment extends Fragment implements Frag
@Override
public void onPause() {
super.onPause();
if (basalEditDialog != null && basalEditDialog.isVisible()) {
basalEditDialog.dismiss();
}
basalEditDialog = null;
MainApp.bus().unregister(this);
}