From: daid303 Date: Mon, 10 Dec 2012 13:35:47 +0000 (+0100) Subject: Fix the simplemode. X-Git-Tag: 13.03~159 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=91a592d92201104cdccc99adb20563dcabbe44be;p=cura.git Fix the simplemode. --- diff --git a/Cura/gui/mainWindow.py b/Cura/gui/mainWindow.py index 1dbff0b2..6e723fd0 100644 --- a/Cura/gui/mainWindow.py +++ b/Cura/gui/mainWindow.py @@ -262,6 +262,11 @@ class mainWindow(wx.Frame): if len(self.filelist) < 1: wx.MessageBox('You need to load a file before you can prepare it.', 'Print error', wx.OK | wx.ICON_INFORMATION) return + isSimple = profile.getPreference('startMode') == 'Simple' + if isSimple: + #save the current profile so we can put it back latter + oldProfile = profile.getGlobalProfileString() + self.simpleSettingsPanel.setupSlice() #Create a progress panel and add it to the window. The progress panel will start the Skein operation. spp = sliceProgessPanel.sliceProgessPanel(self, self, self.filelist) self.sizer.Add(spp, (len(self.progressPanelList)+2,0), span=(1, 4 + self.extruderCount), flag=wx.EXPAND) @@ -271,6 +276,8 @@ class mainWindow(wx.Frame): if newSize.GetWidth() < wx.GetDisplaySize()[0]: self.SetSize(newSize) self.progressPanelList.append(spp) + if isSimple: + profile.loadGlobalProfileFromString(oldProfile) def OnPrint(self, e): if len(self.filelist) < 1: diff --git a/Cura/gui/simpleMode.py b/Cura/gui/simpleMode.py index 56f8057d..04400524 100644 --- a/Cura/gui/simpleMode.py +++ b/Cura/gui/simpleMode.py @@ -59,9 +59,6 @@ class simpleModePanel(wx.Panel): self.printMaterialPLA.SetValue(True) def setupSlice(self): - #save the current profile so we can put it back latter - oldProfile = profile.getGlobalProfileString() - put = profile.putProfileSetting get = profile.getProfileSetting @@ -159,8 +156,3 @@ class simpleModePanel(wx.Panel): def updateProfileToControls(self): pass - -# def OnNormalSwitch(self, e): -# profile.putPreference('startMode', 'Normal') -# mainWindow.mainWindow() -# self.Close()