From: Youness Alaoui Date: Fri, 31 Jul 2015 21:02:49 +0000 (-0400) Subject: Add a 'Are you sure' dialog to the firmware upgrade skip button X-Git-Tag: lulzbot-15.02.1-2.01~52 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=21bf54fdd1aca2904eea20290276a6c1260366d0;p=cura.git Add a 'Are you sure' dialog to the firmware upgrade skip button --- diff --git a/Cura/gui/configWizard.py b/Cura/gui/configWizard.py index ab1d3846..0377d6d8 100644 --- a/Cura/gui/configWizard.py +++ b/Cura/gui/configWizard.py @@ -1401,8 +1401,14 @@ class LulzbotFirmwareUpdatePage(InfoPage): self.GetParent().FindWindowById(wx.ID_FORWARD).Enable() def OnSkipClick(self, e): - self.GetParent().FindWindowById(wx.ID_FORWARD).Enable() - self.GetParent().ShowPage(self.GetNext()) + dlg = wx.MessageDialog(self, _("Are you sure you want to skip the firmware upgrade?\n" + + "It could damage your printer if you changed your toolhead and have not updated thefirmware!"), + _('Skip firmware upgrade?'), wx.YES_NO | wx.ICON_EXCLAMATION) + skip = dlg.ShowModal() == wx.ID_YES + dlg.Destroy() + if skip: + self.GetParent().FindWindowById(wx.ID_FORWARD).Enable() + self.GetParent().ShowPage(self.GetNext()) class LulzbotChangeToolheadWizard(wx.wizard.Wizard): def __init__(self):