ReactOS  0.4.15-dev-4922-ge8ccc85
winsta.h
Go to the documentation of this file.
1 #pragma once
2 
3 #define WINSTA_OBJ_DIR L"\\Windows\\WindowStations"
4 #define SESSION_DIR L"\\Sessions"
5 
6 /* Window Station Status Flags */
7 #define WSS_LOCKED (1)
8 #define WSS_NOINTERACTIVE (2)
9 #define WSS_NOIO (4)
10 #define WSS_SHUTDOWN (8)
11 #define WSS_DYING (16)
12 #define WSS_REALSHUTDOWN (32)
13 
14 // See also: https://reactos.org/wiki/Techwiki:Win32k/WINDOWSTATION
15 typedef struct _WINSTATION_OBJECT
16 {
18 
21 
23  struct tagKL* spklList;
29  PCLIP pClipBase; // Not a clip object.
35 
40 
41  /* ReactOS-specific */
46 
47 #ifndef _WIN64
49 C_ASSERT(offsetof(WINSTATION_OBJECT, spklList) == 0x14);
50 C_ASSERT(offsetof(WINSTATION_OBJECT, ptiClipLock) == 0x18);
51 C_ASSERT(offsetof(WINSTATION_OBJECT, ptiDrawingClipboard) == 0x1c);
52 C_ASSERT(offsetof(WINSTATION_OBJECT, spwndClipOpen) == 0x20);
53 C_ASSERT(offsetof(WINSTATION_OBJECT, spwndClipViewer) == 0x24);
54 C_ASSERT(offsetof(WINSTATION_OBJECT, spwndClipOwner) == 0x28);
55 #endif
56 
58 extern HANDLE gpidLogon;
59 extern HWND hwndSAS;
61 
62 CODE_SEG("INIT")
64 NTAPI
66 
68 NTAPI
70 
72 NTAPI
75 
77 NTAPI
80 
82 NTAPI
85 
89  HWINSTA WindowStation,
93  POBJECT_HANDLE_INFORMATION pObjectHandleInfo);
94 
98  OUT HWINSTA* phWinSta,
101  IN KPROCESSOR_MODE OwnerMode,
102  IN ACCESS_MASK dwDesiredAccess,
103  DWORD Unknown2,
104  DWORD Unknown3,
105  DWORD Unknown4,
106  DWORD Unknown5,
107  DWORD Unknown6);
108 
110 BOOL FASTCALL UserSetProcessWindowStation(HWINSTA hWindowStation);
111 
115 
116 /* EOF */
IN PUNICODE_STRING IN POBJECT_ATTRIBUTES ObjectAttributes
Definition: conport.c:35
INT fClipboardChanged
Definition: winsta.h:33
#define IN
Definition: typedefs.h:39
_Must_inspect_result_ _In_ WDFDEVICE _In_ ULONG _In_ ACCESS_MASK DesiredAccess
Definition: wdfdevice.h:2654
IN PUNICODE_STRING IN POBJECT_ATTRIBUTES IN DWORD Unknown3
Definition: conport.c:35
HANDLE gpidLogon
Definition: simplecall.c:15
NTSTATUS NTAPI IntWinStaObjectParse(_In_ PVOID Parameters)
Definition: winsta.c:138
_Must_inspect_result_ _In_ WDFQUEUE _In_opt_ WDFREQUEST _In_opt_ WDFFILEOBJECT _Inout_opt_ PWDF_REQUEST_PARAMETERS Parameters
Definition: wdfio.h:863
struct _DESKTOP * ActiveDesktop
Definition: winsta.h:42
INT fInDelayedRendering
Definition: winsta.h:34
HWND hwndSAS
Definition: winsta.c:24
LONG NTSTATUS
Definition: precomp.h:26
IN PUNICODE_STRING IN POBJECT_ATTRIBUTES IN DWORD IN DWORD IN DWORD IN DWORD Unknown6
Definition: conport.c:35
PWND spwndClipOwner
Definition: winsta.h:28
NTSTATUS FASTCALL IntCreateWindowStation(OUT HWINSTA *phWinSta, IN POBJECT_ATTRIBUTES ObjectAttributes, IN KPROCESSOR_MODE AccessMode, IN KPROCESSOR_MODE OwnerMode, IN ACCESS_MASK dwDesiredAccess, DWORD Unknown2, DWORD Unknown3, DWORD Unknown4, DWORD Unknown5, DWORD Unknown6)
Definition: winsta.c:447
LIST_ENTRY DesktopListHead
Definition: winsta.h:19
#define FASTCALL
Definition: nt_native.h:50
PWINSTATION_OBJECT FASTCALL IntGetProcessWindowStation(HWINSTA *phWinSta OPTIONAL)
Definition: winsta.c:400
int32_t INT
Definition: typedefs.h:58
WINSTATION_OBJECT * InputWindowStation
Definition: winsta.c:21
struct tagKL * spklList
Definition: winsta.h:23
UNICODE_STRING gustrWindowStationsDir
Definition: winsta.c:27
PWND spwndClipViewer
Definition: winsta.h:27
PWND spwndClipOpen
Definition: winsta.h:26
C_ASSERT(offsetof(WINSTATION_OBJECT, Flags)==0x10)
LUID luidEndSession
Definition: winsta.h:37
Definition: clipboard.h:3
NTSTATUS(* NTAPI)(IN PFILE_FULL_EA_INFORMATION EaBuffer, IN ULONG EaLength, OUT PULONG ErrorOffset)
Definition: IoEaTest.cpp:117
BOOL FASTCALL co_IntInitializeDesktopGraphics(VOID)
Definition: winsta.c:262
VOID FASTCALL IntEndDesktopGraphics(VOID)
Definition: winsta.c:358
unsigned int BOOL
Definition: ntddk_ex.h:94
PRTL_UNICODE_STRING_BUFFER PULONG PULONG Unknown4
INT iClipSerialNumber
Definition: winsta.h:31
_In_ PEPROCESS _In_ KPROCESSOR_MODE AccessMode
Definition: mmfuncs.h:395
BOOL FASTCALL UserSetProcessWindowStation(HWINSTA hWindowStation)
Definition: winsta.c:1382
#define offsetof(TYPE, MEMBER)
Definition: input.h:26
#define _In_
Definition: ms_sal.h:308
NTSTATUS NTAPI IntWinStaOkToClose(_In_ PVOID Parameters)
Definition: winsta.c:203
_Must_inspect_result_ _In_ ULONG Flags
Definition: wsk.h:170
DWORD dwSessionId
Definition: winsta.h:17
NTSTATUS FASTCALL IntValidateWindowStationHandle(HWINSTA WindowStation, KPROCESSOR_MODE AccessMode, ACCESS_MASK DesiredAccess, PWINSTATION_OBJECT *Object, POBJECT_HANDLE_INFORMATION pObjectHandleInfo)
Definition: winsta.c:232
PTHREADINFO ptiClipLock
Definition: winsta.h:24
PCLIP pClipBase
Definition: winsta.h:29
unsigned long DWORD
Definition: ntddk_ex.h:95
struct _WINSTATION_OBJECT * PWINSTATION_OBJECT
CCHAR KPROCESSOR_MODE
Definition: ketypes.h:7
struct _WINSTATION_OBJECT WINSTATION_OBJECT
NTSTATUS NTAPI IntWinStaObjectDelete(_In_ PVOID Parameters)
Definition: winsta.c:106
DWORD cNumClipFormats
Definition: winsta.h:30
Definition: typedefs.h:119
struct atom_table ** PRTL_ATOM_TABLE
Definition: atom.c:43
_Must_inspect_result_ _In_ WDFCOLLECTION _In_ WDFOBJECT Object
Definition: ntuser.h:672
PTHREADINFO ptiDrawingClipboard
Definition: winsta.h:25
PRTL_ATOM_TABLE AtomTable
Definition: winsta.h:20
NTSTATUS NTAPI InitWindowStationImpl(VOID)
Definition: winsta.c:34
PWND spwndClipboardListener
Definition: winsta.h:36
BOOL FASTCALL CheckWinstaAttributeAccess(ACCESS_MASK)
Definition: winsta.c:377
#define OUT
Definition: typedefs.h:40
unsigned int ULONG
Definition: retypes.h:1
PVOID psidUser
Definition: winsta.h:39
IN PUNICODE_STRING IN POBJECT_ATTRIBUTES IN DWORD IN DWORD IN DWORD Unknown5
Definition: conport.c:35
INT iClipSequenceNumber
Definition: winsta.h:32
NTSTATUS NTAPI UserCreateWinstaDirectory(VOID)
Definition: winsta.c:51
static CODE_SEG("PAGE")
Definition: isapnp.c:1482
HANDLE ShellListView
Definition: winsta.h:44
ULONG ACCESS_MASK
Definition: nt_native.h:40
HANDLE ShellWindow
Definition: winsta.h:43
PULONG MinorVersion OPTIONAL
Definition: CrossNt.h:68