"Jakob Eriksson" jakov@vmlinux.org wrote:
Well, line 183 in dlls/gdi/tests/metafile.c detects rather nicely whether we are running in an interactive desktop or not.
I could copy that logic to winetest.exe
metafile.c : 183 ok(emr_processed, "EnumEnhMetaFile couldn't find EMR_EXTTEXTOUTA or EMR_EXTTEXTOUTW record\n");
( http://test.winehq.org/data/200412021000/2000_JakobErikssonBW/gdi32:metafile... )
A better and much simpler test is:
if (!(GetWindowLongA(GetDesktopWindow(), GWL_STYLE) & WS_VISBLE)) trace("running on a not visible desktop\n");