Any OpenHardwareMonitorShowDesktopReferenceWindow (even from another process) will be good enough to detect "Show Desktop". This fixes the "Show Desktop" detection in a second instance of the Open Hardware Monitor.

This commit is contained in:
Michael Möller
2010-09-07 18:40:00 +00:00
parent e8909c4f18
commit 4054b2d9fb
+1 -1
View File
@@ -116,7 +116,7 @@ namespace OpenHardwareMonitor.GUI {
// search if the reference window is behind the worker window
IntPtr reference = NativeMethods.FindWindowEx(
IntPtr.Zero, workerWindow, null, referenceWindowCaption);
showDesktopDetected = reference == referenceWindow.Handle;
showDesktopDetected = reference != IntPtr.Zero;
} else {
// if there is no worker window, then nothing can hide the reference
showDesktopDetected = false;