Author: jimtabor Date: Thu Jan 14 03:52:12 2010 New Revision: 45070
URL: http://svn.reactos.org/svn/reactos?rev=45070&view=rev Log: [Win32k] - Updated headers and related files.
Modified: trunk/reactos/subsystems/win32/win32k/include/desktop.h trunk/reactos/subsystems/win32/win32k/include/win32.h trunk/reactos/subsystems/win32/win32k/main/dllmain.c trunk/reactos/subsystems/win32/win32k/ntuser/caret.c trunk/reactos/subsystems/win32/win32k/ntuser/class.c trunk/reactos/subsystems/win32/win32k/ntuser/clipboard.c trunk/reactos/subsystems/win32/win32k/ntuser/desktop.c trunk/reactos/subsystems/win32/win32k/ntuser/hook.c trunk/reactos/subsystems/win32/win32k/ntuser/input.c trunk/reactos/subsystems/win32/win32k/ntuser/misc.c trunk/reactos/subsystems/win32/win32k/ntuser/msgqueue.c trunk/reactos/subsystems/win32/win32k/ntuser/painting.c trunk/reactos/subsystems/win32/win32k/ntuser/simplecall.c trunk/reactos/subsystems/win32/win32k/ntuser/sysparams.c trunk/reactos/subsystems/win32/win32k/ntuser/useratom.c trunk/reactos/subsystems/win32/win32k/ntuser/window.c trunk/reactos/subsystems/win32/win32k/ntuser/winpos.c trunk/reactos/subsystems/win32/win32k/ntuser/winsta.c
Modified: trunk/reactos/subsystems/win32/win32k/include/desktop.h URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/inc... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/desktop.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/desktop.h [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -8,6 +8,8 @@ { PDESKTOPINFO pDeskInfo; LIST_ENTRY ListEntry; + /* Pointer to the associated window station. */ + struct _WINSTATION_OBJECT *rpwinstaParent; PWND spwndForeground; PWND spwndTray; PWND spwndMessage; @@ -23,12 +25,8 @@ DWORD dwMouseHoverTime;
/* ReactOS */ - CSHORT Type; - CSHORT Size; /* Rectangle of the work area */ RECTL WorkArea; - /* Pointer to the associated window station. */ - struct _WINSTATION_OBJECT *WindowStation; /* Pointer to the active queue. */ PVOID ActiveMessageQueue; /* Handle of the desktop window. */ @@ -130,7 +128,7 @@ HDC FASTCALL UserGetDesktopDC(ULONG,BOOL,BOOL);
#define IntIsActiveDesktop(Desktop) \ - ((Desktop)->WindowStation->ActiveDesktop == (Desktop)) + ((Desktop)->rpwinstaParent->ActiveDesktop == (Desktop))
#define GET_DESKTOP_NAME(d) \ OBJECT_HEADER_TO_NAME_INFO(OBJECT_TO_OBJECT_HEADER(d)) ? \ @@ -210,10 +208,10 @@ ULONG_PTR Delta = 0;
pti = PsGetCurrentThreadWin32Thread(); - if (!pti->Desktop) + if (!pti->rpdesk) return 0;
- pheapDesktop = pti->Desktop->pheapDesktop; + pheapDesktop = pti->rpdesk->pheapDesktop;
W32Process = PsGetCurrentProcessWin32Process(); Mapping = W32Process->HeapMappings.Next;
Modified: trunk/reactos/subsystems/win32/win32k/include/win32.h URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/inc... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/win32.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/win32.h [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -70,7 +70,7 @@ struct _USER_MESSAGE_QUEUE* MessageQueue; struct _KBL* KeyboardLayout; PCLIENTTHREADINFO pcti; - struct _DESKTOP* Desktop; + struct _DESKTOP* rpdesk; PDESKTOPINFO pDeskInfo; PCLIENTINFO pClientInfo; FLONG TIF_flags; @@ -78,7 +78,7 @@ LONG timeLast; ULONG_PTR idLast; INT exitCode; - HANDLE hDesktop; + HDESK hdesk; UINT cPaintsReady; /* Count of paints pending. */ UINT cTimersReady; /* Count of timers pending. */ DWORD dwExpWinVer;
Modified: trunk/reactos/subsystems/win32/win32k/main/dllmain.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/mai... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/main/dllmain.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/main/dllmain.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -246,7 +246,7 @@ if (hDesk != NULL) { PDESKTOP DesktopObject; - Win32Thread->Desktop = NULL; + Win32Thread->rpdesk = NULL; Status = ObReferenceObjectByHandle(hDesk, 0, ExDesktopObjectType,
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/caret.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/caret.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/caret.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -62,7 +62,7 @@ { /* Don't save the new value to the registry! */ PTHREADINFO pti = PsGetCurrentThreadWin32Thread(); - PWINSTATION_OBJECT WinStaObject = pti->Desktop->WindowStation; + PWINSTATION_OBJECT WinStaObject = pti->rpdesk->rpwinstaParent;
/* windows doesn't do this check */ if((uMSeconds < MIN_CARETBLINKRATE) || (uMSeconds > MAX_CARETBLINKRATE)) @@ -152,7 +152,7 @@ UINT Ret;
pti = PsGetCurrentThreadWin32Thread(); - WinStaObject = pti->Desktop->WindowStation; + WinStaObject = pti->rpdesk->rpwinstaParent;
Ret = WinStaObject->CaretBlinkRate; if(!Ret)
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/class.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/class.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/class.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -1265,7 +1265,7 @@ MenuName, fnID, dwFlags, - pti->Desktop, + pti->rpdesk, pi);
if (Class != NULL)
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/clipboard.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/clipboard.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/clipboard.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -1133,7 +1133,7 @@ PWINSTATION_OBJECT WinStaObj;
pti = PsGetCurrentThreadWin32Thread(); - WinStaObj = pti->Desktop->WindowStation; + WinStaObj = pti->rpdesk->rpwinstaParent;
WinStaObj->Clipboard->ClipboardSequenceNumber++; }
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/desktop.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/desktop.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/desktop.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -144,10 +144,10 @@ /* Initialize shell hook window list and set the parent */ RtlZeroMemory(Desktop, sizeof(DESKTOP)); InitializeListHead(&Desktop->ShellHookWindows); - Desktop->WindowStation = (PWINSTATION_OBJECT)ParseObject; + Desktop->rpwinstaParent = (PWINSTATION_OBJECT)ParseObject;
/* Put the desktop on the window station's list of associated desktops */ - InsertTailList(&Desktop->WindowStation->DesktopListHead, + InsertTailList(&Desktop->rpwinstaParent->DesktopListHead, &Desktop->ListEntry);
/* Set the desktop object and return success */ @@ -572,7 +572,7 @@ HWND FASTCALL IntGetCurrentThreadDesktopWindow(VOID) { PTHREADINFO pti = PsGetCurrentThreadWin32Thread(); - PDESKTOP pdo = pti->Desktop; + PDESKTOP pdo = pti->rpdesk; if (NULL == pdo) { DPRINT1("Thread doesn't have a desktop\n"); @@ -796,7 +796,7 @@ BOOL IntRegisterShellHookWindow(HWND hWnd) { PTHREADINFO pti = PsGetCurrentThreadWin32Thread(); - PDESKTOP Desktop = pti->Desktop; + PDESKTOP Desktop = pti->rpdesk; PSHELL_HOOK_WINDOW Entry;
DPRINT("IntRegisterShellHookWindow\n"); @@ -828,7 +828,7 @@ BOOL IntDeRegisterShellHookWindow(HWND hWnd) { PTHREADINFO pti = PsGetCurrentThreadWin32Thread(); - PDESKTOP Desktop = pti->Desktop; + PDESKTOP Desktop = pti->rpdesk; PSHELL_HOOK_WINDOW Current;
LIST_FOR_EACH(Current, &Desktop->ShellHookWindows, SHELL_HOOK_WINDOW, ListEntry) @@ -1103,7 +1103,7 @@
W32Thread = PsGetCurrentThreadWin32Thread();
- if (!W32Thread->Desktop) IntSetThreadDesktop(DesktopObject,FALSE); + if (!W32Thread->rpdesk) IntSetThreadDesktop(DesktopObject,FALSE);
/* Based on wine/server/window.c in get_desktop_window. @@ -1447,7 +1447,7 @@ UINT align_old; int mode_old; PTHREADINFO pti = PsGetCurrentThreadWin32Thread(); - PWINSTATION_OBJECT WinSta = pti->Desktop->WindowStation; + PWINSTATION_OBJECT WinSta = pti->rpdesk->rpwinstaParent; DECLARE_RETURN(BOOL);
UserEnterExclusive(); @@ -1676,7 +1676,7 @@ * Don't allow applications switch the desktop if it's locked, unless the caller * is the logon application itself */ - if((DesktopObject->WindowStation->Flags & WSS_LOCKED) && + if((DesktopObject->rpwinstaParent->Flags & WSS_LOCKED) && LogonProcess != NULL && LogonProcess != PsGetCurrentProcessWin32Process()) { ObDereferenceObject(DesktopObject); @@ -1684,7 +1684,7 @@ RETURN(FALSE); }
- if(DesktopObject->WindowStation != InputWindowStation) + if(DesktopObject->rpwinstaParent != InputWindowStation) { ObDereferenceObject(DesktopObject); DPRINT1("Switching desktop 0x%x denied because desktop doesn't belong to the interactive winsta!\n", hDesktop); @@ -1763,14 +1763,14 @@ { /* just return the handle, we queried the desktop handle of a thread running in the same context */ - Ret = ((PTHREADINFO)Thread->Tcb.Win32Thread)->hDesktop; + Ret = ((PTHREADINFO)Thread->Tcb.Win32Thread)->hdesk; ObDereferenceObject(Thread); RETURN(Ret); }
/* get the desktop handle and the desktop of the thread */ - if(!(hThreadDesktop = ((PTHREADINFO)Thread->Tcb.Win32Thread)->hDesktop) || - !(DesktopObject = ((PTHREADINFO)Thread->Tcb.Win32Thread)->Desktop)) + if(!(hThreadDesktop = ((PTHREADINFO)Thread->Tcb.Win32Thread)->hdesk) || + !(DesktopObject = ((PTHREADINFO)Thread->Tcb.Win32Thread)->rpdesk)) { ObDereferenceObject(Thread); DPRINT1("Desktop information of thread 0x%x broken!?\n", dwThreadId); @@ -1954,9 +1954,9 @@ MapHeap = (PsGetCurrentProcess() != PsInitialSystemProcess); W32Thread = PsGetCurrentThreadWin32Thread();
- if (W32Thread->Desktop != DesktopObject) + if (W32Thread->rpdesk != DesktopObject) { - OldDesktop = W32Thread->Desktop; + OldDesktop = W32Thread->rpdesk;
if (!IsListEmpty(&W32Thread->WindowListHead)) { @@ -1965,7 +1965,7 @@ return FALSE; }
- W32Thread->Desktop = DesktopObject; + W32Thread->rpdesk = DesktopObject;
if (MapHeap && DesktopObject != NULL) {
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/hook.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/hook.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/hook.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -121,7 +121,7 @@ W32Thread->pDeskInfo->fsHooks= W32Thread->fsHooks;
Hook->head.pti = W32Thread; - Hook->head.rpdesk = W32Thread->Desktop; + Hook->head.rpdesk = W32Thread->rpdesk; }
RtlInitUnicodeString(&Hook->ModuleName, NULL);
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/input.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/input.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/input.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -990,7 +990,7 @@ PTHREADINFO OldBlock; ASSERT(W32Thread);
- if(!W32Thread->Desktop || ((W32Thread->TIF_flags & TIF_INCLEANUP) && BlockIt)) + if(!W32Thread->rpdesk || ((W32Thread->TIF_flags & TIF_INCLEANUP) && BlockIt)) { /* * fail blocking if exiting the thread @@ -1004,14 +1004,14 @@ * e.g. services running in the service window station cannot block input */ if(!ThreadHasInputAccess(W32Thread) || - !IntIsActiveDesktop(W32Thread->Desktop)) + !IntIsActiveDesktop(W32Thread->rpdesk)) { SetLastWin32Error(ERROR_ACCESS_DENIED); return FALSE; }
- ASSERT(W32Thread->Desktop); - OldBlock = W32Thread->Desktop->BlockInputThread; + ASSERT(W32Thread->rpdesk); + OldBlock = W32Thread->rpdesk->BlockInputThread; if(OldBlock) { if(OldBlock != W32Thread) @@ -1019,11 +1019,11 @@ SetLastWin32Error(ERROR_ACCESS_DENIED); return FALSE; } - W32Thread->Desktop->BlockInputThread = (BlockIt ? W32Thread : NULL); + W32Thread->rpdesk->BlockInputThread = (BlockIt ? W32Thread : NULL); return OldBlock == NULL; }
- W32Thread->Desktop->BlockInputThread = (BlockIt ? W32Thread : NULL); + W32Thread->rpdesk->BlockInputThread = (BlockIt ? W32Thread : NULL); return OldBlock == NULL; }
@@ -1394,7 +1394,7 @@ /* Do not attach to system threads or between different desktops. */ if ( pti->TIF_flags & TIF_DONTATTACHQUEUE || ptiTo->TIF_flags & TIF_DONTATTACHQUEUE || - pti->Desktop != ptiTo->Desktop ) + pti->rpdesk != ptiTo->rpdesk ) return FALSE;
/* If Attach set, allocate and link. */ @@ -1451,7 +1451,7 @@ W32Thread = PsGetCurrentThreadWin32Thread(); ASSERT(W32Thread);
- if(!W32Thread->Desktop) + if(!W32Thread->rpdesk) { RETURN( 0); } @@ -1467,7 +1467,7 @@ * e.g. services running in the service window station cannot block input */ if(!ThreadHasInputAccess(W32Thread) || - !IntIsActiveDesktop(W32Thread->Desktop)) + !IntIsActiveDesktop(W32Thread->rpdesk)) { SetLastWin32Error(ERROR_ACCESS_DENIED); RETURN( 0);
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/misc.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/misc.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/misc.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -191,13 +191,13 @@ SetLastWin32Error(ERROR_ACCESS_DENIED); RETURN( FALSE); } - Desktop = ((PTHREADINFO)Thread->Tcb.Win32Thread)->Desktop; + Desktop = ((PTHREADINFO)Thread->Tcb.Win32Thread)->rpdesk; } else { /* get the foreground thread */ PTHREADINFO W32Thread = (PTHREADINFO)PsGetCurrentThread()->Tcb.Win32Thread; - Desktop = W32Thread->Desktop; + Desktop = W32Thread->rpdesk; if(Desktop) { MsgQueue = Desktop->ActiveMessageQueue; @@ -474,9 +474,9 @@
pti->pcti = &pti->cti; // FIXME Need to set it in desktop.c!
- if (pti->Desktop != NULL) + if (pti->rpdesk != NULL) { - pti->pDeskInfo = pti->Desktop->pDeskInfo; + pti->pDeskInfo = pti->rpdesk->pDeskInfo; } else {
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/msgqueue.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/msgqueue.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/msgqueue.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -240,7 +240,7 @@ BOOL Res = FALSE;
pti = PsGetCurrentThreadWin32Thread(); - if (pti->Desktop == NULL) + if (pti->rpdesk == NULL) { return FALSE; } @@ -281,7 +281,7 @@ BOOL Res;
pti = PsGetCurrentThreadWin32Thread(); - if (pti->Desktop == NULL) + if (pti->rpdesk == NULL) { return FALSE; }
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/painting.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/painting.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/painting.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -702,7 +702,7 @@
ASSERT_REFS_CO(Window);
- Desktop = ((PTHREADINFO)PsGetCurrentThread()->Tcb.Win32Thread)->Desktop; + Desktop = ((PTHREADINFO)PsGetCurrentThread()->Tcb.Win32Thread)->rpdesk; CaretInfo = ((PUSER_MESSAGE_QUEUE)Desktop->ActiveMessageQueue)->CaretInfo; hWndCaret = CaretInfo->hWnd;
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/simplecall.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/simplecall.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/simplecall.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -309,7 +309,7 @@ BOOL Ret = TRUE; PPOINTL pptl; PTHREADINFO pti = PsGetCurrentThreadWin32Thread(); - if (pti->hDesktop != InputDesktopHandle) RETURN(FALSE); + if (pti->hdesk != InputDesktopHandle) RETURN(FALSE); _SEH2_TRY { pptl = (PPOINTL)Param;
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/sysparams.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/sysparams.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/sysparams.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -898,7 +898,7 @@ case SPI_GETWORKAREA: // FIXME: the workarea should be part of the MONITOR { PTHREADINFO pti = PsGetCurrentThreadWin32Thread(); - PDESKTOP pdesktop = pti->Desktop; + PDESKTOP pdesktop = pti->rpdesk; RECTL rclWorkarea;
if(!pdesktop) @@ -911,7 +911,7 @@ case SPI_SETWORKAREA: // FIXME: the workarea should be part of the MONITOR { PTHREADINFO pti = PsGetCurrentThreadWin32Thread(); - PDESKTOP pdesktop = pti->Desktop; + PDESKTOP pdesktop = pti->rpdesk; RECT rcWorkArea;
if(!pdesktop)
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/useratom.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/useratom.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/useratom.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -37,7 +37,7 @@ RTL_ATOM Atom;
pti = PsGetCurrentThreadWin32Thread(); - if (pti->Desktop == NULL) + if (pti->rpdesk == NULL) { SetLastNtError(Status); return (RTL_ATOM)0; @@ -61,7 +61,7 @@ ULONG Size = nSize;
pti = PsGetCurrentThreadWin32Thread(); - if (pti->Desktop == NULL) + if (pti->rpdesk == NULL) { SetLastNtError(Status); return 0;
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/window.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/window.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/window.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -438,13 +438,13 @@ /* don't remove the WINDOWSTATUS_DESTROYING bit */
/* reset shell window handles */ - if(ThreadData->Desktop) - { - if (Window->hSelf == ThreadData->Desktop->WindowStation->ShellWindow) - ThreadData->Desktop->WindowStation->ShellWindow = NULL; - - if (Window->hSelf == ThreadData->Desktop->WindowStation->ShellListView) - ThreadData->Desktop->WindowStation->ShellListView = NULL; + if(ThreadData->rpdesk) + { + if (Window->hSelf == ThreadData->rpdesk->rpwinstaParent->ShellWindow) + ThreadData->rpdesk->rpwinstaParent->ShellWindow = NULL; + + if (Window->hSelf == ThreadData->rpdesk->rpwinstaParent->ShellListView) + ThreadData->rpdesk->rpwinstaParent->ShellListView = NULL; }
/* Unregister hot keys */ @@ -861,7 +861,7 @@ { W32Thread = PsGetCurrentThreadWin32Thread();
- if(!W32Thread->Desktop) + if(!W32Thread->rpdesk) return NULL;
if(Window->SystemMenu) @@ -874,10 +874,10 @@ } }
- if(W32Thread->Desktop->WindowStation->SystemMenuTemplate) + if(W32Thread->rpdesk->rpwinstaParent->SystemMenuTemplate) { /* clone system menu */ - Menu = UserGetMenuObject(W32Thread->Desktop->WindowStation->SystemMenuTemplate); + Menu = UserGetMenuObject(W32Thread->rpdesk->rpwinstaParent->SystemMenuTemplate); if(!Menu) return NULL;
@@ -1703,9 +1703,9 @@
pti = PsGetCurrentThreadWin32Thread();
- if (pti->Desktop) - { - ParentWindowHandle = pti->Desktop->DesktopWindow; + if (pti->rpdesk) + { + ParentWindowHandle = pti->rpdesk->DesktopWindow; }
@@ -1759,7 +1759,7 @@
/* Check the window station. */ ti = GetW32ThreadInfo(); - if (ti == NULL || pti->Desktop == NULL) + if (ti == NULL || pti->rpdesk == NULL) { DPRINT1("Thread is not attached to a desktop! Cannot create window!\n"); RETURN( (PWND)0); @@ -1792,14 +1792,14 @@ DPRINT("ClassAtom %x\n", ClassAtom); Class = IntReferenceClass(Class, ClassLink, - pti->Desktop); + pti->rpdesk); if (Class == NULL) { DPRINT1("Failed to reference window class!\n"); RETURN(NULL); }
- WinSta = pti->Desktop->WindowStation; + WinSta = pti->rpdesk->rpwinstaParent;
//FIXME: Reference thread/desktop instead ObReferenceObjectByPointer(WinSta, KernelMode, ExWindowStationObjectType, 0); @@ -1811,7 +1811,7 @@ sizeof(WINDOW_OBJECT)); if (Window) { - Window->Wnd = DesktopHeapAlloc(pti->Desktop, + Window->Wnd = DesktopHeapAlloc(pti->rpdesk, sizeof(WND) + Class->cbwndExtra); if (!Window->Wnd) goto AllocErr; @@ -1822,7 +1822,7 @@ Wnd->fnid = 0;
Wnd->head.pti = ti; - Wnd->head.rpdesk = pti->Desktop; + Wnd->head.rpdesk = pti->rpdesk; Wnd->hWndLastActive = hWnd; Wnd->state2 |= WNDS2_WIN40COMPAT; } @@ -1840,11 +1840,11 @@
ObDereferenceObject(WinSta);
- if (NULL == pti->Desktop->DesktopWindow) + if (NULL == pti->rpdesk->DesktopWindow) { /* If there is no desktop window yet, we must be creating it */ - pti->Desktop->DesktopWindow = hWnd; - pti->Desktop->pDeskInfo->spwnd = Wnd; + pti->rpdesk->DesktopWindow = hWnd; + pti->rpdesk->pDeskInfo->spwnd = Wnd; }
/* @@ -2109,7 +2109,7 @@ PRTL_USER_PROCESS_PARAMETERS ProcessParams; BOOL CalculatedDefPosSize = FALSE;
- IntGetDesktopWorkArea(((PTHREADINFO)Window->pti->pEThread->Tcb.Win32Thread)->Desktop, &WorkArea); + IntGetDesktopWorkArea(Window->pti->rpdesk, &WorkArea);
rc = WorkArea; ProcessParams = PsGetCurrentProcess()->Peb->ProcessParameters; @@ -3888,7 +3888,7 @@ /* * Remove extended window style bit WS_EX_TOPMOST for shell windows. */ - WindowStation = Window->pti->Desktop->WindowStation; + WindowStation = Window->pti->rpdesk->rpwinstaParent; if(WindowStation) { if (hWnd == WindowStation->ShellWindow || hWnd == WindowStation->ShellListView)
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/winpos.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/winpos.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/winpos.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -257,7 +257,7 @@ { RECTL WorkArea; PTHREADINFO pti = PsGetCurrentThreadWin32Thread(); - PDESKTOP Desktop = pti->Desktop; /* Or rather get it from the window? */ + PDESKTOP Desktop = pti->rpdesk; /* Or rather get it from the window? */
Parent = Window->spwndParent; if(Parent) @@ -405,7 +405,7 @@ UINT XInc, YInc; RECTL WorkArea; PTHREADINFO pti = PsGetCurrentThreadWin32Thread(); - PDESKTOP Desktop = pti->Desktop; /* Or rather get it from the window? */ + PDESKTOP Desktop = pti->rpdesk; /* Or rather get it from the window? */
IntGetDesktopWorkArea(Desktop, &WorkArea);
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/winsta.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ntu... ============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/winsta.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/winsta.c [iso-8859-1] Thu Jan 14 03:52:12 2010 @@ -900,7 +900,7 @@ { DPRINT1("Should use ObFindHandleForObject\n"); pti = PsGetCurrentThreadWin32Thread(); - Status = ObOpenObjectByPointer(pti->Desktop->WindowStation, + Status = ObOpenObjectByPointer(pti->rpdesk->rpwinstaParent, 0, NULL, WINSTA_ALL_ACCESS, @@ -951,9 +951,9 @@ */
Win32Thread = PsGetCurrentThreadWin32Thread(); - if(Win32Thread != NULL && Win32Thread->Desktop != NULL) - { - WinStaObj = Win32Thread->Desktop->WindowStation; + if(Win32Thread != NULL && Win32Thread->rpdesk != NULL) + { + WinStaObj = Win32Thread->rpdesk->rpwinstaParent; ObReferenceObjectByPointer(WinStaObj, KernelMode, ExWindowStationObjectType, 0); } else if((CurrentProcess = PsGetCurrentProcess()) != CsrProcess)