Ensure bedplate is saved before slicing
- Remove cheat in AddSelectedItemToBedplate helper which saved bed - Invoke PersistePlateIfNeeded before slicing - Mark plate as dirty when adding items - Make SaveChanges awaitable so slicing queues until save is done - Remove unused Action in functionToCallOnSaveAs delegate - Change saveas delegate to support new awaitable signature
This commit is contained in:
parent
d205cc6e13
commit
2a9e70c28c
7 changed files with 34 additions and 30 deletions
|
|
@ -204,12 +204,16 @@ namespace MatterHackers.MatterControl.PartPreviewWindow
|
|||
{
|
||||
if (ActiveSliceSettings.Instance.PrinterSelected)
|
||||
{
|
||||
if (ActiveSliceSettings.Instance.IsValid() && printItem != null)
|
||||
// Save any pending changes before starting the print
|
||||
ApplicationController.Instance.ActiveView3DWidget.PersistPlateIfNeeded().ContinueWith((t) =>
|
||||
{
|
||||
generateGCodeButton.Visible = false;
|
||||
SlicingQueue.Instance.QueuePartForSlicing(printItem);
|
||||
startedSliceFromGenerateButton = true;
|
||||
}
|
||||
if (ActiveSliceSettings.Instance.IsValid() && printItem != null)
|
||||
{
|
||||
generateGCodeButton.Visible = false;
|
||||
SlicingQueue.Instance.QueuePartForSlicing(printItem);
|
||||
startedSliceFromGenerateButton = true;
|
||||
}
|
||||
});
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue