Esempio n. 1
0
        public FormProgress(ProgressComposer progressComposer, Action startAction, Action finishAction)
        {
            InitializeComponent();

            _progress               = progressComposer;
            _startAction            = startAction;
            _finishAction           = finishAction;
            _progressEvents         = new List <ProgressEventArgs>();
            _filteredProgressEvents = new List <ProgressEventArgs>();

            buttonFilter.Enabled = false;

            if (ReferenceEquals(_startAction, null) == false)
            {
                //  DispatcherTimer setup
                _dispatcherTimer          = new DispatcherTimer();
                _dispatcherTimer.Tick    += dispatcherTimer_Tick;
                _dispatcherTimer.Interval = new TimeSpan(0, 0, 2);
            }
            else
            {
                _dispatcherTimer = null;
            }

            StartOperation();
        }
Esempio n. 2
0
        public static GMacCodeBlock Process(GMacMacro baseMacro, ProgressComposer progress)
        {
            var optimizer = new TcbOptimizer(baseMacro);

            optimizer.BeginProcessing();

            return(optimizer.CodeBlock);
        }
Esempio n. 3
0
        public static GMacCodeBlock Process(LlGenerator generator, ProgressComposer progress)
        {
            var optimizer = new TcbOptimizer(generator)
            {
                EnableTestEvaluation = false
            };

            optimizer.BeginProcessing();

            return(optimizer.CodeBlock);
        }
Esempio n. 4
0
        static GMacSystemUtils()
        {
            Version = "Version " +
                      Application
                      .ProductVersion
                      .Split(new[] { '.' }, StringSplitOptions.RemoveEmptyEntries)
                      .Take(3)
                      .Concatenate(".");

            Progress = new ProgressComposer();

            InitializeSettings();
        }
Esempio n. 5
0
 public LanguageCompilationLog(ISourceCodeUnitsContainer project, ProgressComposer progressComposer)
 {
     Project  = project;
     Progress = progressComposer;
 }
Esempio n. 6
0
        public static GMacCodeBlock Process(LlGenerator generator, Dictionary <string, GMacMacroParameterBinding> inputsWithTestValues, bool fixOutputsOrder, ProgressComposer progress)
        {
            var optimizer = new TcbOptimizer(generator)
            {
                FixOutputComputationsOrder = fixOutputsOrder,
                EnableTestEvaluation       = inputsWithTestValues.Count > 0,
                _inputsWithTestValues      = inputsWithTestValues
            };

            optimizer.BeginProcessing();

            return(optimizer.CodeBlock);
        }
Esempio n. 7
0
 public static void SetProgress(ProgressComposer progress)
 {
     Progress = progress;
 }
Esempio n. 8
0
 public FormProgress(ProgressComposer progressComposer)
     : this(progressComposer, null, null)
 {
 }