Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
07/04/19 14:45:47 (5 years ago)
Author:
mkommend
Message:

#2845: Merged 16430 into stable.

Location:
stable
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • stable

  • stable/HeuristicLab.Problems.DataAnalysis.Views

  • stable/HeuristicLab.Problems.DataAnalysis.Views/3.4/Classification/ClassificationSolutionVariableImpactsView.cs

    r16438 r17062  
    120120
    121121      //Prepare arguments
    122       var mainForm = (MainForm.WindowsForms.MainForm)MainFormManager.MainForm;
    123122      var replMethod = (ClassificationSolutionVariableImpactsCalculator.ReplacementMethodEnum)replacementComboBox.Items[replacementComboBox.SelectedIndex];
    124123      var factorReplMethod = (ClassificationSolutionVariableImpactsCalculator.FactorReplacementMethodEnum)factorVarReplComboBox.Items[factorVarReplComboBox.SelectedIndex];
     
    126125
    127126      variableImpactsArrayView.Caption = Content.Name + " Variable Impacts";
    128       progress = mainForm.AddOperationProgressToView(this, "Calculating variable impacts for " + Content.Name);
    129       progress.ProgressValue = 0;
    130 
     127      progress = Progress.Show(this, "Calculating variable impacts for " + Content.Name);
    131128      cancellationToken = new CancellationTokenSource();
    132129
     
    146143        rawVariableImpacts.AddRange(impacts);
    147144        UpdateOrdering();
    148       }
    149       finally {
    150         ((MainForm.WindowsForms.MainForm)MainFormManager.MainForm).RemoveOperationProgressFromView(this);
     145      } finally {
     146        Progress.Hide(this);
    151147      }
    152148    }
     
    175171        if (cancellationToken.Token.IsCancellationRequested) { return null; }
    176172        progress.ProgressValue = (double)++i / count;
    177         progress.Status = string.Format("Calculating impact for variable {0} ({1} of {2})", variableName, i, count);
     173        progress.Message = string.Format("Calculating impact for variable {0} ({1} of {2})", variableName, i, count);
    178174
    179175        double impact = 0;
  • stable/HeuristicLab.Problems.DataAnalysis.Views/3.4/MenuItems/ShrinkDataAnalysisRunsMenuItem.cs

    r15584 r17062  
    7272    public override void Execute() {
    7373      IContentView activeView = (IContentView)MainFormManager.MainForm.ActiveView;
    74       var mainForm = (MainForm.WindowsForms.MainForm)MainFormManager.MainForm;
    75       mainForm.AddOperationProgressToContent(activeView.Content, "Removing duplicate datasets.");
     74      var content = activeView.Content;
     75      Progress.Show(content, "Removing duplicate datasets.", ProgressMode.Indeterminate);
    7676
    7777      Action<IContentView> action = (view) => DatasetUtil.RemoveDuplicateDatasets(view.Content);
     
    7979      action.BeginInvoke(activeView, delegate (IAsyncResult result) {
    8080        action.EndInvoke(result);
    81         mainForm.RemoveOperationProgressFromContent(activeView.Content);
     81        Progress.Hide(content);
    8282      }, null);
    8383    }
  • stable/HeuristicLab.Problems.DataAnalysis.Views/3.4/Regression/RegressionSolutionVariableImpactsView.cs

    r16438 r17062  
    111111
    112112    private async void UpdateVariableImpact() {
    113       IProgress progress;
    114 
    115113      //Check if the selection is valid
    116114      if (Content == null) { return; }
     
    120118
    121119      //Prepare arguments
    122       var mainForm = (MainForm.WindowsForms.MainForm)MainFormManager.MainForm;
    123120      var replMethod = (RegressionSolutionVariableImpactsCalculator.ReplacementMethodEnum)replacementComboBox.Items[replacementComboBox.SelectedIndex];
    124121      var factorReplMethod = (RegressionSolutionVariableImpactsCalculator.FactorReplacementMethodEnum)factorVarReplComboBox.Items[factorVarReplComboBox.SelectedIndex];
     
    126123
    127124      variableImpactsArrayView.Caption = Content.Name + " Variable Impacts";
    128       progress = mainForm.AddOperationProgressToView(this, "Calculating variable impacts for " + Content.Name);
    129       progress.ProgressValue = 0;
    130 
     125      var progress = Progress.Show(this, "Calculating variable impacts for " + Content.Name);
    131126      cancellationToken = new CancellationTokenSource();
    132127
     
    148143      }
    149144      finally {
    150         ((MainForm.WindowsForms.MainForm)MainFormManager.MainForm).RemoveOperationProgressFromView(this);
     145        Progress.Hide(this);
    151146      }
    152147    }
     
    175170        if (cancellationToken.Token.IsCancellationRequested) { return null; }
    176171        progress.ProgressValue = (double)++i / count;
    177         progress.Status = string.Format("Calculating impact for variable {0} ({1} of {2})", variableName, i, count);
     172        progress.Message = string.Format("Calculating impact for variable {0} ({1} of {2})", variableName, i, count);
    178173
    179174        double impact = 0;
Note: See TracChangeset for help on using the changeset viewer.