Let matterslice know we are canceling
This commit is contained in:
parent
4b71321019
commit
ed7859cfac
1 changed files with 14 additions and 10 deletions
|
|
@ -437,16 +437,20 @@ namespace MatterHackers.MatterControl.SlicerConfiguration
|
|||
|
||||
internal void CancelCurrentSlicing()
|
||||
{
|
||||
if (slicerProcess != null)
|
||||
{
|
||||
using (TimedLock.Lock(slicerProcess, "SlicingProcess"))
|
||||
{
|
||||
if (slicerProcess != null && !slicerProcess.HasExited)
|
||||
{
|
||||
slicerProcess.Kill();
|
||||
}
|
||||
}
|
||||
}
|
||||
if (slicerProcess != null)
|
||||
{
|
||||
using (TimedLock.Lock(slicerProcess, "SlicingProcess"))
|
||||
{
|
||||
if (slicerProcess != null && !slicerProcess.HasExited)
|
||||
{
|
||||
slicerProcess.Kill();
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
MatterHackers.MatterSlice.MatterSlice.Stop();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue