Added deletion of the two QFile objects to AMScanActionControllerBasicFileWriter. Also changed AMRegionScanActionController to stop an extra line of values from being printed, thanks to Darren the fix was quick by removing writeDataToFiles() from the AxisFinished part of the event case statement.
Removed unnecessary comment.
Addressed issues with the sample move action. Turns out that AMConstDbObject had not be taught how to save and load objects from other databases. This was a problem for AMSampleMoveActionInfo, which resides in the actions databases whereas the samples live in the user database. I fixed this problem and testing seems to indicate everything is fine now. Also changed the AMSampleMoveActionEditor so that there is a No Sample Selected option in the combobox. This way you can select the first sample on the plate without have to select a different sample first. Also fixed an issue where copying the actions didn't set the correct sample in the editor. Finally, had to fix a problem where AMSampleMoveActions reloaded from the database - ie,, copied from the history view using the Re-Run Action option - failed all the time. Turns out those actionInfos load the sample from the database, and don't get it from the sample plate. Since the actionInfo can't possibly know about AMBeamline I needed to put the checking into AMSampleMoveAction itself during its failure checking. In this case, if the sample pointer in the actionInfo isn't on the plate we do a final iterative check to see if that sample matches any of the names on the plate - and we reset the sample if necessary. This works, but it's ugly. This is the first case where the lack of an AMDbObject retain/release structure is really hampering the normal flow of code.
Moved the controlMoveInfo getters to public from protected in AMControlMoveAction3. Removed some unnecessary debugging from AMDbObject and added a define for errorMon in a AMConstDbObject failure case. Also changed the AMSampleMoveAction to attempt to move as far as possible on a given axis, rather than failing without trying. There are samples that are sometimes calculated just outside the motion range, this change will take them to the soft limit rather than doing nothing.