Add host activity and DB browser, and keep dialogs, drag-drop, and idle maintenance responsive.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-08-28 02:03:52 +02:00
parent b72c375e87
commit b33a78dbbe
45 changed files with 3254 additions and 171 deletions

View File

@@ -0,0 +1,23 @@
using System.Windows;
using System.Windows.Input;
namespace Explorer.App;
/// <summary>
/// Close helpers for windows opened with <see cref="Window.Show"/>.
/// <see cref="Button.IsCancel"/> sets <see cref="Window.DialogResult"/>, which throws on modeless windows.
/// </summary>
internal static class ModelessWindowClose
{
public static void EnableEscape(Window window)
=> window.PreviewKeyDown += (_, e) =>
{
if (e.Key != Key.Escape)
{
return;
}
window.Close();
e.Handled = true;
};
}