Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
11/16/17 10:30:21 (7 years ago)
Author:
pfleck
Message:

#2845

  • Added an explicit method for StartMarquee.
  • Renamed Add/RemoveOperationProgress methods.
  • Moved progress helpers from MainForm into static Progress methods named Show and Hide.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/EnhancedProgress/HeuristicLab.Problems.Instances.Views/3.3/ProblemInstanceProviderViewGeneric.cs

    r14185 r15477  
    121121
    122122        IContentView activeView = (IContentView)MainFormManager.MainForm.ActiveView;
    123         var mainForm = (MainForm.WindowsForms.MainForm)MainFormManager.MainForm;
     123        var content = activeView.Content;
    124124        // lock active view and show progress bar
    125         mainForm.AddOperationProgressToContent(activeView.Content, "Loading problem instance.");
     125        Progress.ShowMarquee(content, "Loading problem instance.");
    126126
    127127        Task.Factory.StartNew(() => {
     
    131131          } catch (Exception ex) {
    132132            ErrorHandling.ShowErrorDialog(String.Format("Could not load the problem instance {0}", descriptor.Name), ex);
    133             mainForm.RemoveOperationProgressFromContent(activeView.Content);
     133            Progress.Hide(content);
    134134            return;
    135135          }
     
    139139            ErrorHandling.ShowErrorDialog(String.Format("This problem does not support loading the instance {0}", descriptor.Name), ex);
    140140          } finally {
    141             mainForm.RemoveOperationProgressFromContent(activeView.Content);
     141            Progress.Hide(content);
    142142          }
    143143        });
Note: See TracChangeset for help on using the changeset viewer.