Remove UnsavedChanges prompt - always save bedplate changes before print

This commit is contained in:
John Lewin 2017-06-02 20:59:33 -07:00
parent 543ddced7c
commit a324a036bc
3 changed files with 13 additions and 20 deletions

View file

@ -378,30 +378,11 @@ namespace MatterHackers.MatterControl.ActionBar
WizardWindow.Show<SetupWizardTroubleshooting>("TroubleShooting", "Trouble Shooting");
}
string unsavedChangesCaption = "Unsaved Changes";
string unsavedChangesMessage = "You have unsaved changes to your part. Are you sure you want to start this print?";
private void onStartButton_Click(object sender, EventArgs mouseEvent)
{
UiThread.RunOnIdle(() =>
{
var view3D = ApplicationController.Instance.ActiveView3DWidget;
if (view3D != null && false)
//&& view3D.ShouldBeSaved)
{
StyledMessageBox.ShowMessageBox((bool startPrint) =>
{
if (startPrint)
{
PrinterConnectionAndCommunication.Instance.PrintActivePartIfPossible();
}
}, unsavedChangesMessage, unsavedChangesCaption, StyledMessageBox.MessageType.YES_NO, "Start Print", "Cancel");
}
else
{
PrinterConnectionAndCommunication.Instance.PrintActivePartIfPossible();
}
PrinterConnectionAndCommunication.Instance.PrintActivePartIfPossible();
});
}