From 8e1057e676228bf323a809971c9dc47c19649691 Mon Sep 17 00:00:00 2001 From: dahall Date: Tue, 22 Dec 2020 11:45:04 -0700 Subject: [PATCH] Exposed public properties in SystemEventHandler --- PInvoke/User32/SystemEventHandler.cs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/PInvoke/User32/SystemEventHandler.cs b/PInvoke/User32/SystemEventHandler.cs index 95195580..1104ce3d 100644 --- a/PInvoke/User32/SystemEventHandler.cs +++ b/PInvoke/User32/SystemEventHandler.cs @@ -56,9 +56,13 @@ namespace Vanara.PInvoke Dispose(false); } + /// Gets a value indicating whether this instance is running in a thread. + /// if this instance is running in a thread; otherwise, . + public bool IsRunningInThread => ThreadRunning is not null; + /// Gets the message window handle which can be used to register for messaged events. /// The message window handle. - protected HWND MessageWindowHandle => msgWindow?.Handle ?? HWND.NULL; + public HWND MessageWindowHandle => msgWindow?.Handle ?? HWND.NULL; private ManualResetEvent ThreadRunning { get; set; }