Example #1
0
	def OnResetProfile(self, e):
		dlg = wx.MessageDialog(self, 'This will reset all profile settings to defaults.\nUnless you have saved your current profile, all settings will be lost!\nDo you really want to reset?', 'Profile reset', wx.YES_NO | wx.ICON_QUESTION)
		result = dlg.ShowModal() == wx.ID_YES
		dlg.Destroy()
		if result:
			profile.resetGlobalProfile()
			self.updateProfileToControls()
Example #2
0
 def OnResetProfile(self, e):
     dlg = wx.MessageDialog(
         self,
         'This will reset all profile settings to defaults.\nUnless you have saved your current profile, all settings will be lost!\nDo you really want to reset?',
         'Profile reset', wx.YES_NO | wx.ICON_QUESTION)
     result = dlg.ShowModal() == wx.ID_YES
     dlg.Destroy()
     if result:
         profile.resetGlobalProfile()
         self.updateProfileToControls()
Example #3
0
	def OnResetProfile(self, e):
		dlg = wx.MessageDialog(self, 'This will reset all profile settings to defaults.\nUnless you have saved your current profile, all settings will be lost!\nDo you really want to reset?', 'Profile reset', wx.YES_NO | wx.ICON_QUESTION)
		result = dlg.ShowModal() == wx.ID_YES
		dlg.Destroy()
		if result:
			profile.resetGlobalProfile()
			if profile.getPreference('machine_type') == 'reprap':
				profile.putProfileSetting('nozzle_size', '0.5')
				profile.putProfileSetting('machine_center_x', '40')
				profile.putProfileSetting('machine_center_y', '40')
			self.updateProfileToControls()
Example #4
0
 def OnResetProfile(self, e):
     dlg = wx.MessageDialog(
         self,
         'This will reset all profile settings to defaults.\nUnless you have saved your current profile, all settings will be lost!\nDo you really want to reset?',
         'Profile reset', wx.YES_NO | wx.ICON_QUESTION)
     result = dlg.ShowModal() == wx.ID_YES
     dlg.Destroy()
     if result:
         profile.resetGlobalProfile()
         if profile.getPreference('machine_type') == 'reprap':
             profile.putProfileSetting('nozzle_size', '0.5')
             profile.putProfileSetting('machine_center_x', '40')
             profile.putProfileSetting('machine_center_y', '40')
         self.updateProfileToControls()
Example #5
0
 def OnResetProfile(self, e):
     dlg = wx.MessageDialog(
         self,
         "This will reset all profile settings to defaults.\nUnless you have saved your current profile, all settings will be lost!\nDo you really want to reset?",
         "Profile reset",
         wx.YES_NO | wx.ICON_QUESTION,
     )
     result = dlg.ShowModal() == wx.ID_YES
     dlg.Destroy()
     if result:
         profile.resetGlobalProfile()
         if profile.getPreference("machine_type") == "reprap":
             profile.putProfileSetting("nozzle_size", "0.5")
             profile.putProfileSetting("machine_center_x", "40")
             profile.putProfileSetting("machine_center_y", "40")
         self.updateProfileToControls()