EVENT_SYSTEM_FOREGROUND Notes

[This is preliminary documentation and subject to change.]

The system generates this event even if the foreground window is changing to another window in the same thread.

For this event, the WinEventProc callback function's hwnd parameter is the handle to the window that is now in the foreground, and the idObject parameter is OBJID_WINDOW. The idChild parameter is CHILDID_SELF.