From 055bcbaa7885333ea88f48c96f71219602372a06 Mon Sep 17 00:00:00 2001 From: John Lewin Date: Thu, 30 Nov 2017 06:08:32 -0800 Subject: [PATCH 01/11] Check for .Connected || .FinishedPrint - Issue MatterHackers/MCCentral#2344 Library Select -> Print unavailable after successful print --- Library/Widgets/PrintLibraryWidget.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Library/Widgets/PrintLibraryWidget.cs b/Library/Widgets/PrintLibraryWidget.cs index e14a8a7b6..6be91e2cc 100644 --- a/Library/Widgets/PrintLibraryWidget.cs +++ b/Library/Widgets/PrintLibraryWidget.cs @@ -405,11 +405,14 @@ namespace MatterHackers.MatterControl.PrintLibrary }, IsEnabled = (selectedListItems, listView) => { + var communicationState = ApplicationController.Instance.DragDropData?.Printer?.Connection.CommunicationState; + // Singleselect - disallow containers return listView.SelectedItems.Count == 1 && selectedListItems.FirstOrDefault()?.Model is ILibraryItem firstItem && !(firstItem is ILibraryContainer) - && ApplicationController.Instance.DragDropData?.Printer?.Connection.CommunicationState == CommunicationStates.Connected; + && (communicationState == CommunicationStates.Connected + || communicationState == CommunicationStates.FinishedPrint); } }); From 243d5d7ec2c4f33d7738080bc7247c57c2edb8ed Mon Sep 17 00:00:00 2001 From: John Lewin Date: Thu, 30 Nov 2017 06:10:46 -0800 Subject: [PATCH 02/11] Await ClearPlate call - Issue MatterHackers/MCCentral#2343 Library Selection -> Print frequently fails to place selection on bed --- ApplicationView/PrinterModels.cs | 6 +++--- Library/Widgets/PrintLibraryWidget.cs | 2 +- PartPreviewWindow/View3D/View3DWidget.cs | 5 ++++- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/ApplicationView/PrinterModels.cs b/ApplicationView/PrinterModels.cs index fa92fdd9d..580c03c9e 100644 --- a/ApplicationView/PrinterModels.cs +++ b/ApplicationView/PrinterModels.cs @@ -117,18 +117,18 @@ namespace MatterHackers.MatterControl return new FileSystemFileItem(mcxPath); } - internal void ClearPlate() + internal async Task ClearPlate() { // Clear existing this.LoadedGCode = null; this.GCodeRenderer = null; // Load - this.LoadContent(new EditContext() + await this.LoadContent(new EditContext() { ContentStore = ApplicationController.Instance.Library.PlatingHistory, SourceItem = BedConfig.NewPlatingItem() - }).ConfigureAwait(false); + }); } internal static ILibraryItem LoadLastPlateOrNew() diff --git a/Library/Widgets/PrintLibraryWidget.cs b/Library/Widgets/PrintLibraryWidget.cs index 6be91e2cc..31c48d566 100644 --- a/Library/Widgets/PrintLibraryWidget.cs +++ b/Library/Widgets/PrintLibraryWidget.cs @@ -384,7 +384,7 @@ namespace MatterHackers.MatterControl.PrintLibrary { UiThread.RunOnIdle(async () => { - printer.Bed.ClearPlate(); + await printer.Bed.ClearPlate(); AddToPlate(selectedLibraryItems); diff --git a/PartPreviewWindow/View3D/View3DWidget.cs b/PartPreviewWindow/View3D/View3DWidget.cs index 3c2c9a9d3..f7283cdfa 100644 --- a/PartPreviewWindow/View3D/View3DWidget.cs +++ b/PartPreviewWindow/View3D/View3DWidget.cs @@ -394,7 +394,10 @@ namespace MatterHackers.MatterControl.PartPreviewWindow Title = "Clear Bed".Localize(), Action = () => { - UiThread.RunOnIdle(sceneContext.ClearPlate); + UiThread.RunOnIdle(() => + { + sceneContext.ClearPlate().ConfigureAwait(false); + }); } } }; From d94525b3d93d7c6b4582cc56da6a29f107775934 Mon Sep 17 00:00:00 2001 From: John Lewin Date: Thu, 30 Nov 2017 06:39:58 -0800 Subject: [PATCH 03/11] Expose long running task so that callers can block until completed --- Library/Widgets/InsertionGroup.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Library/Widgets/InsertionGroup.cs b/Library/Widgets/InsertionGroup.cs index e4ef76e2d..19e7a2017 100644 --- a/Library/Widgets/InsertionGroup.cs +++ b/Library/Widgets/InsertionGroup.cs @@ -49,6 +49,8 @@ namespace MatterHackers.MatterControl.PrintLibrary private InteractiveScene scene; private View3DWidget view3DWidget; + public Task LoadingItemsTask { get; } + static InsertionGroup() { // Create the placeholder mesh and position it at z0 @@ -64,7 +66,7 @@ namespace MatterHackers.MatterControl.PrintLibrary this.scene = scene; this.view3DWidget = view3DWidget; - Task.Run((Func)(async () => + this.LoadingItemsTask = Task.Run((Func)(async () => { var newItemOffset = Vector2.Zero; if (!dragOperationActive()) From eb7f7bde7d20219425d35aac3d176a113d05047a Mon Sep 17 00:00:00 2001 From: John Lewin Date: Thu, 30 Nov 2017 06:43:38 -0800 Subject: [PATCH 04/11] Ensure content is loaded and scene is saved before starting print - Return created InsertionGroup from AddToPlate - Await insertionGroup.LoadingItemsTask before persisting changes - Persist bed after insertionGroup load completes - Issue MatterHackers/MCCentral#2346 Library Selection -> Print fails to produce gcode --- Library/Widgets/PrintLibraryWidget.cs | 18 ++++++++++++++---- Submodules/agg-sharp | 2 +- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/Library/Widgets/PrintLibraryWidget.cs b/Library/Widgets/PrintLibraryWidget.cs index 31c48d566..47ccd68ac 100644 --- a/Library/Widgets/PrintLibraryWidget.cs +++ b/Library/Widgets/PrintLibraryWidget.cs @@ -384,12 +384,18 @@ namespace MatterHackers.MatterControl.PrintLibrary { UiThread.RunOnIdle(async () => { + // Clear plate await printer.Bed.ClearPlate(); - AddToPlate(selectedLibraryItems); + // Add content + var insertionGroup = AddToPlate(selectedLibraryItems); + await insertionGroup.LoadingItemsTask; + // Persist changes + printer.Bed.Save(); + + // Slice and print var context = printer.Bed.EditContext; - await ApplicationController.Instance.PrintPart( context.PartFilePath, context.GCodeFilePath, @@ -699,20 +705,24 @@ namespace MatterHackers.MatterControl.PrintLibrary }); } - private static void AddToPlate(IEnumerable selectedLibraryItems) + private static InsertionGroup AddToPlate(IEnumerable selectedLibraryItems) { + InsertionGroup insertionGroup = null; + var context = ApplicationController.Instance.DragDropData; var scene = context.SceneContext.Scene; scene.Children.Modify(list => { list.Add( - new InsertionGroup( + insertionGroup = new InsertionGroup( selectedLibraryItems, context.View3DWidget, scene, context.SceneContext.BedCenter, dragOperationActive: () => false)); }); + + return insertionGroup; } public override void OnClosed(ClosedEventArgs e) diff --git a/Submodules/agg-sharp b/Submodules/agg-sharp index f92ab5bbb..0759ce93e 160000 --- a/Submodules/agg-sharp +++ b/Submodules/agg-sharp @@ -1 +1 @@ -Subproject commit f92ab5bbbcf8fe99440e067e52cdb289a0ff57d0 +Subproject commit 0759ce93ef5eb6ef6b728c6c4d70233fe9db4429 From 6f608bbeaaf945182ab9d43f41b1e1cd38eddb16 Mon Sep 17 00:00:00 2001 From: John Lewin Date: Thu, 30 Nov 2017 06:51:06 -0800 Subject: [PATCH 05/11] Move AddToPlate from ui to model --- ApplicationView/PrinterModels.cs | 24 +++++++++++++++++++++- Library/Widgets/PrintLibraryWidget.cs | 29 ++++++--------------------- 2 files changed, 29 insertions(+), 24 deletions(-) diff --git a/ApplicationView/PrinterModels.cs b/ApplicationView/PrinterModels.cs index 580c03c9e..219f4a185 100644 --- a/ApplicationView/PrinterModels.cs +++ b/ApplicationView/PrinterModels.cs @@ -50,8 +50,10 @@ namespace MatterHackers.MatterControl using MatterHackers.PolygonMesh; using MatterHackers.VectorMath; using MatterHackers.MatterControl.PartPreviewWindow; + using System.Collections.Generic; + using MatterHackers.MatterControl.PrintLibrary; - public class BedConfig + public class BedConfig { public event EventHandler ActiveLayerChanged; @@ -131,6 +133,26 @@ namespace MatterHackers.MatterControl }); } + public InsertionGroup AddToPlate(IEnumerable selectedLibraryItems) + { + InsertionGroup insertionGroup = null; + + var context = ApplicationController.Instance.DragDropData; + var scene = context.SceneContext.Scene; + scene.Children.Modify(list => + { + list.Add( + insertionGroup = new InsertionGroup( + selectedLibraryItems, + context.View3DWidget, + scene, + context.SceneContext.BedCenter, + dragOperationActive: () => false)); + }); + + return insertionGroup; + } + internal static ILibraryItem LoadLastPlateOrNew() { // Find the last used bed plate mcx diff --git a/Library/Widgets/PrintLibraryWidget.cs b/Library/Widgets/PrintLibraryWidget.cs index 47ccd68ac..448747863 100644 --- a/Library/Widgets/PrintLibraryWidget.cs +++ b/Library/Widgets/PrintLibraryWidget.cs @@ -365,7 +365,6 @@ namespace MatterHackers.MatterControl.PrintLibrary // TODO: Sort out the right way to have an ActivePrinter context that looks and behaves correctly var activeContext = ApplicationController.Instance.DragDropData; var printer = activeContext.Printer; - //var printerTabPage = activeContext.View3DWidget.Parents().FirstOrDefault(); switch (selectedLibraryItems.FirstOrDefault()) { @@ -388,7 +387,7 @@ namespace MatterHackers.MatterControl.PrintLibrary await printer.Bed.ClearPlate(); // Add content - var insertionGroup = AddToPlate(selectedLibraryItems); + var insertionGroup = printer.Bed.AddToPlate(selectedLibraryItems); await insertionGroup.LoadingItemsTask; // Persist changes @@ -428,7 +427,11 @@ namespace MatterHackers.MatterControl.PrintLibrary Title = "Add to Plate".Localize(), Action = (selectedLibraryItems, listView) => { - AddToPlate(selectedLibraryItems); + // TODO: Sort out the right way to have an ActivePrinter context that looks and behaves correctly + var activeContext = ApplicationController.Instance.DragDropData; + var printer = activeContext.Printer; + + printer.Bed.AddToPlate(selectedLibraryItems); }, IsEnabled = (selectedListItems, listView) => { @@ -705,26 +708,6 @@ namespace MatterHackers.MatterControl.PrintLibrary }); } - private static InsertionGroup AddToPlate(IEnumerable selectedLibraryItems) - { - InsertionGroup insertionGroup = null; - - var context = ApplicationController.Instance.DragDropData; - var scene = context.SceneContext.Scene; - scene.Children.Modify(list => - { - list.Add( - insertionGroup = new InsertionGroup( - selectedLibraryItems, - context.View3DWidget, - scene, - context.SceneContext.BedCenter, - dragOperationActive: () => false)); - }); - - return insertionGroup; - } - public override void OnClosed(ClosedEventArgs e) { if (libraryView?.ActiveContainer != null) From bf1bba079265ab98d5c182186fdc2e744183b36b Mon Sep 17 00:00:00 2001 From: John Lewin Date: Thu, 30 Nov 2017 06:58:27 -0800 Subject: [PATCH 06/11] Remove unused View3DWidget dependency --- ApplicationView/ApplicationController.cs | 5 ++--- Library/Widgets/PrintLibraryWidget.cs | 1 - PartPreviewWindow/View3D/PrinterActionsBar.cs | 2 -- PartPreviewWindow/View3D/SlicePopupMenu.cs | 1 - 4 files changed, 2 insertions(+), 7 deletions(-) diff --git a/ApplicationView/ApplicationController.cs b/ApplicationView/ApplicationController.cs index 593336544..bcd240fd3 100644 --- a/ApplicationView/ApplicationController.cs +++ b/ApplicationView/ApplicationController.cs @@ -1113,7 +1113,7 @@ namespace MatterHackers.MatterControl private string doNotAskAgainMessage = "Don't remind me again".Localize(); - public async Task PrintPart(string partFilePath, string gcodeFilePath, string printItemName, PrinterConfig printer, View3DWidget view3DWidget, SliceProgressReporter reporter, bool overrideAllowGCode = false) + public async Task PrintPart(string partFilePath, string gcodeFilePath, string printItemName, PrinterConfig printer, SliceProgressReporter reporter, bool overrideAllowGCode = false) { // Exit if called in a non-applicable state if (this.ActivePrinter.Connection.CommunicationState != CommunicationStates.Connected @@ -1201,7 +1201,6 @@ namespace MatterHackers.MatterControl printer, partFilePath, gcodeFilePath, - view3DWidget, reporter); partToPrint_SliceDone(partFilePath, gcodeFilePath); @@ -1275,7 +1274,7 @@ namespace MatterHackers.MatterControl } } - public async Task SliceFileLoadOutput(PrinterConfig printer, string partFilePath, string gcodeFilePath, View3DWidget view3DWidget, SliceProgressReporter reporter) + public async Task SliceFileLoadOutput(PrinterConfig printer, string partFilePath, string gcodeFilePath, SliceProgressReporter reporter) { var gcodeLoadCancellationTokenSource = new CancellationTokenSource(); diff --git a/Library/Widgets/PrintLibraryWidget.cs b/Library/Widgets/PrintLibraryWidget.cs index 448747863..9b37f12e7 100644 --- a/Library/Widgets/PrintLibraryWidget.cs +++ b/Library/Widgets/PrintLibraryWidget.cs @@ -400,7 +400,6 @@ namespace MatterHackers.MatterControl.PrintLibrary context.GCodeFilePath, context.SourceItem.Name, printer, - activeContext.View3DWidget, null); }); } diff --git a/PartPreviewWindow/View3D/PrinterActionsBar.cs b/PartPreviewWindow/View3D/PrinterActionsBar.cs index 01cc163b3..a03d5246c 100644 --- a/PartPreviewWindow/View3D/PrinterActionsBar.cs +++ b/PartPreviewWindow/View3D/PrinterActionsBar.cs @@ -293,7 +293,6 @@ namespace MatterHackers.MatterControl.PartPreviewWindow context.GCodeFilePath, context.SourceItem.Name, printer, - printerTabPage.view3DWidget, null); }); }; @@ -314,7 +313,6 @@ namespace MatterHackers.MatterControl.PartPreviewWindow context.GCodeFilePath, context.SourceItem.Name, printer, - printerTabPage.view3DWidget, null); }); }; diff --git a/PartPreviewWindow/View3D/SlicePopupMenu.cs b/PartPreviewWindow/View3D/SlicePopupMenu.cs index 1d5a094df..1817cf950 100644 --- a/PartPreviewWindow/View3D/SlicePopupMenu.cs +++ b/PartPreviewWindow/View3D/SlicePopupMenu.cs @@ -128,7 +128,6 @@ namespace MatterHackers.MatterControl.PartPreviewWindow printer, printer.Bed.EditContext.PartFilePath, printer.Bed.EditContext.GCodeFilePath, - printerTabPage.view3DWidget, new SliceProgressReporter(this.PopupContent, printer)); } catch (Exception ex) From 781017999cf717e8cd7b299c3f9851ed174194a8 Mon Sep 17 00:00:00 2001 From: John Lewin Date: Thu, 30 Nov 2017 07:03:42 -0800 Subject: [PATCH 07/11] Move Selection -> Print from ui to model --- ApplicationView/PrinterModels.cs | 22 ++++++++++++++++++++++ Library/Widgets/PrintLibraryWidget.cs | 19 +------------------ 2 files changed, 23 insertions(+), 18 deletions(-) diff --git a/ApplicationView/PrinterModels.cs b/ApplicationView/PrinterModels.cs index 219f4a185..53038a1c7 100644 --- a/ApplicationView/PrinterModels.cs +++ b/ApplicationView/PrinterModels.cs @@ -153,6 +153,28 @@ namespace MatterHackers.MatterControl return insertionGroup; } + public async Task StashAndPrint(IEnumerable selectedLibraryItems) + { + // Clear plate + await this.ClearPlate(); + + // Add content + var insertionGroup = this.AddToPlate(selectedLibraryItems); + await insertionGroup.LoadingItemsTask; + + // Persist changes + this.Save(); + + // Slice and print + var context = this.EditContext; + await ApplicationController.Instance.PrintPart( + context.PartFilePath, + context.GCodeFilePath, + context.SourceItem.Name, + this.Printer, + null); + } + internal static ILibraryItem LoadLastPlateOrNew() { // Find the last used bed plate mcx diff --git a/Library/Widgets/PrintLibraryWidget.cs b/Library/Widgets/PrintLibraryWidget.cs index 9b37f12e7..5bfa67180 100644 --- a/Library/Widgets/PrintLibraryWidget.cs +++ b/Library/Widgets/PrintLibraryWidget.cs @@ -383,24 +383,7 @@ namespace MatterHackers.MatterControl.PrintLibrary { UiThread.RunOnIdle(async () => { - // Clear plate - await printer.Bed.ClearPlate(); - - // Add content - var insertionGroup = printer.Bed.AddToPlate(selectedLibraryItems); - await insertionGroup.LoadingItemsTask; - - // Persist changes - printer.Bed.Save(); - - // Slice and print - var context = printer.Bed.EditContext; - await ApplicationController.Instance.PrintPart( - context.PartFilePath, - context.GCodeFilePath, - context.SourceItem.Name, - printer, - null); + await printer.Bed.StashAndPrint(selectedLibraryItems); }); } break; From 4c98e099c7819b974d801ff35cb0fda4b0a0071c Mon Sep 17 00:00:00 2001 From: John Lewin Date: Thu, 30 Nov 2017 08:52:01 -0800 Subject: [PATCH 08/11] Remove ApplicationClosed event from ApplicationController --- ApplicationView/ApplicationController.cs | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) diff --git a/ApplicationView/ApplicationController.cs b/ApplicationView/ApplicationController.cs index bcd240fd3..f7735f3cc 100644 --- a/ApplicationView/ApplicationController.cs +++ b/ApplicationView/ApplicationController.cs @@ -266,8 +266,6 @@ namespace MatterHackers.MatterControl public ApplicationView MainView; - public event EventHandler ApplicationClosed; - private EventHandler unregisterEvents; private Dictionary> registeredLibraryActions = new Dictionary>(); @@ -504,16 +502,7 @@ namespace MatterHackers.MatterControl UiThread.RunOnIdle(ReloadAll); } }, ref unregisterEvents); - - // Remove consumed ClientToken from running list on shutdown - ApplicationClosed += (s, e) => - { - ApplicationSettings.Instance.ReleaseClientToken(); - - // Release the waiting ThumbnailGeneration task so it can shutdown gracefully - thumbGenResetEvent?.Set(); - }; - + PrinterConnection.ErrorReported.RegisterEvent((s, e) => { var foundStringEventArgs = e as FoundStringEventArgs; @@ -716,6 +705,9 @@ namespace MatterHackers.MatterControl public void OnApplicationClosed() { + // Release the waiting ThumbnailGeneration task so it can shutdown gracefully + thumbGenResetEvent?.Set(); + // Save changes before close if (this.ActivePrinter != null && this.ActivePrinter != emptyPrinter) @@ -723,7 +715,7 @@ namespace MatterHackers.MatterControl this.ActivePrinter.Bed.Save(); } - ApplicationClosed?.Invoke(null, null); + ApplicationSettings.Instance.ReleaseClientToken(); } static void LoadOemOrDefaultTheme() From cad3c23ef3fbe556ccbc5b394a8bd61638c6e6b6 Mon Sep 17 00:00:00 2001 From: John Lewin Date: Thu, 30 Nov 2017 09:43:33 -0800 Subject: [PATCH 09/11] Improve emulator thread shutdown --- PrinterEmulator/Emulator.cs | 34 ++++++++++++++++++++++------------ 1 file changed, 22 insertions(+), 12 deletions(-) diff --git a/PrinterEmulator/Emulator.cs b/PrinterEmulator/Emulator.cs index c56f0aa0a..b2bb77391 100644 --- a/PrinterEmulator/Emulator.cs +++ b/PrinterEmulator/Emulator.cs @@ -51,7 +51,7 @@ namespace MatterHackers.PrinterEmulator // Dictionary of command and response callback private Dictionary> responses; - private bool shutDown = false; + private bool shuttingDown = false; public Heater HeatedBed { get; } = new Heater("HeatedBed") { CurrentTemperature = 26 }; @@ -148,8 +148,7 @@ namespace MatterHackers.PrinterEmulator public void Dispose() { - ShutDown(); - + this.ShutDown(); Emulator.Instance = null; } @@ -250,9 +249,13 @@ namespace MatterHackers.PrinterEmulator public void ShutDown() { - HeatedBed.Stop(); - Hotend.Stop(); - shutDown = true; + if (!shuttingDown) + { + shuttingDown = true; + + HeatedBed.Stop(); + Hotend.Stop(); + } } public void SimulateReboot() @@ -452,6 +455,8 @@ namespace MatterHackers.PrinterEmulator // Maintain temperatures Task.Run(() => { + Thread.CurrentThread.Name = $"EmulatorHeator{identifier}"; + var random = new Random(); double requiredLoops = 0; @@ -583,7 +588,7 @@ namespace MatterHackers.PrinterEmulator public void Close() { - this.shutDown = true; + this.ShutDown(); } public void Open() @@ -599,7 +604,8 @@ namespace MatterHackers.PrinterEmulator Task.Run(() => { - while (!shutDown) + Thread.CurrentThread.Name = "EmulatorDtr"; + while (!shuttingDown) { if (this.DtrEnable != DsrState) { @@ -613,13 +619,20 @@ namespace MatterHackers.PrinterEmulator Task.Run(() => { - while (!shutDown || receiveQueue.Count > 0) + Thread.CurrentThread.Name = "EmulatorPipeline"; + + while (!shuttingDown || receiveQueue.Count > 0) { if (receiveQueue.Count == 0) { receiveResetEvent.WaitOne(); } + if (shuttingDown) + { + return; + } + if (receiveQueue.Count == 0) { Thread.Sleep(10); @@ -648,11 +661,8 @@ namespace MatterHackers.PrinterEmulator this.IsOpen = false; - this.Close(); this.Dispose(); }); - - this.IsOpen = true; } public void QueueResponse(string line) From 0164f4e85e3ad63713e39c431252d2e496d9834d Mon Sep 17 00:00:00 2001 From: John Lewin Date: Thu, 30 Nov 2017 09:44:16 -0800 Subject: [PATCH 10/11] Abort profile download loop if exiting --- SettingsManagement/OemSettings.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/SettingsManagement/OemSettings.cs b/SettingsManagement/OemSettings.cs index 4d87a4169..30f1bf8cf 100644 --- a/SettingsManagement/OemSettings.cs +++ b/SettingsManagement/OemSettings.cs @@ -205,6 +205,11 @@ namespace MatterHackers.MatterControl.SettingsManagement await Task.Delay(20000); await ProfileManager.LoadOemProfileAsync(publicDevice, oem, model); + if (MatterControlApplication.Instance.ApplicationExiting) + { + return; + } + if (syncReport != null) { reportValue.Status = string.Format("Downloading public profiles for {0}...", oem); From 9b19afcec770e50b205cf7db267557b2a614d2c8 Mon Sep 17 00:00:00 2001 From: John Lewin Date: Thu, 30 Nov 2017 09:44:32 -0800 Subject: [PATCH 11/11] Use extension method syntax --- .../MatterControl.Tests/MatterControl/MatterControlUtilities.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Tests/MatterControl.Tests/MatterControl/MatterControlUtilities.cs b/Tests/MatterControl.Tests/MatterControl/MatterControlUtilities.cs index d64859d98..ccdc92535 100644 --- a/Tests/MatterControl.Tests/MatterControl/MatterControlUtilities.cs +++ b/Tests/MatterControl.Tests/MatterControl/MatterControlUtilities.cs @@ -286,7 +286,7 @@ namespace MatterHackers.MatterControl.Tests.Automation // An unpredictable period of time will pass between Clicking Save, everything reloading and us returning to the caller. // Block until ReloadAll has completed then close and return to the caller, at which point hopefully everything is reloaded. - WaitForReloadAll(testRunner, () => testRunner.ClickByName("Save & Continue Button")); + testRunner.WaitForReloadAll(() => testRunner.ClickByName("Save & Continue Button")); testRunner.ClickByName("Cancel Wizard Button"); testRunner.Delay(1);