From 070ef48aa75d9a16521240b82c73baf9136be6c4 Mon Sep 17 00:00:00 2001 From: brendanx67 Date: Tue, 10 Dec 2024 12:55:54 -0800 Subject: [PATCH] Skyline: Minor tweaks to AbstractFunctionalTest for screenshots - Fix Skyline icon displaying on control-box forms - Always WaitForGraphs it taking a screenshot in PauseForScreenShot --- pwiz_tools/Skyline/TestUtil/TestFunctional.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pwiz_tools/Skyline/TestUtil/TestFunctional.cs b/pwiz_tools/Skyline/TestUtil/TestFunctional.cs index b65d904497..da2a9535e8 100644 --- a/pwiz_tools/Skyline/TestUtil/TestFunctional.cs +++ b/pwiz_tools/Skyline/TestUtil/TestFunctional.cs @@ -290,7 +290,7 @@ protected static TDlg ShowDialog(Action act, int millis = -1) where TDlg : if (IsRecordingScreenShots && dlg.ShowIcon && !ReferenceEquals(dlg, SkylineWindow)) { if (dlg.FormBorderStyle != FormBorderStyle.FixedDialog || - dlg.Icon != null) // Normally a fixed dialog will not have the Skyline icon handle + dlg.Icon.Handle == Resources.Skyline.Handle) // Normally a fixed dialog will not have the Skyline icon handle { var ico = dlg.Icon.Handle; if (ico != SkylineWindow.Icon.Handle) @@ -1882,6 +1882,8 @@ private void PauseForScreenShotInternal(string description, Type formType = null Thread.Sleep(Program.PauseSeconds * 1000); else if ((IsPauseForScreenShots || IsAutoScreenShotMode) && Math.Max(PauseStartingPage, Program.PauseStartingPage) <= ScreenshotCounter) { + WaitForGraphs(); // Screenshots always need graphs to be fully updated + if (screenshotForm == null) { if (!fullScreen && formType != null)