diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Dialogs/WizardDialog.java b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Dialogs/WizardDialog.java index 825051d34f..783c16a7d5 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Dialogs/WizardDialog.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Dialogs/WizardDialog.java @@ -93,8 +93,7 @@ public class WizardDialog extends DialogFragment implements OnClickListener { } - public WizardDialog(Context context) { - this(); + public void setContext(Context context) { parentContext = context; } diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/OverviewFragment.java b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/OverviewFragment.java index dfa78351af..cb168e2f65 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/OverviewFragment.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/OverviewFragment.java @@ -153,7 +153,8 @@ public class OverviewFragment extends Fragment { @Override public void onClick(View view) { FragmentManager manager = getFragmentManager(); - WizardDialog wizardDialog = new WizardDialog(getContext()); + WizardDialog wizardDialog = new WizardDialog(); + wizardDialog.setContext(getContext()); wizardDialog.show(manager, "WizardDialog"); } });