- Camera ROI DebugLevel inheritance fixed/improved, parent can be Off

- avoid empty lines in logs after SendCommand, SendCalibData, ValveMove logs
This commit is contained in:
Milan Hanajik
2014-08-15 20:50:42 +02:00
parent ea59dd0932
commit c767512fad
3 changed files with 22 additions and 6 deletions
@@ -41,7 +41,10 @@ namespace TBF.BenchControl.Cameras.CameraRoi
if (cfg.DebugLevel != Entities.DebugMode.Off)
{
camera = TbfComponents.FindComponent(cfg.ParentName, components) as GenericDevices.ICamera;
if (camera == null) throw new Exception("Cannot find " + Name + " parent");
if ((camera == null) && (cfg.DebugLevel != Entities.DebugMode.Inherit))
{
throw new Exception("Cannot find " + Name + " parent");
}
}
}