Fixes #4300 - Scrolling intermittently causes All_Scenarios_Quit_And_Init_Shutdown_Properly to fail (#4301)

* Refactor Scrolling.cs for timer management and nullability

Enabled nullable reference types with `#nullable enable` for improved safety. Replaced the `pulsing` flag with a new `_progressTimer` object to better manage the progress bar's timer lifecycle. Updated `AppOnInitialized` and `AppUnloaded` methods to handle timer initialization and cleanup properly, preventing potential memory leaks.

Simplified code by removing unnecessary comments and aligning method signatures with nullable reference type annotations.

* Enable nullable types and add debugging utilities

* Runu tests 5 times

* Adjust abortTime in ScenarioTests to 1800

* Revert "Runu tests 5 times"

This reverts commit b9b5282315.

* Improve CI diagnostics and adjust scenario abort time

* Fix typos, update metadata,

Corrected typos in `ScenarioCategory` and comments in `Mazing.cs`.
Added the `System.Text` namespace to support additional functionality.
Introduced a new "Games" category in `ScenarioCategory`.
Updated `.DotSettings` to include "Mazing" in the user dictionary.
Improved overall code comments and metadata for clarity.

* Remove unnecessary null assertion for _progressTimer

* Update Examples/UICatalog/Scenarios/Scrolling.cs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
Tig
2025-10-21 02:36:52 -06:00
committed by GitHub
parent 7a810b0b87
commit b502471ee6
5 changed files with 23 additions and 20 deletions

View File

@@ -43,7 +43,7 @@ public class ScenarioTests : TestsAllViews
var scenario = Activator.CreateInstance (scenarioType) as Scenario;
var scenarioName = scenario!.GetName ();
uint abortTime = 2200;
uint abortTime = 5000; // Scrolling scenario can take up to 3 seconds to init on slow CI machines
object? timeout = null;
var initialized = false;
var shutdownGracefully = false;