ReactOS.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
List overview
Download
Ros-diffs
April 2008
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
ros-diffs@reactos.org
21 participants
395 discussions
Start a n
N
ew thread
[jimtabor] 32995: Removed w.ArcDirection. Now we are using dclevel path flags.
by jimtabor@svn.reactos.org
Author: jimtabor Date: Wed Apr 16 22:46:46 2008 New Revision: 32995 URL:
http://svn.reactos.org/svn/reactos?rev=32995&view=rev
Log: Removed w.ArcDirection. Now we are using dclevel path flags. Modified: trunk/reactos/include/reactos/win32k/ntgdihdl.h trunk/reactos/subsystems/win32/win32k/objects/coord.c trunk/reactos/subsystems/win32/win32k/objects/dc.c trunk/reactos/subsystems/win32/win32k/objects/path.c Modified: trunk/reactos/include/reactos/win32k/ntgdihdl.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/reactos/win32k/ntg…
============================================================================== --- trunk/reactos/include/reactos/win32k/ntgdihdl.h [iso-8859-1] (original) +++ trunk/reactos/include/reactos/win32k/ntgdihdl.h [iso-8859-1] Wed Apr 16 22:46:46 2008 @@ -346,7 +346,6 @@ INT DCOrgX; /* DC origin */ INT DCOrgY; - INT ArcDirection; XFORM xformWorld2Wnd; /* World-to-window transformation */ XFORM xformWorld2Vport; /* World-to-viewport transformation */ Modified: trunk/reactos/subsystems/win32/win32k/objects/coord.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/objects/coord.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/objects/coord.c [iso-8859-1] Wed Apr 16 22:46:46 2008 @@ -980,10 +980,10 @@ if (!(Dc_Attr->flTextAlign & TA_CENTER)) Dc_Attr->flTextAlign |= TA_RIGHT; - if (dc->w.ArcDirection == AD_CLOCKWISE) - dc->w.ArcDirection = AD_COUNTERCLOCKWISE; + if (dc->DcLevel.flPath & DCPATH_CLOCKWISE) + dc->DcLevel.flPath &= ~DCPATH_CLOCKWISE; else - dc->w.ArcDirection = AD_CLOCKWISE; + dc->DcLevel.flPath |= DCPATH_CLOCKWISE; Dc_Attr->flXform |= (PAGE_EXTENTS_CHANGED|INVALIDATE_ATTRIBUTES|DEVICE_TO_WORLD_INVALID); Modified: trunk/reactos/subsystems/win32/win32k/objects/dc.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/objects/dc.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/objects/dc.c [iso-8859-1] Wed Apr 16 22:46:46 2008 @@ -146,6 +146,7 @@ nDc_Attr->jROP2 = oDc_Attr->jROP2; nDc_Attr->dwLayout = oDc_Attr->dwLayout; if (oDc_Attr->dwLayout & LAYOUT_ORIENTATIONMASK) Layout = oDc_Attr->dwLayout; + NewDC->DcLevel.flPath = OrigDC->DcLevel.flPath; DC_UnlockDc(NewDC); DC_UnlockDc(OrigDC); @@ -828,6 +829,7 @@ NewDC->erclWindow.top = NewDC->erclWindow.left = 0; NewDC->erclWindow.right = ((PGDIDEVICE)NewDC->pPDev)->GDIInfo.ulHorzRes; NewDC->erclWindow.bottom = ((PGDIDEVICE)NewDC->pPDev)->GDIInfo.ulVertRes; + NewDC->DcLevel.flPath = DCPATH_CLOCKWISE; DC_UnlockDc( NewDC ); @@ -1248,7 +1250,7 @@ #endif nDc_Attr->ptlCurrent = Dc_Attr->ptlCurrent; nDc_Attr->ptfxCurrent = Dc_Attr->ptfxCurrent; - newdc->w.ArcDirection = dc->w.ArcDirection; + newdc->DcLevel.flPath = dc->DcLevel.flPath; newdc->w.xformWorld2Wnd = dc->w.xformWorld2Wnd; newdc->w.xformWorld2Vport = dc->w.xformWorld2Vport; newdc->w.xformVport2World = dc->w.xformVport2World; @@ -1318,7 +1320,7 @@ #endif Dc_Attr->ptlCurrent = sDc_Attr->ptlCurrent; Dc_Attr->ptfxCurrent = sDc_Attr->ptfxCurrent; - dc->w.ArcDirection = dcs->w.ArcDirection; + dc->DcLevel.flPath = dcs->DcLevel.flPath; dc->w.xformWorld2Wnd = dcs->w.xformWorld2Wnd; dc->w.xformWorld2Vport = dcs->w.xformWorld2Vport; dc->w.xformVport2World = dcs->w.xformVport2World; @@ -2105,7 +2107,10 @@ SafeResult = Dc_Attr->cBreak; break; case GdiGetArcDirection: - SafeResult = dc->w.ArcDirection; + if (Dc_Attr->dwLayout & LAYOUT_RTL) + SafeResult = AD_CLOCKWISE - ((dc->DcLevel.flPath & DCPATH_CLOCKWISE) != 0); + else + SafeResult = ((dc->DcLevel.flPath & DCPATH_CLOCKWISE) != 0) + AD_COUNTERCLOCKWISE; break; case GdiGetEMFRestorDc: break; @@ -2217,29 +2222,26 @@ Ret = FALSE; break; } - if ( Dc_Attr->dwLayout & LAYOUT_RTL ) + if ( Dc_Attr->dwLayout & LAYOUT_RTL ) // Right to Left { SafeResult = AD_CLOCKWISE - ((dc->DcLevel.flPath & DCPATH_CLOCKWISE) != 0); if ( dwIn == AD_CLOCKWISE ) { - dc->DcLevel.flPath |= DCPATH_CLOCKWISE; + dc->DcLevel.flPath &= ~DCPATH_CLOCKWISE; break; } - dc->DcLevel.flPath &= ~DCPATH_CLOCKWISE; - } - else + dc->DcLevel.flPath |= DCPATH_CLOCKWISE; + } + else // Left to Right { SafeResult = ((dc->DcLevel.flPath & DCPATH_CLOCKWISE) != 0) + AD_COUNTERCLOCKWISE; if ( dwIn == AD_COUNTERCLOCKWISE) { - dc->DcLevel.flPath |= DCPATH_CLOCKWISE; + dc->DcLevel.flPath &= ~DCPATH_CLOCKWISE; break; } - dc->DcLevel.flPath &= ~DCPATH_CLOCKWISE; - } - - SafeResult = dc->w.ArcDirection; // Fixme - dc->w.ArcDirection = dwIn; // Fixme + dc->DcLevel.flPath |= DCPATH_CLOCKWISE; + } break; default: SetLastWin32Error(ERROR_INVALID_PARAMETER); Modified: trunk/reactos/subsystems/win32/win32k/objects/path.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/objects/path.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/objects/path.c [iso-8859-1] Wed Apr 16 22:46:46 2008 @@ -757,7 +757,7 @@ ASSERT ( dc ); - clockwise = ( dc->w.ArcDirection == AD_CLOCKWISE ); + clockwise = ((dc->DcLevel.flPath & DCPATH_CLOCKWISE) != 0); /* Check that path is open */ if ( dc->w.path.state != PATH_Open )
16 years, 8 months
1
0
0
0
[jimtabor] 32994: Revert change to window.c. It is not ready.
by jimtabor@svn.reactos.org
Author: jimtabor Date: Wed Apr 16 20:57:29 2008 New Revision: 32994 URL:
http://svn.reactos.org/svn/reactos?rev=32994&view=rev
Log: Revert change to window.c. It is not ready. Modified: trunk/reactos/subsystems/win32/win32k/ntuser/window.c Modified: trunk/reactos/subsystems/win32/win32k/ntuser/window.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/window.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/window.c [iso-8859-1] Wed Apr 16 20:57:29 2008 @@ -2056,7 +2056,7 @@ IntUnlinkWindow(Window); RETURN((HWND)0); } - +#if 0 Result = co_EVENT_CallEvents(EVENT_OBJECT_CREATE, Window->hSelf, OBJID_WINDOW, 0); if (Result == (LRESULT)-1) @@ -2065,7 +2065,7 @@ DPRINT1("IntCreateWindowEx(): event CREATE hook failed. No cleanup performed!\n"); RETURN((HWND)0); } - +#endif /* Send move and size messages. */ if (!(Window->Flags & WINDOWOBJECT_NEED_SIZE)) {
16 years, 8 months
1
0
0
0
[jimtabor] 32993: Adding support for Event hooks. Start using the server info structure and pass the pointer to the user with kernel to user correction.
by jimtabor@svn.reactos.org
Author: jimtabor Date: Wed Apr 16 20:48:34 2008 New Revision: 32993 URL:
http://svn.reactos.org/svn/reactos?rev=32993&view=rev
Log: Adding support for Event hooks. Start using the server info structure and pass the pointer to the user with kernel to user correction. Added: trunk/reactos/subsystems/win32/win32k/ntuser/event.c - copied, changed from r32946, trunk/reactos/subsystems/win32/win32k/ntuser/hook.c Modified: trunk/reactos/dll/win32/user32/misc/dllmain.c trunk/reactos/dll/win32/user32/windows/hook.c trunk/reactos/include/reactos/win32k/callback.h trunk/reactos/include/reactos/win32k/ntuser.h trunk/reactos/subsystems/win32/win32k/include/callback.h trunk/reactos/subsystems/win32/win32k/include/hook.h trunk/reactos/subsystems/win32/win32k/ntuser/callback.c trunk/reactos/subsystems/win32/win32k/ntuser/hook.c trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c trunk/reactos/subsystems/win32/win32k/ntuser/window.c trunk/reactos/subsystems/win32/win32k/win32k.rbuild Modified: trunk/reactos/dll/win32/user32/misc/dllmain.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/misc/dllm…
============================================================================== --- trunk/reactos/dll/win32/user32/misc/dllmain.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/user32/misc/dllmain.c [iso-8859-1] Wed Apr 16 20:48:34 2008 @@ -8,6 +8,7 @@ PUSER_HANDLE_ENTRY gHandleEntries = NULL; PW32PROCESSINFO g_pi = NULL; /* User Mode Pointer */ PW32PROCESSINFO g_kpi = NULL; /* Kernel Mode Pointer */ +PSERVERINFO g_psi = NULL; PW32PROCESSINFO GetW32ProcessInfo(VOID); @@ -56,9 +57,12 @@ (PVOID)User32SetupDefaultCursors; NtCurrentTeb()->ProcessEnvironmentBlock->KernelCallbackTable[USER32_CALLBACK_HOOKPROC] = (PVOID)User32CallHookProcFromKernel; + NtCurrentTeb()->ProcessEnvironmentBlock->KernelCallbackTable[USER32_CALLBACK_EVENTPROC] = + (PVOID)User32CallEventProcFromKernel; g_pi = GetW32ProcessInfo(); g_kpi = SharedPtrToKernel(g_pi); + g_psi = SharedPtrToUser(g_pi->psi); gHandleTable = SharedPtrToUser(g_pi->UserHandleTable); gHandleEntries = SharedPtrToUser(gHandleTable->handles); Modified: trunk/reactos/dll/win32/user32/windows/hook.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/windows/h…
============================================================================== --- trunk/reactos/dll/win32/user32/windows/hook.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/user32/windows/hook.c [iso-8859-1] Wed Apr 16 20:48:34 2008 @@ -33,8 +33,7 @@ #include <wine/debug.h> WINE_DEFAULT_DEBUG_CHANNEL(user32); - -DWORD Bogus_SrvEventActivity = 0; // Fixme, need to ref to share data. +extern PSERVERINFO g_psi; /* PRIVATE FUNCTIONS *********************************************************/ @@ -263,7 +262,7 @@ // "Servers call NotifyWinEvent to announce the event to the system after the // event has occurred; they must never notify the system of an event before // the event has occurred." msdn on NotifyWinEvent. - if (Bogus_SrvEventActivity & GetMaskFromEvent(event)) // Check to see. + if (g_psi->SrvEventActivity & GetMaskFromEvent(event)) // Check to see. NtUserNotifyWinEvent(event, hwnd, idObject, idChild); } @@ -318,7 +317,7 @@ { if ((PW32THREADINFO)NtCurrentTeb()->Win32ThreadInfo) { - return (Bogus_SrvEventActivity & GetMaskFromEvent(event)) != 0; + return (g_psi->SrvEventActivity & GetMaskFromEvent(event)) != 0; } return FALSE; } @@ -454,3 +453,24 @@ return ZwCallbackReturn(&Result, sizeof(LRESULT), STATUS_SUCCESS); } + +NTSTATUS STDCALL +User32CallEventProcFromKernel(PVOID Arguments, ULONG ArgumentLength) +{ + PEVENTPROC_CALLBACK_ARGUMENTS Common; + + Common = (PEVENTPROC_CALLBACK_ARGUMENTS) Arguments; + + Common->Proc(Common->hook, + Common->event, + Common->hwnd, + Common->idObject, + Common->idChild, + Common->dwEventThread, + Common->dwmsEventTime); + + return ZwCallbackReturn(NULL, 0, STATUS_SUCCESS); +} + + + Modified: trunk/reactos/include/reactos/win32k/callback.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/reactos/win32k/cal…
============================================================================== --- trunk/reactos/include/reactos/win32k/callback.h [iso-8859-1] (original) +++ trunk/reactos/include/reactos/win32k/callback.h [iso-8859-1] Wed Apr 16 20:48:34 2008 @@ -6,7 +6,8 @@ #define USER32_CALLBACK_LOADSYSMENUTEMPLATE (2) #define USER32_CALLBACK_LOADDEFAULTCURSORS (3) #define USER32_CALLBACK_HOOKPROC (4) -#define USER32_CALLBACK_MAXIMUM (4) +#define USER32_CALLBACK_EVENTPROC (5) +#define USER32_CALLBACK_MAXIMUM (5) typedef struct _WINDOWPROC_CALLBACK_ARGUMENTS { @@ -50,6 +51,23 @@ /* WCHAR szClass[] */ } HOOKPROC_CBT_CREATEWND_EXTRA_ARGUMENTS, *PHOOKPROC_CBT_CREATEWND_EXTRA_ARGUMENTS; +typedef VOID (*WINEVENTPROC)(HWINEVENTHOOK,DWORD,HWND,LONG,LONG,DWORD,DWORD); + +typedef struct _EVENTPROC_CALLBACK_ARGUMENTS +{ + HWINEVENTHOOK hook; + DWORD event; + HWND hwnd; + LONG idObject; + LONG idChild; + DWORD dwEventThread; + DWORD dwmsEventTime; + WINEVENTPROC Proc; + BOOLEAN Ansi; + UINT ModuleNameLength; + WCHAR ModuleName[1]; +} EVENTPROC_CALLBACK_ARGUMENTS, *PEVENTPROC_CALLBACK_ARGUMENTS; + NTSTATUS STDCALL User32CallWindowProcFromKernel(PVOID Arguments, ULONG ArgumentLength); NTSTATUS STDCALL @@ -60,5 +78,7 @@ User32SetupDefaultCursors(PVOID Arguments, ULONG ArgumentLength); NTSTATUS STDCALL User32CallHookProcFromKernel(PVOID Arguments, ULONG ArgumentLength); +NTSTATUS STDCALL +User32CallEventProcFromKernel(PVOID Arguments, ULONG ArgumentLength); #endif /* __INCLUDE_USER32_CALLBACK_H */ Modified: trunk/reactos/include/reactos/win32k/ntuser.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/reactos/win32k/ntu…
============================================================================== --- trunk/reactos/include/reactos/win32k/ntuser.h [iso-8859-1] (original) +++ trunk/reactos/include/reactos/win32k/ntuser.h [iso-8859-1] Wed Apr 16 20:48:34 2008 @@ -1679,7 +1679,7 @@ DWORD dwUnknown3, DWORD dwUnknown4); -DWORD +VOID NTAPI NtUserNotifyWinEvent( DWORD Event, @@ -2345,7 +2345,7 @@ NtUserUnhookWindowsHookEx( HHOOK Hook); -DWORD +BOOL NTAPI NtUserUnhookWinEvent( HWINEVENTHOOK hWinEventHook); Modified: trunk/reactos/subsystems/win32/win32k/include/callback.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/callback.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/callback.h [iso-8859-1] Wed Apr 16 20:48:34 2008 @@ -35,6 +35,16 @@ BOOLEAN Ansi, PUNICODE_STRING ModuleName); +LRESULT STDCALL +co_IntCallEventProc(HWINEVENTHOOK hook, + DWORD event, + HWND hwnd, + LONG idObject, + LONG idChild, + DWORD dwEventThread, + DWORD dwmsEventTime, + WINEVENTPROC Proc); + VOID FASTCALL IntCleanupThreadCallbacks(PW32THREAD W32Thread); Modified: trunk/reactos/subsystems/win32/win32k/include/hook.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/hook.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/hook.h [iso-8859-1] Wed Apr 16 20:48:34 2008 @@ -23,7 +23,27 @@ UINT Counts[NB_HOOKS]; /* use counts for each hook chain */ } HOOKTABLE, *PHOOKTABLE; +typedef struct tagEVENTHOOK +{ + LIST_ENTRY Chain; /* Event chain entry */ + HWINEVENTHOOK Self; /* user handle for this event */ + PETHREAD Thread; /* Thread owning the event */ + UINT eventMin; + UINT eventMax; + WINEVENTPROC Proc; /* Event function */ + BOOLEAN Ansi; /* Is it an Ansi event? */ + ULONG Flags; /* Some internal flags */ + UNICODE_STRING ModuleName; /* Module name for global events */ +} EVENTHOOK, *PEVENTHOOK; + +typedef struct tagEVENTTABLE +{ + LIST_ENTRY Events; + UINT Counts; +} EVENTTABLE, *PEVENTTABLE; + LRESULT FASTCALL co_HOOK_CallHooks(INT HookId, INT Code, WPARAM wParam, LPARAM lParam); +LRESULT FASTCALL co_EVENT_CallEvents(DWORD, HWND, LONG, LONG); VOID FASTCALL HOOK_DestroyThreadHooks(PETHREAD Thread); PHOOK FASTCALL IntGetHookObject(HHOOK); Modified: trunk/reactos/subsystems/win32/win32k/ntuser/callback.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/callback.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/callback.c [iso-8859-1] Wed Apr 16 20:48:34 2008 @@ -465,4 +465,69 @@ return Result; } +LRESULT +STDCALL +co_IntCallEventProc(HWINEVENTHOOK hook, + DWORD event, + HWND hWnd, + LONG idObject, + LONG idChild, + DWORD dwEventThread, + DWORD dwmsEventTime, + WINEVENTPROC Proc) +{ + LRESULT Result; + NTSTATUS Status; + PEVENTPROC_CALLBACK_ARGUMENTS Common; + ULONG ArgumentLength, ResultLength; + PVOID Argument, ResultPointer, pWnd; + + ArgumentLength = sizeof(EVENTPROC_CALLBACK_ARGUMENTS); + + Argument = IntCbAllocateMemory(ArgumentLength); + if (NULL == Argument) + { + DPRINT1("EventProc callback failed: out of memory\n"); + return 0; + } + Common = (PEVENTPROC_CALLBACK_ARGUMENTS) Argument; + Common->hook = hook; + Common->event = event; + Common->hwnd = hWnd; + Common->idObject = idObject; + Common->idChild = idChild; + Common->dwEventThread = dwEventThread; + Common->dwmsEventTime = dwmsEventTime; + Common->Proc = Proc; + + ResultPointer = NULL; + ResultLength = sizeof(LRESULT); + + IntSetTebWndCallback (&hWnd, &pWnd); + + UserLeaveCo(); + + Status = KeUserModeCallback(USER32_CALLBACK_EVENTPROC, + Argument, + ArgumentLength, + &ResultPointer, + &ResultLength); + + /* Simulate old behaviour: copy into our local buffer */ + Result = *(LRESULT*)ResultPointer; + + UserEnterCo(); + + IntRestoreTebWndCallback (hWnd, pWnd); + + IntCbFreeMemory(Argument); + + if (!NT_SUCCESS(Status)) + { + return 0; + } + + return Result; +} + /* EOF */ Copied: trunk/reactos/subsystems/win32/win32k/ntuser/event.c (from r32946, trunk/reactos/subsystems/win32/win32k/ntuser/hook.c) URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/hook.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/event.c [iso-8859-1] Wed Apr 16 20:48:34 2008 @@ -1,43 +1,11 @@ -/* - * ReactOS W32 Subsystem - * Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003 ReactOS Team - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - */ -/* - * COPYRIGHT: See COPYING in the top level directory - * PROJECT: ReactOS kernel - * PURPOSE: Window hooks - * FILE: subsys/win32k/ntuser/hook.c - * PROGRAMER: Casper S. Hornstrup (chorns(a)users.sourceforge.net) - * REVISION HISTORY: - * 06-06-2001 CSH Created - * NOTE: Most of this code was adapted from Wine, - * Copyright (C) 2002 Alexandre Julliard - */ #include <w32k.h> #define NDEBUG #include <debug.h> -#define HOOKID_TO_INDEX(HookId) (HookId - WH_MINHOOK) -#define HOOKID_TO_FLAG(HookId) (1 << ((HookId) + 1)) - -static PHOOKTABLE GlobalHooks; -DWORD Bogus_SrvEventActivity = 0; +extern PSERVERINFO gpsi; +//static PEVENTTABLE GlobalEvents; /* PRIVATE FUNCTIONS *********************************************************/ @@ -76,662 +44,50 @@ return Ret; } -/* create a new hook table */ -static PHOOKTABLE -IntAllocHookTable(void) + +static +DWORD +FASTCALL +TimeStamp(VOID) { - PHOOKTABLE Table; - UINT i; + return (DWORD)((ULONGLONG)SharedUserData->TickCountLowDeprecated * SharedUserData->TickCountMultiplier / 16777216); +} - Table = ExAllocatePoolWithTag(PagedPool, sizeof(HOOKTABLE), TAG_HOOK); - if (NULL != Table) - { - for (i = 0; i < NB_HOOKS; i++) - { - InitializeListHead(&Table->Hooks[i]); - Table->Counts[i] = 0; - } - } +/* FUNCTIONS *****************************************************************/ - return Table; +LRESULT +FASTCALL +co_EVENT_CallEvents( DWORD event, + HWND hwnd, + LONG idObject, + LONG idChild) +{ + + PEVENTHOOK peh = UserHeapAlloc(sizeof(EVENTHOOK)); + + if ((gpsi->SrvEventActivity & GetMaskFromEvent(event))) return 0; // No events to run. + + LRESULT Result = co_IntCallEventProc(peh->Self, + event, + hwnd, + idObject, + idChild, + (DWORD)(NtCurrentTeb()->Cid).UniqueThread, + TimeStamp(), + peh->Proc); + return Result; } -PHOOK FASTCALL IntGetHookObject(HHOOK hHook) +VOID +STDCALL +NtUserNotifyWinEvent( + DWORD Event, + HWND hWnd, + LONG idObject, + LONG idChild) { - PHOOK Hook; - - if (!hHook) - { - SetLastWin32Error(ERROR_INVALID_HOOK_HANDLE); - return NULL; - } - - Hook = (PHOOK)UserGetObject(gHandleTable, hHook, otHook); - if (!Hook) - { - SetLastWin32Error(ERROR_INVALID_HOOK_HANDLE); - return NULL; - } - - ASSERT(USER_BODY_TO_HEADER(Hook)->RefCount >= 0); - - USER_BODY_TO_HEADER(Hook)->RefCount++; - - return Hook; -} - - - -/* create a new hook and add it to the specified table */ -static PHOOK -IntAddHook(PETHREAD Thread, int HookId, BOOLEAN Global, PWINSTATION_OBJECT WinStaObj) -{ - PW32THREAD W32Thread; - PHOOK Hook; - PHOOKTABLE Table = Global ? GlobalHooks : MsqGetHooks(((PW32THREAD)Thread->Tcb.Win32Thread)->MessageQueue); - HANDLE Handle; - - if (NULL == Table) - { - Table = IntAllocHookTable(); - if (NULL == Table) - { - return NULL; - } - if (Global) - { - GlobalHooks = Table; - } - else - { - MsqSetHooks(((PW32THREAD)Thread->Tcb.Win32Thread)->MessageQueue, Table); - } - } - - Hook = UserCreateObject(gHandleTable, &Handle, otHook, sizeof(HOOK)); - if (NULL == Hook) - { - return NULL; - } - - Hook->Self = Handle; - Hook->Thread = Thread; - Hook->HookId = HookId; - - W32Thread = ((PW32THREAD)Thread->Tcb.Win32Thread); - ASSERT(W32Thread != NULL); - W32Thread->Hooks |= HOOKID_TO_FLAG(HookId); - if (W32Thread->ThreadInfo != NULL) - W32Thread->ThreadInfo->Hooks = W32Thread->Hooks; - - RtlInitUnicodeString(&Hook->ModuleName, NULL); - - InsertHeadList(&Table->Hooks[HOOKID_TO_INDEX(HookId)], &Hook->Chain); - - return Hook; -} - -/* get the hook table that a given hook belongs to */ -static PHOOKTABLE FASTCALL -IntGetTable(PHOOK Hook) -{ - if (NULL == Hook->Thread || WH_KEYBOARD_LL == Hook->HookId || - WH_MOUSE_LL == Hook->HookId) - { - return GlobalHooks; - } - - return MsqGetHooks(((PW32THREAD)Hook->Thread->Tcb.Win32Thread)->MessageQueue); -} - -/* get the first hook in the chain */ -static PHOOK FASTCALL -IntGetFirstHook(PHOOKTABLE Table, int HookId) -{ - PLIST_ENTRY Elem = Table->Hooks[HOOKID_TO_INDEX(HookId)].Flink; - return Elem == &Table->Hooks[HOOKID_TO_INDEX(HookId)] - ? NULL : CONTAINING_RECORD(Elem, HOOK, Chain); -} - -/* find the first non-deleted hook in the chain */ -static PHOOK FASTCALL -IntGetFirstValidHook(PHOOKTABLE Table, int HookId) -{ - PHOOK Hook; - PLIST_ENTRY Elem; - - Hook = IntGetFirstHook(Table, HookId); - while (NULL != Hook && NULL == Hook->Proc) - { - Elem = Hook->Chain.Flink; - Hook = (Elem == &Table->Hooks[HOOKID_TO_INDEX(HookId)] - ? NULL : CONTAINING_RECORD(Elem, HOOK, Chain)); - } - - return Hook; -} - -/* find the next hook in the chain, skipping the deleted ones */ -static PHOOK FASTCALL -IntGetNextHook(PHOOK Hook) -{ - PHOOKTABLE Table = IntGetTable(Hook); - int HookId = Hook->HookId; - PLIST_ENTRY Elem; - - Elem = Hook->Chain.Flink; - while (Elem != &Table->Hooks[HOOKID_TO_INDEX(HookId)]) - { - Hook = CONTAINING_RECORD(Elem, HOOK, Chain); - if (NULL != Hook->Proc) - { - return Hook; - } - } - - if (NULL != GlobalHooks && Table != GlobalHooks) /* now search through the global table */ - { - return IntGetFirstValidHook(GlobalHooks, HookId); - } - - return NULL; -} - -/* free a hook, removing it from its chain */ -static VOID FASTCALL -IntFreeHook(PHOOKTABLE Table, PHOOK Hook, PWINSTATION_OBJECT WinStaObj) -{ - RemoveEntryList(&Hook->Chain); - RtlFreeUnicodeString(&Hook->ModuleName); - - /* Dereference thread if required */ - if (Hook->Flags & HOOK_THREAD_REFERENCED) - { - ObDereferenceObject(Hook->Thread); - } - - /* Close handle */ - UserDeleteObject(Hook->Self, otHook); -} - -/* remove a hook, freeing it if the chain is not in use */ -static VOID -IntRemoveHook(PHOOK Hook, PWINSTATION_OBJECT WinStaObj, BOOL TableAlreadyLocked) -{ - PW32THREAD W32Thread; - PHOOKTABLE Table = IntGetTable(Hook); - - ASSERT(NULL != Table); - if (NULL == Table) - { - return; - } - - W32Thread = ((PW32THREAD)Hook->Thread->Tcb.Win32Thread); - ASSERT(W32Thread != NULL); - W32Thread->Hooks &= ~HOOKID_TO_FLAG(Hook->HookId); - if (W32Thread->ThreadInfo != NULL) - W32Thread->ThreadInfo->Hooks = W32Thread->Hooks; - - if (0 != Table->Counts[HOOKID_TO_INDEX(Hook->HookId)]) - { - Hook->Proc = NULL; /* chain is in use, just mark it and return */ - } - else - { - IntFreeHook(Table, Hook, WinStaObj); - } -} - -/* release a hook chain, removing deleted hooks if the use count drops to 0 */ -static VOID FASTCALL -IntReleaseHookChain(PHOOKTABLE Table, int HookId, PWINSTATION_OBJECT WinStaObj) -{ - PLIST_ENTRY Elem; - PHOOK HookObj; - - if (NULL == Table) - { - return; - } - - /* use count shouldn't already be 0 */ - ASSERT(0 != Table->Counts[HOOKID_TO_INDEX(HookId)]); - if (0 == Table->Counts[HOOKID_TO_INDEX(HookId)]) - { - return; - } - if (0 == --Table->Counts[HOOKID_TO_INDEX(HookId)]) - { - Elem = Table->Hooks[HOOKID_TO_INDEX(HookId)].Flink; - while (Elem != &Table->Hooks[HOOKID_TO_INDEX(HookId)]) - { - HookObj = CONTAINING_RECORD(Elem, HOOK, Chain); - Elem = Elem->Flink; - if (NULL == HookObj->Proc) - { - IntFreeHook(Table, HookObj, WinStaObj); - } - } - } -} - -static LRESULT FASTCALL -IntCallLowLevelHook(INT HookId, INT Code, WPARAM wParam, LPARAM lParam, PHOOK Hook) -{ - NTSTATUS Status; - ULONG_PTR uResult; - - /* FIXME should get timeout from - * HKEY_CURRENT_USER\Control Panel\Desktop\LowLevelHooksTimeout */ - Status = co_MsqSendMessage(((PW32THREAD)Hook->Thread->Tcb.Win32Thread)->MessageQueue, (HWND) Code, HookId, - wParam, lParam, 5000, TRUE, TRUE, &uResult); - - return NT_SUCCESS(Status) ? uResult : 0; -} - -LRESULT FASTCALL -co_HOOK_CallHooks(INT HookId, INT Code, WPARAM wParam, LPARAM lParam) -{ - PHOOK Hook; - PW32THREAD Win32Thread; - PHOOKTABLE Table; - LRESULT Result; - PWINSTATION_OBJECT WinStaObj; - NTSTATUS Status; - - ASSERT(WH_MINHOOK <= HookId && HookId <= WH_MAXHOOK); - - Win32Thread = PsGetCurrentThreadWin32Thread(); - if (NULL == Win32Thread) - { - Table = NULL; - } - else - { - Table = MsqGetHooks(Win32Thread->MessageQueue); - } - - if (NULL == Table || ! (Hook = IntGetFirstValidHook(Table, HookId))) - { - /* try global table */ - Table = GlobalHooks; - if (NULL == Table || ! (Hook = IntGetFirstValidHook(Table, HookId))) - { - return 0; /* no hook set */ - } - } - - if (Hook->Thread != PsGetCurrentThread() - && (WH_KEYBOARD_LL == HookId || WH_MOUSE_LL == HookId)) - { - DPRINT("Calling hook in owning thread\n"); - return IntCallLowLevelHook(HookId, Code, wParam, lParam, Hook); - } - - if (Hook->Thread != PsGetCurrentThread()) - { - DPRINT1("Calling hooks in other threads not implemented yet"); - return 0; - } - - Table->Counts[HOOKID_TO_INDEX(HookId)]++; - if (Table != GlobalHooks && GlobalHooks != NULL) - { - GlobalHooks->Counts[HOOKID_TO_INDEX(HookId)]++; - } - - Result = co_IntCallHookProc(HookId, Code, wParam, lParam, Hook->Proc, - Hook->Ansi, &Hook->ModuleName); - - Status = IntValidateWindowStationHandle(PsGetCurrentProcess()->Win32WindowStation, - KernelMode, - 0, - &WinStaObj); - - if (! NT_SUCCESS(Status)) - { - DPRINT1("Invalid window station????\n"); - } - else - { - IntReleaseHookChain(MsqGetHooks(PsGetCurrentThreadWin32Thread()->MessageQueue), HookId, WinStaObj); - IntReleaseHookChain(GlobalHooks, HookId, WinStaObj); - ObDereferenceObject(WinStaObj); - } - - return Result; -} - -VOID FASTCALL -HOOK_DestroyThreadHooks(PETHREAD Thread) -{ - int HookId; - PLIST_ENTRY Elem; - PHOOK HookObj; - PWINSTATION_OBJECT WinStaObj; - NTSTATUS Status; - - if (NULL != GlobalHooks) - { - Status = IntValidateWindowStationHandle(PsGetCurrentProcess()->Win32WindowStation, - KernelMode, - 0, - &WinStaObj); - - if (! NT_SUCCESS(Status)) - { - DPRINT1("Invalid window station????\n"); - return; - } - - for (HookId = WH_MINHOOK; HookId <= WH_MAXHOOK; HookId++) - { - /* only low-level keyboard/mouse global hooks can be owned by a thread */ - switch(HookId) - { - case WH_KEYBOARD_LL: - case WH_MOUSE_LL: - Elem = GlobalHooks->Hooks[HOOKID_TO_INDEX(HookId)].Flink; - while (Elem != &GlobalHooks->Hooks[HOOKID_TO_INDEX(HookId)]) - { - HookObj = CONTAINING_RECORD(Elem, HOOK, Chain); - Elem = Elem->Flink; - if (HookObj->Thread == Thread) - { - IntRemoveHook(HookObj, WinStaObj, TRUE); - } - } - break; - } - } - - ObDereferenceObject(WinStaObj); - } -} - -LRESULT -STDCALL -NtUserCallNextHookEx( - HHOOK Hook, - int Code, - WPARAM wParam, - LPARAM lParam) -{ - PHOOK HookObj, NextObj; - PWINSTATION_OBJECT WinStaObj; - NTSTATUS Status; - DECLARE_RETURN(LRESULT); - - DPRINT("Enter NtUserCallNextHookEx\n"); - UserEnterExclusive(); - - Status = IntValidateWindowStationHandle(PsGetCurrentProcess()->Win32WindowStation, - KernelMode, - 0, - &WinStaObj); - - if (! NT_SUCCESS(Status)) - { - SetLastNtError(Status); - RETURN( FALSE); - } - - //Status = UserReferenceObjectByHandle(gHandleTable, Hook, - // otHookProc, (PVOID *) &HookObj); - ObDereferenceObject(WinStaObj); - - // if (! NT_SUCCESS(Status)) - // { - // DPRINT1("Invalid handle passed to NtUserCallNextHookEx\n"); - // SetLastNtError(Status); - // RETURN( 0); - // } - - if (!(HookObj = IntGetHookObject(Hook))) - { - RETURN(0); - } - - ASSERT(Hook == HookObj->Self); - - if (NULL != HookObj->Thread && (HookObj->Thread != PsGetCurrentThread())) - { - DPRINT1("Thread mismatch\n"); - UserDereferenceObject(HookObj); - SetLastWin32Error(ERROR_INVALID_HANDLE); - RETURN( 0); - } - - NextObj = IntGetNextHook(HookObj); - UserDereferenceObject(HookObj); - if (NULL != NextObj) - { - DPRINT1("Calling next hook not implemented\n"); - UNIMPLEMENTED - SetLastWin32Error(ERROR_NOT_SUPPORTED); - RETURN( 0); - } - - RETURN( 0); - -CLEANUP: - DPRINT("Leave NtUserCallNextHookEx, ret=%i\n",_ret_); - UserLeave(); - END_CLEANUP; -} - -HHOOK -STDCALL -NtUserSetWindowsHookAW( - int idHook, - HOOKPROC lpfn, - BOOL Ansi) -{ - UNICODE_STRING USModuleName; - RtlInitUnicodeString(&USModuleName, NULL); - return NtUserSetWindowsHookEx(NULL, &USModuleName, 0, idHook, lpfn, Ansi); -} - -HHOOK -STDCALL -NtUserSetWindowsHookEx( - HINSTANCE Mod, - PUNICODE_STRING UnsafeModuleName, - DWORD ThreadId, - int HookId, - HOOKPROC HookProc, - BOOL Ansi) -{ - PWINSTATION_OBJECT WinStaObj; - BOOLEAN Global; - PETHREAD Thread; - PHOOK Hook; - UNICODE_STRING ModuleName; - NTSTATUS Status; - HHOOK Handle; - DECLARE_RETURN(HHOOK); - - DPRINT("Enter NtUserSetWindowsHookEx\n"); - UserEnterExclusive(); - - if (HookId < WH_MINHOOK || WH_MAXHOOK < HookId || NULL == HookProc) - { - SetLastWin32Error(ERROR_INVALID_PARAMETER); - RETURN( NULL); - } - - if (ThreadId) /* thread-local hook */ - { - if (HookId == WH_JOURNALRECORD || - HookId == WH_JOURNALPLAYBACK || - HookId == WH_KEYBOARD_LL || - HookId == WH_MOUSE_LL || - HookId == WH_SYSMSGFILTER) - { - /* these can only be global */ - SetLastWin32Error(ERROR_INVALID_PARAMETER); - RETURN( NULL); - } - Mod = NULL; - Global = FALSE; - if (! NT_SUCCESS(PsLookupThreadByThreadId((HANDLE) ThreadId, &Thread))) - { - DPRINT1("Invalid thread id 0x%x\n", ThreadId); - SetLastWin32Error(ERROR_INVALID_PARAMETER); - RETURN( NULL); - } - if (Thread->ThreadsProcess != PsGetCurrentProcess()) - { - ObDereferenceObject(Thread); - DPRINT1("Can't specify thread belonging to another process\n"); - SetLastWin32Error(ERROR_INVALID_PARAMETER); - RETURN( NULL); - } - } - else /* system-global hook */ - { - if (HookId == WH_KEYBOARD_LL || HookId == WH_MOUSE_LL) - { - Mod = NULL; - Thread = PsGetCurrentThread(); - Status = ObReferenceObjectByPointer(Thread, - THREAD_ALL_ACCESS, - PsThreadType, - KernelMode); - - if (! NT_SUCCESS(Status)) - { - SetLastNtError(Status); - RETURN( (HANDLE) NULL); - } - } - else if (NULL == Mod) - { - SetLastWin32Error(ERROR_INVALID_PARAMETER); - RETURN( NULL); - } - else - { - Thread = NULL; - } - Global = TRUE; - } - - /* We only (partially) support local WH_CBT hooks and - * WH_KEYBOARD_LL/WH_MOUSE_LL hooks for now */ - if ((WH_CBT != HookId || Global) - && WH_KEYBOARD_LL != HookId && WH_MOUSE_LL != HookId) - { -#if 0 /* Removed to get winEmbed working again */ - UNIMPLEMENTED -#else - DPRINT1("Not implemented: HookId %d Global %s\n", HookId, Global ? "TRUE" : "FALSE"); -#endif - - if (NULL != Thread) - { - ObDereferenceObject(Thread); - } - SetLastWin32Error(ERROR_NOT_SUPPORTED); - RETURN( NULL); - } - - Status = IntValidateWindowStationHandle(PsGetCurrentProcess()->Win32WindowStation, - KernelMode, - 0, - &WinStaObj); - - if (! NT_SUCCESS(Status)) - { - if (NULL != Thread) - { - ObDereferenceObject(Thread); - } - SetLastNtError(Status); - RETURN( (HANDLE) NULL); - } - - Hook = IntAddHook(Thread, HookId, Global, WinStaObj); - if (NULL == Hook) - { - if (NULL != Thread) - { - ObDereferenceObject(Thread); - } - ObDereferenceObject(WinStaObj); - RETURN( NULL); - } - - if (NULL != Thread) - { - Hook->Flags |= HOOK_THREAD_REFERENCED; - } - - if (NULL != Mod) - { - Status = MmCopyFromCaller(&ModuleName, UnsafeModuleName, sizeof(UNICODE_STRING)); - if (! NT_SUCCESS(Status)) - { - UserDereferenceObject(Hook); - IntRemoveHook(Hook, WinStaObj, FALSE); - if (NULL != Thread) - { - ObDereferenceObject(Thread); - } - ObDereferenceObject(WinStaObj); - SetLastNtError(Status); - RETURN( NULL); - } - Hook->ModuleName.Buffer = ExAllocatePoolWithTag(PagedPool, - ModuleName.MaximumLength, - TAG_HOOK); - if (NULL == Hook->ModuleName.Buffer) - { - UserDereferenceObject(Hook); - IntRemoveHook(Hook, WinStaObj, FALSE); - if (NULL != Thread) - { - ObDereferenceObject(Thread); - } - ObDereferenceObject(WinStaObj); - SetLastWin32Error(ERROR_NOT_ENOUGH_MEMORY); - RETURN( NULL); - } - Hook->ModuleName.MaximumLength = ModuleName.MaximumLength; - Status = MmCopyFromCaller(Hook->ModuleName.Buffer, - ModuleName.Buffer, - ModuleName.MaximumLength); - if (! NT_SUCCESS(Status)) - { - ExFreePool(Hook->ModuleName.Buffer); - UserDereferenceObject(Hook); - IntRemoveHook(Hook, WinStaObj, FALSE); - if (NULL != Thread) - { - ObDereferenceObject(Thread); - } - ObDereferenceObject(WinStaObj); - SetLastNtError(Status); - RETURN( NULL); - } - Hook->ModuleName.Length = ModuleName.Length; - } - - Hook->Proc = HookProc; - Hook->Ansi = Ansi; - Handle = Hook->Self; - - UserDereferenceObject(Hook); - ObDereferenceObject(WinStaObj); - - RETURN( Handle); - -CLEANUP: - DPRINT("Leave NtUserSetWindowsHookEx, ret=%i\n",_ret_); - UserLeave(); - END_CLEANUP; + UNIMPLEMENTED } HWINEVENTHOOK @@ -746,70 +102,23 @@ DWORD idThread, UINT dwflags) { + gpsi->SrvEventActivity |= GetMaskFromEvent(eventMin); + gpsi->SrvEventActivity &= ~GetMaskFromEvent(eventMin); - Bogus_SrvEventActivity |= GetMaskFromEvent(eventMin); // Fake it out for now. - Bogus_SrvEventActivity &= ~GetMaskFromEvent(eventMin); UNIMPLEMENTED return 0; } + BOOL -STDCALL -NtUserUnhookWindowsHookEx( - HHOOK Hook) -{ - PWINSTATION_OBJECT WinStaObj; - PHOOK HookObj; - NTSTATUS Status; - DECLARE_RETURN(BOOL); - - DPRINT("Enter NtUserUnhookWindowsHookEx\n"); - UserEnterExclusive(); - - Status = IntValidateWindowStationHandle(PsGetCurrentProcess()->Win32WindowStation, - KernelMode, - 0, - &WinStaObj); - - if (! NT_SUCCESS(Status)) - { - SetLastNtError(Status); - RETURN( FALSE); - } - - // Status = UserReferenceObjectByHandle(gHandleTable, Hook, - // otHookProc, (PVOID *) &HookObj); - if (!(HookObj = IntGetHookObject(Hook))) - { - DPRINT1("Invalid handle passed to NtUserUnhookWindowsHookEx\n"); - ObDereferenceObject(WinStaObj); - // SetLastNtError(Status); - RETURN( FALSE); - } - ASSERT(Hook == HookObj->Self); - - IntRemoveHook(HookObj, WinStaObj, FALSE); - - UserDereferenceObject(HookObj); - ObDereferenceObject(WinStaObj); - - RETURN( TRUE); - -CLEANUP: - DPRINT("Leave NtUserUnhookWindowsHookEx, ret=%i\n",_ret_); - UserLeave(); - END_CLEANUP; -} - -DWORD STDCALL NtUserUnhookWinEvent( HWINEVENTHOOK hWinEventHook) { UNIMPLEMENTED - return 0; + return FALSE; } /* EOF */ Modified: trunk/reactos/subsystems/win32/win32k/ntuser/hook.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/hook.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/hook.c [iso-8859-1] Wed Apr 16 20:48:34 2008 @@ -1,26 +1,8 @@ -/* - * ReactOS W32 Subsystem - * Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003 ReactOS Team - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - */ /* * COPYRIGHT: See COPYING in the top level directory * PROJECT: ReactOS kernel * PURPOSE: Window hooks - * FILE: subsys/win32k/ntuser/hook.c + * FILE: subsystem/win32/win32k/ntuser/hook.c * PROGRAMER: Casper S. Hornstrup (chorns(a)users.sourceforge.net) * REVISION HISTORY: * 06-06-2001 CSH Created @@ -37,44 +19,10 @@ #define HOOKID_TO_FLAG(HookId) (1 << ((HookId) + 1)) static PHOOKTABLE GlobalHooks; -DWORD Bogus_SrvEventActivity = 0; /* PRIVATE FUNCTIONS *********************************************************/ -static -DWORD -FASTCALL -GetMaskFromEvent(DWORD Event) -{ - DWORD Ret = 0; - - if ( Event > EVENT_OBJECT_STATECHANGE ) - { - if ( Event == EVENT_OBJECT_LOCATIONCHANGE ) return SRV_EVENT_LOCATIONCHANGE; - if ( Event == EVENT_OBJECT_NAMECHANGE ) return SRV_EVENT_NAMECHANGE; - if ( Event == EVENT_OBJECT_VALUECHANGE ) return SRV_EVENT_VALUECHANGE; - return SRV_EVENT_CREATE; - } - - if ( Event == EVENT_OBJECT_STATECHANGE ) return SRV_EVENT_STATECHANGE; - - Ret = SRV_EVENT_RUNNING; - - if ( Event < EVENT_SYSTEM_MENUSTART ) return SRV_EVENT_CREATE; - - if ( Event <= EVENT_SYSTEM_MENUPOPUPEND ) - { - Ret = SRV_EVENT_MENU; - } - else - { - if ( Event <= EVENT_CONSOLE_CARET-1 ) return SRV_EVENT_CREATE; - if ( Event <= EVENT_CONSOLE_END_APPLICATION ) return SRV_EVENT_END_APPLICATION; - if ( Event != EVENT_OBJECT_FOCUS ) return SRV_EVENT_CREATE; - } - return Ret; -} /* create a new hook table */ static PHOOKTABLE @@ -734,25 +682,6 @@ END_CLEANUP; } -HWINEVENTHOOK -STDCALL -NtUserSetWinEventHook( - UINT eventMin, - UINT eventMax, - HMODULE hmodWinEventProc, - PUNICODE_STRING puString, - WINEVENTPROC lpfnWinEventProc, - DWORD idProcess, - DWORD idThread, - UINT dwflags) -{ - - Bogus_SrvEventActivity |= GetMaskFromEvent(eventMin); // Fake it out for now. - Bogus_SrvEventActivity &= ~GetMaskFromEvent(eventMin); - UNIMPLEMENTED - - return 0; -} BOOL STDCALL @@ -801,15 +730,5 @@ UserLeave(); END_CLEANUP; } - -DWORD -STDCALL -NtUserUnhookWinEvent( - HWINEVENTHOOK hWinEventHook) -{ - UNIMPLEMENTED - - return 0; -} - + /* EOF */ Modified: trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c [iso-8859-1] Wed Apr 16 20:48:34 2008 @@ -428,19 +428,6 @@ DWORD STDCALL -NtUserNotifyWinEvent( - DWORD Event, - HWND hWnd, - LONG idObject, - LONG idChild) -{ - UNIMPLEMENTED - - return 0; -} - -DWORD -STDCALL NtUserQueryUserCounters( DWORD Unknown0, DWORD Unknown1, Modified: trunk/reactos/subsystems/win32/win32k/ntuser/window.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/window.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/window.c [iso-8859-1] Wed Apr 16 20:48:34 2008 @@ -2056,7 +2056,7 @@ IntUnlinkWindow(Window); RETURN((HWND)0); } -#if 0 + Result = co_EVENT_CallEvents(EVENT_OBJECT_CREATE, Window->hSelf, OBJID_WINDOW, 0); if (Result == (LRESULT)-1) @@ -2065,7 +2065,7 @@ DPRINT1("IntCreateWindowEx(): event CREATE hook failed. No cleanup performed!\n"); RETURN((HWND)0); } -#endif + /* Send move and size messages. */ if (!(Window->Flags & WINDOWOBJECT_NEED_SIZE)) { Modified: trunk/reactos/subsystems/win32/win32k/win32k.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/wi…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/win32k.rbuild [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/win32k.rbuild [iso-8859-1] Wed Apr 16 20:48:34 2008 @@ -112,6 +112,7 @@ <file>csr.c</file> <file>cursoricon.c</file> <file>desktop.c</file> + <file>event.c</file> <file>focus.c</file> <file>guicheck.c</file> <file>hook.c</file>
16 years, 8 months
1
0
0
0
[jimtabor] 32992: Fix copy count and added dc path flags and support new arc direction.
by jimtabor@svn.reactos.org
Author: jimtabor Date: Wed Apr 16 20:12:58 2008 New Revision: 32992 URL:
http://svn.reactos.org/svn/reactos?rev=32992&view=rev
Log: Fix copy count and added dc path flags and support new arc direction. Modified: trunk/reactos/subsystems/win32/win32k/include/dc.h trunk/reactos/subsystems/win32/win32k/objects/dc.c Modified: trunk/reactos/subsystems/win32/win32k/include/dc.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/dc.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/dc.h [iso-8859-1] Wed Apr 16 20:12:58 2008 @@ -8,6 +8,11 @@ // Get/SetBounds/Rect support. #define DCB_WINDOWMGR 0x8000 // Queries the Windows bounding rectangle instead of the application's + + /* DCPATH flPath */ +#define DCPATH_ACTIVE 0x0001 +#define DCPATH_SAVE 0x0002 +#define DCPATH_CLOCKWISE 0x0004 /* DC flags */ #define DC_SAVED 0x0002 /* It is a saved DC */ Modified: trunk/reactos/subsystems/win32/win32k/objects/dc.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/ob…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/objects/dc.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/objects/dc.c [iso-8859-1] Wed Apr 16 20:12:58 2008 @@ -2187,6 +2187,8 @@ switch (u) { case GdtGetSetCopyCount: + SafeResult = dc->ulCopyCount; + dc->ulCopyCount = dwIn; break; case GdiGetSetTextAlign: SafeResult = Dc_Attr->lTextAlign; @@ -2213,9 +2215,31 @@ { SetLastWin32Error(ERROR_INVALID_PARAMETER); Ret = FALSE; - } - SafeResult = dc->w.ArcDirection; - dc->w.ArcDirection = dwIn; + break; + } + if ( Dc_Attr->dwLayout & LAYOUT_RTL ) + { + SafeResult = AD_CLOCKWISE - ((dc->DcLevel.flPath & DCPATH_CLOCKWISE) != 0); + if ( dwIn == AD_CLOCKWISE ) + { + dc->DcLevel.flPath |= DCPATH_CLOCKWISE; + break; + } + dc->DcLevel.flPath &= ~DCPATH_CLOCKWISE; + } + else + { + SafeResult = ((dc->DcLevel.flPath & DCPATH_CLOCKWISE) != 0) + AD_COUNTERCLOCKWISE; + if ( dwIn == AD_COUNTERCLOCKWISE) + { + dc->DcLevel.flPath |= DCPATH_CLOCKWISE; + break; + } + dc->DcLevel.flPath &= ~DCPATH_CLOCKWISE; + } + + SafeResult = dc->w.ArcDirection; // Fixme + dc->w.ArcDirection = dwIn; // Fixme break; default: SetLastWin32Error(ERROR_INVALID_PARAMETER);
16 years, 8 months
1
0
0
0
[tkreuzer] 32991: - fix build - remobe RegisterThreadAcceleratorTable prototype (function doesn't exist)
by tkreuzer@svn.reactos.org
Author: tkreuzer Date: Wed Apr 16 16:55:47 2008 New Revision: 32991 URL:
http://svn.reactos.org/svn/reactos?rev=32991&view=rev
Log: - fix build - remobe RegisterThreadAcceleratorTable prototype (function doesn't exist) Modified: trunk/reactos/subsystems/win32/win32k/include/accelerator.h trunk/reactos/subsystems/win32/win32k/include/bitmaps.h trunk/reactos/subsystems/win32/win32k/include/dc.h trunk/reactos/subsystems/win32/win32k/include/gdiobj.h Modified: trunk/reactos/subsystems/win32/win32k/include/accelerator.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/accelerator.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/accelerator.h [iso-8859-1] Wed Apr 16 16:55:47 2008 @@ -17,8 +17,6 @@ NTSTATUS FASTCALL CleanupAcceleratorImpl(); -VOID -RegisterThreadAcceleratorTable(struct _ETHREAD *Thread); PACCELERATOR_TABLE FASTCALL UserGetAccelObject(HACCEL); #endif /* _WIN32K_ACCELERATOR_H */ Modified: trunk/reactos/subsystems/win32/win32k/include/bitmaps.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/bitmaps.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/bitmaps.h [iso-8859-1] Wed Apr 16 16:55:47 2008 @@ -2,8 +2,8 @@ #ifndef __WIN32K_BITMAPS_H #define __WIN32K_BITMAPS_H -#include <include/win32.h> -#include <include/gdiobj.h> +#include "win32.h" +#include "gdiobj.h" /* GDI logical bitmap object */ typedef struct _BITMAPOBJ Modified: trunk/reactos/subsystems/win32/win32k/include/dc.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/dc.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/dc.h [iso-8859-1] Wed Apr 16 16:55:47 2008 @@ -1,8 +1,8 @@ #ifndef __WIN32K_DC_H #define __WIN32K_DC_H -#include <include/brush.h> -#include <include/bitmaps.h> +#include "brush.h" +#include "bitmaps.h" /* Constants ******************************************************************/ Modified: trunk/reactos/subsystems/win32/win32k/include/gdiobj.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/gdiobj.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/gdiobj.h [iso-8859-1] Wed Apr 16 16:55:47 2008 @@ -8,7 +8,7 @@ /* Public GDI Object/Handle definitions */ #include <win32k/ntgdihdl.h> -#include <include/win32.h> +#include "win32.h" typedef struct _GDI_HANDLE_TABLE {
16 years, 8 months
1
0
0
0
[pschweitzer] 32990: Fixed typo spotted by Sylvain
by pschweitzer@svn.reactos.org
Author: pschweitzer Date: Wed Apr 16 16:36:35 2008 New Revision: 32990 URL:
http://svn.reactos.org/svn/reactos?rev=32990&view=rev
Log: Fixed typo spotted by Sylvain Modified: trunk/reactos/base/applications/dxdiag/lang/fr-FR.rc Modified: trunk/reactos/base/applications/dxdiag/lang/fr-FR.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/dxdiag/l…
============================================================================== --- trunk/reactos/base/applications/dxdiag/lang/fr-FR.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/dxdiag/lang/fr-FR.rc [iso-8859-1] Wed Apr 16 16:36:35 2008 @@ -4,7 +4,7 @@ STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU | WS_THICKFRAME -CAPTION "ReactX - Programme de diagnostique" +CAPTION "ReactX - Programme de diagnostic" FONT 8, "MS Shell Dlg" BEGIN CONTROL "Tab1",IDC_TAB_CONTROL,"SysTabControl32",WS_TABSTOP,2,2,374,195 @@ -60,7 +60,7 @@ STRINGTABLE DISCARDABLE BEGIN - IDS_MAIN_DIALOG "Outil de diagnostique ReactX" + IDS_MAIN_DIALOG "Outil de diagnostic ReactX" IDS_SYSTEM_DIALOG "Système" IDS_DISPLAY_DIALOG "Affichage" IDS_SOUND_DIALOG "Son"
16 years, 8 months
1
0
0
0
[tkreuzer] 32989: win32k header cleanup/update: - make the headers include headers they depend on, so the inclusion order is irrelevant, not finished - start sorting them alphabetically - remove duplicate include of timer.h - add cliprgn.h - add DCLEVEL struct and make DC struct windows xp compatible (currently + some ros specific entries)
by tkreuzer@svn.reactos.org
Author: tkreuzer Date: Wed Apr 16 16:34:12 2008 New Revision: 32989 URL:
http://svn.reactos.org/svn/reactos?rev=32989&view=rev
Log: win32k header cleanup/update: - make the headers include headers they depend on, so the inclusion order is irrelevant, not finished - start sorting them alphabetically - remove duplicate include of timer.h - add cliprgn.h - add DCLEVEL struct and make DC struct windows xp compatible (currently + some ros specific entries) Added: trunk/reactos/subsystems/win32/win32k/include/cliprgn.h (with props) Modified: trunk/reactos/subsystems/win32/win32k/include/accelerator.h trunk/reactos/subsystems/win32/win32k/include/bitmaps.h trunk/reactos/subsystems/win32/win32k/include/callback.h trunk/reactos/subsystems/win32/win32k/include/caret.h trunk/reactos/subsystems/win32/win32k/include/class.h trunk/reactos/subsystems/win32/win32k/include/clipboard.h trunk/reactos/subsystems/win32/win32k/include/coord.h trunk/reactos/subsystems/win32/win32k/include/dc.h trunk/reactos/subsystems/win32/win32k/include/gdiobj.h trunk/reactos/subsystems/win32/win32k/include/intgdi.h trunk/reactos/subsystems/win32/win32k/include/palette.h trunk/reactos/subsystems/win32/win32k/include/region.h trunk/reactos/subsystems/win32/win32k/include/win32k.h Modified: trunk/reactos/subsystems/win32/win32k/include/accelerator.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/accelerator.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/accelerator.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -1,6 +1,7 @@ #ifndef _WIN32K_ACCELERATOR_H #define _WIN32K_ACCELERATOR_H +#include <include/win32.h> #include <include/winsta.h> #include <include/window.h> Modified: trunk/reactos/subsystems/win32/win32k/include/bitmaps.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/bitmaps.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/bitmaps.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -1,6 +1,9 @@ #ifndef __WIN32K_BITMAPS_H #define __WIN32K_BITMAPS_H + +#include <include/win32.h> +#include <include/gdiobj.h> /* GDI logical bitmap object */ typedef struct _BITMAPOBJ Modified: trunk/reactos/subsystems/win32/win32k/include/callback.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/callback.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/callback.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -1,5 +1,7 @@ #ifndef _WIN32K_CALLBACK_H #define _WIN32K_CALLBACK_H + +#include <include/win32.h> LRESULT STDCALL co_IntCallWindowProc(WNDPROC Proc, Modified: trunk/reactos/subsystems/win32/win32k/include/caret.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/caret.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/caret.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -1,5 +1,8 @@ #ifndef _WIN32K_CARET_H #define _WIN32K_CARET_H + +#include <include/win32.h> +#include <include/window.h> #define IDCARETTIMER (0xffff) Modified: trunk/reactos/subsystems/win32/win32k/include/class.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/class.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/class.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -1,5 +1,7 @@ #ifndef _WIN32K_CLASS_H #define _WIN32K_CLASS_H + +#include <include/win32.h> #define IS_ATOM(x) \ (((ULONG_PTR)(x) > 0x0) && ((ULONG_PTR)(x) < 0x10000)) Modified: trunk/reactos/subsystems/win32/win32k/include/clipboard.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/clipboard.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/clipboard.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -2,6 +2,7 @@ #define _WIN32K_CLIPBOARD_H #include "window.h" +#include <include/win32.h> VOID FASTCALL IntIncrementSequenceNumber(VOID); Added: trunk/reactos/subsystems/win32/win32k/include/cliprgn.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/cliprgn.h (added) +++ trunk/reactos/subsystems/win32/win32k/include/cliprgn.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -1,0 +1,12 @@ +#ifndef __WIN32K_CLIPRGN_H +#define __WIN32K_CLIPRGN_H + +#include <include/dc.h> +#include <include/region.h> + +INT FASTCALL IntGdiGetClipBox(HDC hDC, LPRECT rc); +INT STDCALL IntGdiSelectVisRgn(HDC hdc, HRGN hrgn); +INT STDCALL IntGdiExtSelectClipRgn (PDC dc, HRGN hrgn, int fnMode); + + +#endif /* not __WIN32K_CLIPRGN_H */ Propchange: trunk/reactos/subsystems/win32/win32k/include/cliprgn.h ------------------------------------------------------------------------------ svn:eol-style = native Modified: trunk/reactos/subsystems/win32/win32k/include/coord.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/coord.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/coord.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -1,5 +1,7 @@ #ifndef __WIN32K_COORD_H #define __WIN32K_COORD_H + +#include <include/dc.h> VOID FASTCALL Modified: trunk/reactos/subsystems/win32/win32k/include/dc.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/dc.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/dc.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -1,7 +1,8 @@ #ifndef __WIN32K_DC_H #define __WIN32K_DC_H -#include "driver.h" +#include <include/brush.h> +#include <include/bitmaps.h> /* Constants ******************************************************************/ @@ -32,6 +33,45 @@ /* Type definitions ***********************************************************/ +typedef struct _DCLEVEL +{ + HPALETTE hpal; + struct _PALGDI * ppal; + PVOID pColorSpace; // COLORSPACE* + LONG lIcmMode; + LONG lSaveDepth; + DWORD unk1_00000000; + HGDIOBJ hdcSave; + POINTL ptlBrushOrigin; + PGDIBRUSHOBJ pbrFill; + PGDIBRUSHOBJ pbrLine; + PVOID plfnt; // LFONTOBJ* (TEXTOBJ*) + HGDIOBJ hPath; // HPATH + FLONG flPath; + LINEATTRS laPath; // 0x20 bytes + PVOID prgnClip; // PROSRGNDATA + PVOID prgnMeta; + COLORADJUSTMENT ca; + FLONG flFontState; + UNIVERSAL_FONT_ID ufi; + DWORD unk4_00000000[11]; + FLONG fl; + FLONG flBrush; + MATRIX_S mxWorldToDevice; + MATRIX_S mxDeviceToWorld; + MATRIX_S mxWorldToPage; + EFLOAT_S efM11PtoD; + EFLOAT_S efM22PtoD; + EFLOAT_S efDxPtoD; + EFLOAT_S efDyPtoD; + EFLOAT_S efM11_TWIPS; + EFLOAT_S efM22_TWIPS; + EFLOAT_S efPr11; + EFLOAT_S efPr22; + PBITMAPOBJ pSurface; // SURFACE* + SIZE sizl; +} DCLEVEL, PDCLEVEL; + /* The DC object structure */ typedef struct _DC { @@ -47,16 +87,39 @@ FLONG flGraphics; FLONG flGraphics2; PDC_ATTR pDc_Attr; - WIN_DC_INFO w; + DCLEVEL DcLevel; DC_ATTR Dc_Attr; HDC hNext; HDC hPrev; RECTL erclClip; + POINTL ptlSaveFillOrig; RECTL erclWindow; RECTL erclBounds; - HRGN hprgnAPI; - HRGN hprgnVis; - + RECTL erclBoundsApp; + PVOID prgnAPI; // PROSRGNDATA + PVOID prgnVis; + PVOID prgnRao; + POINTL ptlFillOrigin; + unsigned eboFill_[23]; // EBRUSHOBJ + unsigned eboLine_[23]; + unsigned eboText_[23]; + unsigned eboBackground_[23]; + HFONT hlfntCur; + FLONG flSimulationFlags; + LONG lEscapement; + PVOID prfnt; // RFONT* + unsigned co_[31]; // CLIPOBJ + PVOID pPFFList; // PPFF* + PVOID ClrxFormObj; + INT ipfdDevMax; + ULONG ulCopyCount; + PVOID pSurfInfo; + POINTL ptlDoBanding; + + /* Reactos specific members */ + WIN_DC_INFO w; + HRGN hprgnAPI; // should use prgnAPI + HRGN hprgnVis; // should use prgnVis CLIPOBJ *CombinedClip; XLATEOBJ *XlateBrush; XLATEOBJ *XlatePen; Modified: trunk/reactos/subsystems/win32/win32k/include/gdiobj.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/gdiobj.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/gdiobj.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -8,6 +8,7 @@ /* Public GDI Object/Handle definitions */ #include <win32k/ntgdihdl.h> +#include <include/win32.h> typedef struct _GDI_HANDLE_TABLE { Modified: trunk/reactos/subsystems/win32/win32k/include/intgdi.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/intgdi.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/intgdi.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -193,8 +193,6 @@ INT FASTCALL IntGdiGetDeviceCaps(PDC dc, INT Index); -int STDCALL IntGdiExtSelectClipRgn (PDC dc, HRGN hrgn, int fnMode); - INT FASTCALL IntGdiEscape(PDC dc, Modified: trunk/reactos/subsystems/win32/win32k/include/palette.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/palette.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/palette.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -1,5 +1,7 @@ #ifndef _WIN32K_PALETTE_H #define _WIN32K_PALETTE_H + +#include <include/dc.h> #define NO_MAPPING Modified: trunk/reactos/subsystems/win32/win32k/include/region.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/region.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/region.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -37,9 +37,6 @@ INT STDCALL IntGdiGetRgnBox(HRGN, LPRECT); BOOL FASTCALL IntGdiPaintRgn(PDC, HRGN ); HRGN FASTCALL GdiCreatePolyPolygonRgn(CONST PPOINT, CONST PINT, INT, INT ); -int FASTCALL IntGdiGetClipBox(HDC hDC, LPRECT rc); -INT STDCALL IntGdiSelectVisRgn(HDC hdc, HRGN hrgn); - #define UnsafeIntCreateRectRgnIndirect(prc) \ NtGdiCreateRectRgn((prc)->left, (prc)->top, (prc)->right, (prc)->bottom) Modified: trunk/reactos/subsystems/win32/win32k/include/win32k.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/win32k.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/win32k.h [iso-8859-1] Wed Apr 16 16:34:12 2008 @@ -12,21 +12,36 @@ #define INTERNAL_CALL NTAPI /* Internal Win32k Headers */ -#include <include/ntuser.h> -#include <include/win32.h> +#include <include/driver.h> + #include <include/accelerator.h> +#include <include/clipboard.h> +#include <include/cliprgn.h> +#include <include/bitmaps.h> +#include <include/brush.h> #include <include/callback.h> +#include <include/caret.h> #include <include/class.h> #include <include/cleanup.h> -#include <include/clipboard.h> #include <include/color.h> +#include <include/coord.h> #include <include/csr.h> +#include <include/dc.h> +#include <include/dce.h> +#include <include/dib.h> +#include <include/error.h> +#include <include/gdiobj.h> +#include <include/palette.h> +#include <include/rect.h> +#include <include/win32.h> +#include <include/window.h> +#include <include/winsta.h> + +#include <include/region.h> +#include <include/ntuser.h> #include <include/cursoricon.h> -#include <include/dce.h> #include <include/desktop.h> -#include <include/dib.h> #include <include/eng.h> -#include <include/error.h> #include <include/focus.h> #include <include/guicheck.h> #include <include/hook.h> @@ -42,26 +57,19 @@ #include <include/object.h> #include <include/paint.h> #include <include/painting.h> -#include <include/palette.h> #include <include/path.h> #include <include/prop.h> -#include <include/rect.h> #include <include/scroll.h> #include <include/surface.h> #include <include/tags.h> #include <include/text.h> #include <include/timer.h> -#include <include/timer.h> #include <include/useratom.h> #include <include/vis.h> -#include <include/window.h> -#include <include/caret.h> #include <include/userfuncs.h> #include <include/winpos.h> -#include <include/winsta.h> #include <include/mmcopy.h> #include <include/misc.h> -#include <include/coord.h> #include <include/gdifloat.h> #include <eng/objects.h> #include <eng/misc.h>
16 years, 8 months
1
0
0
0
[dchapyshev] 32988: - Add Russian translation
by dchapyshev@svn.reactos.org
Author: dchapyshev Date: Wed Apr 16 14:59:54 2008 New Revision: 32988 URL:
http://svn.reactos.org/svn/reactos?rev=32988&view=rev
Log: - Add Russian translation Added: trunk/reactos/base/applications/dxdiag/lang/ru-RU.rc (with props) Modified: trunk/reactos/base/applications/dxdiag/rsrc.rc Added: trunk/reactos/base/applications/dxdiag/lang/ru-RU.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/dxdiag/l…
============================================================================== --- trunk/reactos/base/applications/dxdiag/lang/ru-RU.rc (added) +++ trunk/reactos/base/applications/dxdiag/lang/ru-RU.rc [iso-8859-1] Wed Apr 16 14:59:54 2008 @@ -1,0 +1,71 @@ +LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT + +IDD_MAIN_DIALOG DIALOGEX DISCARDABLE 0, 0, 378, 220 +STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | + WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU | + WS_THICKFRAME +CAPTION "Ñðåäñòâî äèàãíîñòèêè ReactX" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL "Tab1",IDC_TAB_CONTROL,"SysTabControl32",WS_TABSTOP,2,2,374,195 + PUSHBUTTON "&Ñïðàâêà", IDC_BUTTON_HELP, 2, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + DEFPUSHBUTTON "&Ñëåäóþùàÿ ñòðàíèöà", IDC_BUTTON_NEXT, 137, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "Ñ&îõðàíèòü âñþ èíôîðìàöèþ...", IDC_BUTTON_SAVE_INFO, 201, 201, 110, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "&Âûõîä", IDC_BUTTON_EXIT, 323, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP +END + +IDD_SYSTEM_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + +IDD_DISPLAY_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + + +IDD_SOUND_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + +IDD_MUSIC_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + + +IDD_INPUT_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + +IDD_NETWORK_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + +IDD_HELP_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_MAIN_DIALOG "Ñðåäñòâî äèàãíîñòèêè ReactX" + IDS_SYSTEM_DIALOG "Ñèñòåìà" + IDS_DISPLAY_DIALOG "Ýêðàí" + IDS_SOUND_DIALOG "Çâóê" + IDS_MUSIC_DIALOG "Ìóçûêà" + IDS_INPUT_DIALOG "Ââîä" + IDS_NETWORK_DIALOG "Ñåòü" + IDS_HELP_DIALOG "Ñïðàâêà" +END Propchange: trunk/reactos/base/applications/dxdiag/lang/ru-RU.rc ------------------------------------------------------------------------------ svn:eol-style = native Modified: trunk/reactos/base/applications/dxdiag/rsrc.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/dxdiag/r…
============================================================================== --- trunk/reactos/base/applications/dxdiag/rsrc.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/dxdiag/rsrc.rc [iso-8859-1] Wed Apr 16 14:59:54 2008 @@ -7,3 +7,4 @@ #include "lang/de-DE.rc" #include "lang/en-US.rc" #include "lang/fr-FR.rc" +#include "lang/ru-RU.rc"
16 years, 8 months
1
0
0
0
[pschweitzer] 32987: Removed a breakpoint in Ext2CommonClose() (after an *intensive* discussion with Filip...). That way ext2 FSD won't crash any more at startup.
by pschweitzer@svn.reactos.org
Author: pschweitzer Date: Wed Apr 16 12:51:27 2008 New Revision: 32987 URL:
http://svn.reactos.org/svn/reactos?rev=32987&view=rev
Log: Removed a breakpoint in Ext2CommonClose() (after an *intensive* discussion with Filip...). That way ext2 FSD won't crash any more at startup. Modified: trunk/reactos/drivers/filesystems/ext2/src/close.c Modified: trunk/reactos/drivers/filesystems/ext2/src/close.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/ext2/s…
============================================================================== --- trunk/reactos/drivers/filesystems/ext2/src/close.c [iso-8859-1] (original) +++ trunk/reactos/drivers/filesystems/ext2/src/close.c [iso-8859-1] Wed Apr 16 12:51:27 2008 @@ -144,7 +144,6 @@ { DebugTrace( DEBUG_TRACE_SPECIAL, "###### File Pointer 0x%LX [Close]", PtrFileObject); } - Ext2BreakPoint(); try_return( RC ); }
16 years, 8 months
1
0
0
0
[pschweitzer] 32986: - Fixed a string in English translation - Added French translation (that doesn't do anything yet :)) for dxdiag.exe
by pschweitzer@svn.reactos.org
Author: pschweitzer Date: Wed Apr 16 12:47:09 2008 New Revision: 32986 URL:
http://svn.reactos.org/svn/reactos?rev=32986&view=rev
Log: - Fixed a string in English translation - Added French translation (that doesn't do anything yet :)) for dxdiag.exe Added: trunk/reactos/base/applications/dxdiag/lang/fr-FR.rc (with props) Modified: trunk/reactos/base/applications/dxdiag/lang/en-US.rc trunk/reactos/base/applications/dxdiag/rsrc.rc Modified: trunk/reactos/base/applications/dxdiag/lang/en-US.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/dxdiag/l…
============================================================================== --- trunk/reactos/base/applications/dxdiag/lang/en-US.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/dxdiag/lang/en-US.rc [iso-8859-1] Wed Apr 16 12:47:09 2008 @@ -4,7 +4,7 @@ STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU | WS_THICKFRAME -CAPTION "ReactX-Diagnoseprogramm" +CAPTION "ReactX-Diagnostic program" FONT 8, "MS Shell Dlg" BEGIN CONTROL "Tab1",IDC_TAB_CONTROL,"SysTabControl32",WS_TABSTOP,2,2,374,195 Added: trunk/reactos/base/applications/dxdiag/lang/fr-FR.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/dxdiag/l…
============================================================================== --- trunk/reactos/base/applications/dxdiag/lang/fr-FR.rc (added) +++ trunk/reactos/base/applications/dxdiag/lang/fr-FR.rc [iso-8859-1] Wed Apr 16 12:47:09 2008 @@ -1,0 +1,71 @@ +LANGUAGE LANG_FRENCH, SUBLANG_NEUTRAL + +IDD_MAIN_DIALOG DIALOGEX DISCARDABLE 0, 0, 378, 220 +STYLE DS_SHELLFONT | DS_CENTER | WS_MINIMIZEBOX | WS_POPUP | + WS_CLIPSIBLINGS | WS_CLIPCHILDREN | WS_CAPTION | WS_SYSMENU | + WS_THICKFRAME +CAPTION "ReactX - Programme de diagnostique" +FONT 8, "MS Shell Dlg" +BEGIN + CONTROL "Tab1",IDC_TAB_CONTROL,"SysTabControl32",WS_TABSTOP,2,2,374,195 + PUSHBUTTON "Aide", IDC_BUTTON_HELP, 2, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + DEFPUSHBUTTON "Page suiva&nte", IDC_BUTTON_NEXT, 137, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "Enregi&strer toutes les informations...", IDC_BUTTON_SAVE_INFO, 201, 201, 110, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP + PUSHBUTTON "Quitt&er", IDC_BUTTON_EXIT, 323, 201, 50, 14, WS_CHILD | WS_VISIBLE | WS_TABSTOP +END + +IDD_SYSTEM_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + +IDD_DISPLAY_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + + +IDD_SOUND_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + +IDD_MUSIC_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + + +IDD_INPUT_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + +IDD_NETWORK_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + +IDD_HELP_DIALOG DIALOGEX DISCARDABLE 0, 0, 362, 175 +STYLE DS_SHELLFONT | DS_CONTROL | WS_CHILD | WS_CLIPCHILDREN +FONT 8, "MS Shell Dlg" +BEGIN +END + +STRINGTABLE DISCARDABLE +BEGIN + IDS_MAIN_DIALOG "Outil de diagnostique ReactX" + IDS_SYSTEM_DIALOG "Système" + IDS_DISPLAY_DIALOG "Affichage" + IDS_SOUND_DIALOG "Son" + IDS_MUSIC_DIALOG "Musique" + IDS_INPUT_DIALOG "Entrée" + IDS_NETWORK_DIALOG "Réseau" + IDS_HELP_DIALOG "Aide" +END Propchange: trunk/reactos/base/applications/dxdiag/lang/fr-FR.rc ------------------------------------------------------------------------------ svn:eol-style = native Modified: trunk/reactos/base/applications/dxdiag/rsrc.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/dxdiag/r…
============================================================================== --- trunk/reactos/base/applications/dxdiag/rsrc.rc [iso-8859-1] (original) +++ trunk/reactos/base/applications/dxdiag/rsrc.rc [iso-8859-1] Wed Apr 16 12:47:09 2008 @@ -6,3 +6,4 @@ #include "lang/de-DE.rc" #include "lang/en-US.rc" +#include "lang/fr-FR.rc"
16 years, 8 months
1
0
0
0
← Newer
1
...
18
19
20
21
22
23
24
...
40
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
Results per page:
10
25
50
100
200