コード例 #1
0
ファイル: JobController.cs プロジェクト: urish/M3D
        private void SaveJobState()
        {
            AbstractJob jobImplementation = MyJobImplementation;
            var         parameters        = (PersistantJobData)null;

            if (jobImplementation != null)
            {
                parameters = new PersistantJobData(jobImplementation.CurrentFileLineNumber, jobImplementation.Details.jobParams);
            }

            m_oParentFirmwareController.SaveJobParamsToPersistantData(parameters);
        }
コード例 #2
0
        private CommandResult RecoverSpooledPrint(PersistantJobData jobData)
        {
            var currentLineNumber = (long)jobData.CurrentLineNumber;
            var progressIndicator = m_iPI_ProgressIndicator;
            var num = (int)((ulong)currentLineNumber % 65536UL);

            if (progressIndicator > num)
            {
                progressIndicator -= 65536;
            }

            var ulLineToSkipTo = (ulong)currentLineNumber + (ulong)(progressIndicator - num);

            return(m_OnRecoverSpooledPrint(jobData.Params, ulLineToSkipTo));
        }
コード例 #3
0
ファイル: PersistantJobData.cs プロジェクト: urish/M3D
 public PersistantJobData(PersistantJobData other)
 {
     Params            = new JobParams(other.Params);
     CurrentLineNumber = other.CurrentLineNumber;
 }