Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ UserInteractive

unsafe bool System.Environment.UserInteractive
staticget

Definition at line 367 of file Environment.cs.

368 {
369 get
370 {
371 IntPtr processWindowStation = Interop.User32.GetProcessWindowStation();
372 if (processWindowStation != IntPtr.Zero)
373 {
375 uint lpnLengthNeeded = 0u;
376 if (Interop.User32.GetUserObjectInformationW(processWindowStation, 1, &uSEROBJECTFLAGS, (uint)sizeof(Interop.User32.USEROBJECTFLAGS), ref lpnLengthNeeded))
377 {
378 return (uSEROBJECTFLAGS.dwFlags & 1) != 0;
379 }
380 }
381 return true;
382 }
383 }
static IntPtr GetProcessWindowStation()
static unsafe bool GetUserObjectInformationW(IntPtr hObj, int nIndex, void *pvBuffer, uint nLength, ref uint lpnLengthNeeded)