From 049a79893eac8335ad37defd042533e0fbb8f054 Mon Sep 17 00:00:00 2001 From: Roy Ben Shabat Date: Thu, 15 Oct 2020 23:03:00 +0300 Subject: Disable job execution when liquid volumes out of range. --- .../Visual_Studio/PPC/Tango.PPC.UI/Printing/DefaultPrintingManager.cs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Software/Visual_Studio/PPC/Tango.PPC.UI') diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Printing/DefaultPrintingManager.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/Printing/DefaultPrintingManager.cs index 34624947f..1f2895f26 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Printing/DefaultPrintingManager.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Printing/DefaultPrintingManager.cs @@ -259,6 +259,10 @@ namespace Tango.PPC.UI.Printing { throw new InvalidOperationException("Error starting job. Color is out of range."); } + if (job.Segments.SelectMany(x => x.BrushStops).Any(x => x.IsLiquidVolumesOutOfRange)) + { + throw new InvalidOperationException("Error starting job. Total ink volume is out of range."); + } if (job.Segments.SelectMany(x => x.BrushStops).Any(x => x.BrushColorSpace == ColorSpaces.Catalog && x.ColorCatalogsItem == null && !x.IsTransparent && !x.IsWhite)) { throw new InvalidOperationException("Error starting job. Please select a catalog color."); -- cgit v1.3.1