diff options
author | Lluis Sanchez <lluis@xamarin.com> | 2014-01-20 19:32:53 +0400 |
---|---|---|
committer | Lluis Sanchez Gual <lluis@xamarin.com> | 2014-10-21 18:39:14 +0400 |
commit | f73b2a9990495587d514aa1856919c21170a3940 (patch) | |
tree | 9842411ee8644ead5915a715ee7e53984a601df4 /main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/StatusProgressMonitor.cs | |
parent | a2046b6331a271e8203df7d3d0f14500d33d60fa (diff) |
Initial drop of the new project model
Diffstat (limited to 'main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/StatusProgressMonitor.cs')
-rw-r--r-- | main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/StatusProgressMonitor.cs | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/StatusProgressMonitor.cs b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/StatusProgressMonitor.cs index df4fd5efbe..9c53d67eb7 100644 --- a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/StatusProgressMonitor.cs +++ b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/StatusProgressMonitor.cs @@ -34,7 +34,7 @@ using MonoDevelop.Core; namespace MonoDevelop.Ide.Gui { - internal class StatusProgressMonitor: BaseProgressMonitor + internal class StatusProgressMonitor: ProgressMonitor { string icon; bool showErrorDialogs; @@ -62,20 +62,20 @@ namespace MonoDevelop.Ide.Gui protected override void OnProgressChanged () { if (showTaskTitles) - statusBar.ShowMessage (icon, CurrentTask); - if (!UnknownWork) - statusBar.SetProgressFraction (GlobalWork); - RunPendingEvents (); + statusBar.ShowMessage (icon, CurrentTaskName); + if (!ProgressIsUnknown) + statusBar.SetProgressFraction (Progress); + DispatchService.RunPendingEvents (); } public void UpdateStatusBar () { if (showTaskTitles) - statusBar.ShowMessage (icon, CurrentTask); + statusBar.ShowMessage (icon, CurrentTaskName); else statusBar.ShowMessage (icon, title); - if (!UnknownWork) - statusBar.SetProgressFraction (GlobalWork); + if (!ProgressIsUnknown) + statusBar.SetProgressFraction (Progress); else statusBar.SetProgressFraction (0); } @@ -87,22 +87,22 @@ namespace MonoDevelop.Ide.Gui statusBar.EndProgress (); try { - if (Errors.Count > 0 || Warnings.Count > 0) { - if (Errors.Count > 0) { - statusBar.ShowError (Errors [Errors.Count - 1]); - } else if (SuccessMessages.Count == 0) { - statusBar.ShowWarning (Warnings [Warnings.Count - 1]); + if (Errors.Length > 0 || Warnings.Length > 0) { + if (Errors.Length > 0) { + statusBar.ShowError (Errors [Errors.Length - 1].Message); + } else if (SuccessMessages.Length == 0) { + statusBar.ShowWarning (Warnings [Warnings.Length - 1]); } base.OnCompleted (); if (showErrorDialogs) - ShowResultDialog (); + this.ShowResultDialog (); return; } - if (SuccessMessages.Count > 0) - statusBar.ShowMessage (MonoDevelop.Ide.Gui.Stock.StatusSuccess, SuccessMessages [SuccessMessages.Count - 1]); + if (SuccessMessages.Length > 0) + statusBar.ShowMessage (MonoDevelop.Ide.Gui.Stock.StatusSuccess, SuccessMessages [SuccessMessages.Length - 1]); } finally { statusBar.StatusSourcePad = statusSourcePad; |