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
March 2011
----- 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
276 discussions
Start a n
N
ew thread
[cwittich] 51096: [msi] -partial sync to wine 1.3.16
by cwittich@svn.reactos.org
Author: cwittich Date: Sun Mar 20 08:47:41 2011 New Revision: 51096 URL:
http://svn.reactos.org/svn/reactos?rev=51096&view=rev
Log: [msi] -partial sync to wine 1.3.16 Added: trunk/reactos/dll/win32/msi/assembly.c (with props) Modified: trunk/reactos/dll/win32/msi/action.c trunk/reactos/dll/win32/msi/appsearch.c trunk/reactos/dll/win32/msi/classes.c trunk/reactos/dll/win32/msi/cond.tab.c trunk/reactos/dll/win32/msi/cond.y trunk/reactos/dll/win32/msi/create.c trunk/reactos/dll/win32/msi/custom.c trunk/reactos/dll/win32/msi/database.c trunk/reactos/dll/win32/msi/dialog.c trunk/reactos/dll/win32/msi/events.c trunk/reactos/dll/win32/msi/files.c trunk/reactos/dll/win32/msi/font.c trunk/reactos/dll/win32/msi/format.c trunk/reactos/dll/win32/msi/helpers.c trunk/reactos/dll/win32/msi/insert.c trunk/reactos/dll/win32/msi/install.c trunk/reactos/dll/win32/msi/media.c trunk/reactos/dll/win32/msi/msi.c trunk/reactos/dll/win32/msi/msi.rbuild trunk/reactos/dll/win32/msi/msi.rc trunk/reactos/dll/win32/msi/msi.spec trunk/reactos/dll/win32/msi/msi_main.c trunk/reactos/dll/win32/msi/msipriv.h trunk/reactos/dll/win32/msi/msiquery.c trunk/reactos/dll/win32/msi/msiserver.idl trunk/reactos/dll/win32/msi/package.c trunk/reactos/dll/win32/msi/record.c trunk/reactos/dll/win32/msi/registry.c trunk/reactos/dll/win32/msi/script.c trunk/reactos/dll/win32/msi/source.c trunk/reactos/dll/win32/msi/sql.tab.c trunk/reactos/dll/win32/msi/sql.y trunk/reactos/dll/win32/msi/string.c trunk/reactos/dll/win32/msi/table.c trunk/reactos/dll/win32/msi/where.c [This mail would be too long, it was shortened to contain the URLs only.] Modified: trunk/reactos/dll/win32/msi/action.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/action.c?rev…
Modified: trunk/reactos/dll/win32/msi/appsearch.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/appsearch.c?…
Added: trunk/reactos/dll/win32/msi/assembly.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/assembly.c?r…
Modified: trunk/reactos/dll/win32/msi/classes.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/classes.c?re…
Modified: trunk/reactos/dll/win32/msi/cond.tab.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/cond.tab.c?r…
Modified: trunk/reactos/dll/win32/msi/cond.y URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/cond.y?rev=5…
Modified: trunk/reactos/dll/win32/msi/create.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/create.c?rev…
Modified: trunk/reactos/dll/win32/msi/custom.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/custom.c?rev…
Modified: trunk/reactos/dll/win32/msi/database.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/database.c?r…
Modified: trunk/reactos/dll/win32/msi/dialog.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/dialog.c?rev…
Modified: trunk/reactos/dll/win32/msi/events.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/events.c?rev…
Modified: trunk/reactos/dll/win32/msi/files.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/files.c?rev=…
Modified: trunk/reactos/dll/win32/msi/font.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/font.c?rev=5…
Modified: trunk/reactos/dll/win32/msi/format.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/format.c?rev…
Modified: trunk/reactos/dll/win32/msi/helpers.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/helpers.c?re…
Modified: trunk/reactos/dll/win32/msi/insert.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/insert.c?rev…
Modified: trunk/reactos/dll/win32/msi/install.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/install.c?re…
Modified: trunk/reactos/dll/win32/msi/media.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/media.c?rev=…
Modified: trunk/reactos/dll/win32/msi/msi.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/msi.c?rev=51…
Modified: trunk/reactos/dll/win32/msi/msi.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/msi.rbuild?r…
Modified: trunk/reactos/dll/win32/msi/msi.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/msi.rc?rev=5…
Modified: trunk/reactos/dll/win32/msi/msi.spec URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/msi.spec?rev…
Modified: trunk/reactos/dll/win32/msi/msi_main.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/msi_main.c?r…
Modified: trunk/reactos/dll/win32/msi/msipriv.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/msipriv.h?re…
Modified: trunk/reactos/dll/win32/msi/msiquery.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/msiquery.c?r…
Modified: trunk/reactos/dll/win32/msi/msiserver.idl URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/msiserver.id…
Modified: trunk/reactos/dll/win32/msi/package.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/package.c?re…
Modified: trunk/reactos/dll/win32/msi/record.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/record.c?rev…
Modified: trunk/reactos/dll/win32/msi/registry.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/registry.c?r…
Modified: trunk/reactos/dll/win32/msi/script.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/script.c?rev…
Modified: trunk/reactos/dll/win32/msi/source.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/source.c?rev…
Modified: trunk/reactos/dll/win32/msi/sql.tab.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/sql.tab.c?re…
Modified: trunk/reactos/dll/win32/msi/sql.y URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/sql.y?rev=51…
Modified: trunk/reactos/dll/win32/msi/string.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/string.c?rev…
Modified: trunk/reactos/dll/win32/msi/table.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/table.c?rev=…
Modified: trunk/reactos/dll/win32/msi/where.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msi/where.c?rev=…
13 years, 9 months
1
0
0
0
[jimtabor] 51095: [User32] - Finishing with setting window class types from the window proc. Next step will be checking it in the User32 message exchange instead of using the class structure. This ...
by jimtabor@svn.reactos.org
Author: jimtabor Date: Sun Mar 20 01:29:39 2011 New Revision: 51095 URL:
http://svn.reactos.org/svn/reactos?rev=51095&view=rev
Log: [User32] - Finishing with setting window class types from the window proc. Next step will be checking it in the User32 message exchange instead of using the class structure. This was recognized with the MDI tests, this too could fix the combo listbox issue. - Minor static test fixes and miscellaneous notes. Modified: trunk/reactos/dll/win32/user32/controls/icontitle.c trunk/reactos/dll/win32/user32/controls/regcontrol.c trunk/reactos/dll/win32/user32/controls/scrollbar.c trunk/reactos/dll/win32/user32/controls/static.c trunk/reactos/dll/win32/user32/windows/menu.c Modified: trunk/reactos/dll/win32/user32/controls/icontitle.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/controls/…
============================================================================== --- trunk/reactos/dll/win32/user32/controls/icontitle.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/user32/controls/icontitle.c [iso-8859-1] Sun Mar 20 01:29:39 2011 @@ -189,6 +189,18 @@ HWND owner = GetWindow( hWnd, GW_OWNER ); if (!IsWindow(hWnd)) return 0; +#ifdef __REACTOS__ // Do this now, remove after Server side is fixed. + PWND pWnd; + + pWnd = ValidateHwnd(hWnd); + if (pWnd) + { + if (!pWnd->fnid) + { + NtUserSetWindowFNID(hWnd, FNID_ICONTITLE); + } + } +#endif switch( msg ) { @@ -201,6 +213,11 @@ hIconTitleFont = CreateFontIndirectA( &logFont ); } return (hIconTitleFont ? 0 : -1); +#ifdef __REACTOS__ + case WM_DESTROY: + NtUserSetWindowFNID(hWnd, FNID_DESTROY); + break; +#endif case WM_NCHITTEST: return HTCAPTION; case WM_NCMOUSEMOVE: Modified: trunk/reactos/dll/win32/user32/controls/regcontrol.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/controls/…
============================================================================== --- trunk/reactos/dll/win32/user32/controls/regcontrol.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/user32/controls/regcontrol.c [iso-8859-1] Sun Mar 20 01:29:39 2011 @@ -87,8 +87,23 @@ WINAPI MsgWindowProc( HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam ) { + PWND pWnd; + + pWnd = ValidateHwnd(hwnd); + if (pWnd) + { + if (!pWnd->fnid) + { + NtUserSetWindowFNID(hwnd, FNID_MESSAGEWND); + } + } + if (message == WM_NCCREATE) return TRUE; - return 0; + + if (message == WM_DESTROY) + NtUserSetWindowFNID(hwnd, FNID_DESTROY); + + return DefWindowProc(hwnd, message, wParam, lParam ); } LRESULT Modified: trunk/reactos/dll/win32/user32/controls/scrollbar.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/controls/…
============================================================================== --- trunk/reactos/dll/win32/user32/controls/scrollbar.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/user32/controls/scrollbar.c [iso-8859-1] Sun Mar 20 01:29:39 2011 @@ -1248,11 +1248,30 @@ return 0; } +#ifdef __REACTOS__ // Do this now, remove after Server side is fixed. + PWND pWnd; + + pWnd = ValidateHwnd(Wnd); + if (pWnd) + { + if (!pWnd->fnid) + { + NtUserSetWindowFNID(Wnd, FNID_SCROLLBAR); + } + } +#endif + switch (Msg) { case WM_CREATE: IntScrollCreateScrollBar(Wnd, (LPCREATESTRUCTW) lParam); break; + +#ifdef __REACTOS__ + case WM_DESTROY: + NtUserSetWindowFNID(Wnd, FNID_DESTROY); + return DefWindowProc(Wnd, Msg, wParam, lParam ); +#endif //#if 0 /* FIXME */ case WM_ENABLE: Modified: trunk/reactos/dll/win32/user32/controls/static.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/controls/…
============================================================================== --- trunk/reactos/dll/win32/user32/controls/static.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/user32/controls/static.c [iso-8859-1] Sun Mar 20 01:29:39 2011 @@ -813,6 +813,9 @@ GetClientRect( hwnd, &rc); /* FIXME: send WM_CTLCOLORSTATIC */ +#ifdef __REACTOS__ + hBrush = STATIC_SendWmCtlColorStatic(hwnd, hdc); // Always sent.... +#endif switch (style & SS_TYPEMASK) { case SS_BLACKRECT: Modified: trunk/reactos/dll/win32/user32/windows/menu.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/windows/m…
============================================================================== --- trunk/reactos/dll/win32/user32/windows/menu.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/user32/windows/menu.c [iso-8859-1] Sun Mar 20 01:29:39 2011 @@ -1792,9 +1792,24 @@ MenuCleanupRosMenuItemInfo(&ItemInfo); } +// +// This breaks some test results. Should handle A2U if called! +// LRESULT WINAPI PopupMenuWndProcA(HWND Wnd, UINT Message, WPARAM wParam, LPARAM lParam) { TRACE("YES! hwnd=%x msg=0x%04x wp=0x%04lx lp=0x%08lx\n", Wnd, Message, wParam, lParam); +#ifdef __REACTOS__ + PWND pWnd; + + pWnd = ValidateHwnd(Wnd); + if (pWnd) + { + if (!pWnd->fnid) + { + NtUserSetWindowFNID(Wnd, FNID_MENU); + } + } +#endif switch(Message) { @@ -1834,6 +1849,9 @@ top_popup = NULL; top_popup_hmenu = NULL; } +#ifdef __REACTOS__ + NtUserSetWindowFNID(Wnd, FNID_DESTROY); +#endif break; case WM_SHOWWINDOW: @@ -1868,6 +1886,18 @@ PopupMenuWndProcW(HWND Wnd, UINT Message, WPARAM wParam, LPARAM lParam) { TRACE("hwnd=%x msg=0x%04x wp=0x%04lx lp=0x%08lx\n", Wnd, Message, wParam, lParam); +#ifdef __REACTOS__ // Do this now, remove after Server side is fixed. + PWND pWnd; + + pWnd = ValidateHwnd(Wnd); + if (pWnd) + { + if (!pWnd->fnid) + { + NtUserSetWindowFNID(Wnd, FNID_MENU); + } + } +#endif switch(Message) { @@ -1907,6 +1937,9 @@ top_popup = NULL; top_popup_hmenu = NULL; } +#ifdef __REACTOS__ + NtUserSetWindowFNID(Wnd, FNID_DESTROY); +#endif break; case WM_SHOWWINDOW:
13 years, 9 months
1
0
0
0
[jimtabor] 51094: [Win32k] - Move the appropriate code from window.c to winpos.c, decreasing the size in window.c. Adding proper checks for maximums and desktop/message windows. - Started MinMaximi...
by jimtabor@svn.reactos.org
Author: jimtabor Date: Sun Mar 20 01:09:15 2011 New Revision: 51094 URL:
http://svn.reactos.org/svn/reactos?rev=51094&view=rev
Log: [Win32k] - Move the appropriate code from window.c to winpos.c, decreasing the size in window.c. Adding proper checks for maximums and desktop/message windows. - Started MinMaximize, experimental, based on an idea and boredom, needing a good test case. Also away of troubleshooting our window positioning with minimize and maximizing windows. Modified: trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c trunk/reactos/subsystems/win32/win32k/ntuser/window.c trunk/reactos/subsystems/win32/win32k/ntuser/winpos.c 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] Sun Mar 20 01:09:15 2011 @@ -817,8 +817,45 @@ UINT cmd, // Wine SW_ commands BOOL Hide) { - UNIMPLEMENTED; - return 0; + RECTL NewPos; + UINT SwFlags; + PWND pWnd; + + DPRINT("Enter NtUserMinMaximize\n"); + UserEnterExclusive(); + + pWnd = UserGetWindowObject(hWnd); + if ( !pWnd || // FIXME: + pWnd == IntGetDesktopWindow() || // pWnd->fnid == FNID_DESKTOP + pWnd == IntGetMessageWindow() ) // pWnd->fnid == FNID_MESSAGEWND + { + goto Exit; + } + + if ( cmd > SW_MAX || pWnd->state2 & WNDS2_INDESTROY) + { + EngSetLastError(ERROR_INVALID_PARAMETER); + goto Exit; + } + + co_WinPosMinMaximize(pWnd, cmd, &NewPos); + + SwFlags = Hide ? SWP_NOACTIVATE|SWP_NOZORDER|SWP_FRAMECHANGED : SWP_NOZORDER|SWP_FRAMECHANGED; + + co_WinPosSetWindowPos( pWnd, + NULL, + NewPos.left, + NewPos.top, + NewPos.right, + NewPos.bottom, + SwFlags); + + co_WinPosShowWindow(pWnd, cmd); + +Exit: + DPRINT("Leave NtUserMinMaximize\n"); + UserLeave(); + return 0; // Always NULL? } DWORD 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] Sun Mar 20 01:09:15 2011 @@ -3685,23 +3685,6 @@ } /* - * @implemented - */ -BOOL APIENTRY -NtUserMoveWindow( - HWND hWnd, - int X, - int Y, - int nWidth, - int nHeight, - BOOL bRepaint) -{ - return NtUserSetWindowPos(hWnd, 0, X, Y, nWidth, nHeight, - (bRepaint ? SWP_NOZORDER | SWP_NOACTIVATE : - SWP_NOZORDER | SWP_NOACTIVATE | SWP_NOREDRAW)); -} - -/* QueryWindow based on KJK::Hyperion and James Tabor. 0 = QWUniqueProcessId @@ -3899,234 +3882,6 @@ DPRINT("Leave NtUserSetWindowFNID\n"); UserLeave(); END_CLEANUP; -} - - -/* - * @implemented - */ -BOOL APIENTRY -NtUserSetWindowPlacement(HWND hWnd, - WINDOWPLACEMENT *lpwndpl) -{ - PWND Wnd; - WINDOWPLACEMENT Safepl; - NTSTATUS Status; - DECLARE_RETURN(BOOL); - USER_REFERENCE_ENTRY Ref; - - DPRINT("Enter NtUserSetWindowPlacement\n"); - UserEnterExclusive(); - - if (!(Wnd = UserGetWindowObject(hWnd))) - { - RETURN( FALSE); - } - - Status = MmCopyFromCaller(&Safepl, lpwndpl, sizeof(WINDOWPLACEMENT)); - if(!NT_SUCCESS(Status)) - { - SetLastNtError(Status); - RETURN( FALSE); - } - if(Safepl.length != sizeof(WINDOWPLACEMENT)) - { - RETURN( FALSE); - } - - UserRefObjectCo(Wnd, &Ref); - - if ((Wnd->style & (WS_MAXIMIZE | WS_MINIMIZE)) == 0) - { - co_WinPosSetWindowPos(Wnd, NULL, - Safepl.rcNormalPosition.left, Safepl.rcNormalPosition.top, - Safepl.rcNormalPosition.right - Safepl.rcNormalPosition.left, - Safepl.rcNormalPosition.bottom - Safepl.rcNormalPosition.top, - SWP_NOZORDER | SWP_NOACTIVATE); - } - - /* FIXME - change window status */ - co_WinPosShowWindow(Wnd, Safepl.showCmd); - - Wnd->InternalPosInitialized = TRUE; - Wnd->InternalPos.NormalRect = Safepl.rcNormalPosition; - Wnd->InternalPos.IconPos = Safepl.ptMinPosition; - Wnd->InternalPos.MaxPos = Safepl.ptMaxPosition; - - UserDerefObjectCo(Wnd); - RETURN(TRUE); - -CLEANUP: - DPRINT("Leave NtUserSetWindowPlacement, ret=%i\n",_ret_); - UserLeave(); - END_CLEANUP; -} - - -/* - * @implemented - */ -BOOL APIENTRY -NtUserSetWindowPos( - HWND hWnd, - HWND hWndInsertAfter, - int X, - int Y, - int cx, - int cy, - UINT uFlags) -{ - DECLARE_RETURN(BOOL); - PWND Window; - BOOL ret; - USER_REFERENCE_ENTRY Ref; - - DPRINT("Enter NtUserSetWindowPos\n"); - UserEnterExclusive(); - - if (!(Window = UserGetWindowObject(hWnd))) - { - RETURN(FALSE); - } - - /* First make sure that coordinates are valid for WM_WINDOWPOSCHANGING */ - if (!(uFlags & SWP_NOMOVE)) - { - if (X < -32768) X = -32768; - else if (X > 32767) X = 32767; - if (Y < -32768) Y = -32768; - else if (Y > 32767) Y = 32767; - } - if (!(uFlags & SWP_NOSIZE)) - { - if (cx < 0) cx = 0; - else if (cx > 32767) cx = 32767; - if (cy < 0) cy = 0; - else if (cy > 32767) cy = 32767; - } - - UserRefObjectCo(Window, &Ref); - ret = co_WinPosSetWindowPos(Window, hWndInsertAfter, X, Y, cx, cy, uFlags); - UserDerefObjectCo(Window); - - RETURN(ret); - -CLEANUP: - DPRINT("Leave NtUserSetWindowPos, ret=%i\n",_ret_); - UserLeave(); - END_CLEANUP; -} - -/* - * @implemented - */ -INT APIENTRY -NtUserSetWindowRgn( - HWND hWnd, - HRGN hRgn, - BOOL bRedraw) -{ - HRGN hrgnCopy; - PWND Window; - INT flags = (SWP_NOCLIENTSIZE|SWP_NOCLIENTMOVE|SWP_NOACTIVATE|SWP_FRAMECHANGED|SWP_NOSIZE|SWP_NOMOVE); - BOOLEAN Ret = FALSE; - DECLARE_RETURN(INT); - - DPRINT("Enter NtUserSetWindowRgn\n"); - UserEnterExclusive(); - - if (!(Window = UserGetWindowObject(hWnd))) - { - RETURN( 0); - } - - if (hRgn) // The region will be deleted in user32. - { - if (GDIOBJ_ValidateHandle(hRgn, GDI_OBJECT_TYPE_REGION)) - { - hrgnCopy = IntSysCreateRectRgn(0, 0, 0, 0); - - NtGdiCombineRgn(hrgnCopy, hRgn, 0, RGN_COPY); - } - else - RETURN( 0); - } - else - { - hrgnCopy = NULL; - } - - if (Window->hrgnClip) - { - /* Delete no longer needed region handle */ - GreDeleteObject(Window->hrgnClip); - } - - if (hrgnCopy) - { - if (Window->fnid != FNID_DESKTOP) - NtGdiOffsetRgn(hrgnCopy, Window->rcWindow.left, Window->rcWindow.top); - - /* Set public ownership */ - IntGdiSetRegionOwner(hrgnCopy, GDI_OBJ_HMGR_PUBLIC); - } - Window->hrgnClip = hrgnCopy; - - Ret = co_WinPosSetWindowPos(Window, HWND_TOP, 0, 0, 0, 0, bRedraw ? flags : (flags|SWP_NOREDRAW) ); - - RETURN( (INT)Ret); - -CLEANUP: - DPRINT("Leave NtUserSetWindowRgn, ret=%i\n",_ret_); - UserLeave(); - END_CLEANUP; -} - - -/* - * @implemented - */ -BOOL APIENTRY -NtUserShowWindow(HWND hWnd, LONG nCmdShow) -{ - PWND Window; - BOOL ret; - DECLARE_RETURN(BOOL); - USER_REFERENCE_ENTRY Ref; - - DPRINT("Enter NtUserShowWindow\n"); - UserEnterExclusive(); - - if (!(Window = UserGetWindowObject(hWnd))) - { - RETURN(FALSE); - } - - UserRefObjectCo(Window, &Ref); - ret = co_WinPosShowWindow(Window, nCmdShow); - UserDerefObjectCo(Window); - - RETURN(ret); - -CLEANUP: - DPRINT("Leave NtUserShowWindow, ret=%i\n",_ret_); - UserLeave(); - END_CLEANUP; -} - - -/* - * @unimplemented - */ -BOOL APIENTRY -NtUserShowWindowAsync(HWND hWnd, LONG nCmdShow) -{ -#if 0 - UNIMPLEMENTED - return 0; -#else - return NtUserShowWindow(hWnd, nCmdShow); -#endif } /* Modified: trunk/reactos/subsystems/win32/win32k/ntuser/winpos.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/winpos.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/winpos.c [iso-8859-1] Sun Mar 20 01:09:15 2011 @@ -20,7 +20,7 @@ * COPYRIGHT: See COPYING in the top level directory * PROJECT: ReactOS kernel * PURPOSE: Windows - * FILE: subsys/win32k/ntuser/window.c + * FILE: subsystems/win32/win32k/ntuser/window.c * PROGRAMER: Casper S. Hornstrup (chorns(a)users.sourceforge.net) * REVISION HISTORY: * 06-06-2001 CSH NtGdid @@ -199,8 +199,8 @@ x = rectParent.left; y = rectParent.bottom; - xspacing = UserGetSystemMetrics(SM_CXMINSPACING); - yspacing = UserGetSystemMetrics(SM_CYMINSPACING); + xspacing = UserGetSystemMetrics(SM_CXICONSPACING); + yspacing = UserGetSystemMetrics(SM_CYICONSPACING); DPRINT("X:%d Y:%d XS:%d YS:%d\n",x,y,xspacing,yspacing); @@ -216,8 +216,8 @@ USER_REFERENCE_ENTRY Ref; UserRefObjectCo(Child, &Ref); - co_WinPosSetWindowPos(Child, 0, x + UserGetSystemMetrics(SM_CXBORDER), - y - yspacing - UserGetSystemMetrics(SM_CYBORDER) + co_WinPosSetWindowPos(Child, 0, x + (xspacing - UserGetSystemMetrics(SM_CXICON)) / 2, + y - yspacing - UserGetSystemMetrics(SM_CYICON) / 2 , 0, 0, SWP_NOSIZE | SWP_NOZORDER | SWP_NOACTIVATE ); UserDerefObjectCo(Child); @@ -239,7 +239,7 @@ static VOID FASTCALL WinPosFindIconPos(PWND Window, POINT *Pos) { - /* FIXME */ + DPRINT1("WinPosFindIconPos FIXME!\n"); } VOID FASTCALL @@ -1832,7 +1832,7 @@ SWP_NOCOPYBITS|SWP_HIDEWINDOW|SWP_SHOWWINDOW|SWP_FRAMECHANGED| SWP_NOACTIVATE|SWP_NOREDRAW|SWP_NOZORDER|SWP_NOMOVE|SWP_NOSIZE); - DPRINT("Enter NtUsereferWindowPos\n"); + DPRINT("Enter NtUserDeferWindowPos\n"); UserEnterExclusive(); if ( Flags & Tmp ) @@ -1842,9 +1842,9 @@ } pWnd = UserGetWindowObject(Wnd); - if ( !pWnd || - pWnd == IntGetDesktopWindow() || - pWnd == IntGetMessageWindow() ) + if ( !pWnd || // FIXME: + pWnd == IntGetDesktopWindow() || // pWnd->fnid == FNID_DESKTOP + pWnd == IntGetMessageWindow() ) // pWnd->fnid == FNID_MESSAGEWND { goto Exit; } @@ -1871,6 +1871,281 @@ return Ret; } +/* + * @implemented + */ +BOOL APIENTRY +NtUserMoveWindow( + HWND hWnd, + int X, + int Y, + int nWidth, + int nHeight, + BOOL bRepaint) +{ + return NtUserSetWindowPos(hWnd, 0, X, Y, nWidth, nHeight, + (bRepaint ? SWP_NOZORDER | SWP_NOACTIVATE : + SWP_NOZORDER | SWP_NOACTIVATE | SWP_NOREDRAW)); +} + +/* + * @implemented + */ +BOOL APIENTRY +NtUserSetWindowPos( + HWND hWnd, + HWND hWndInsertAfter, + int X, + int Y, + int cx, + int cy, + UINT uFlags) +{ + DECLARE_RETURN(BOOL); + PWND Window, pWndIA; + BOOL ret; + USER_REFERENCE_ENTRY Ref; + + DPRINT("Enter NtUserSetWindowPos\n"); + UserEnterExclusive(); + + if (!(Window = UserGetWindowObject(hWnd)) || // FIXME: + Window == IntGetDesktopWindow() || // pWnd->fnid == FNID_DESKTOP + Window == IntGetMessageWindow() ) // pWnd->fnid == FNID_MESSAGEWND + { + RETURN(FALSE); + } + + if ( hWndInsertAfter && + hWndInsertAfter != HWND_BOTTOM && + hWndInsertAfter != HWND_TOPMOST && + hWndInsertAfter != HWND_NOTOPMOST ) + { + pWndIA = UserGetWindowObject(hWndInsertAfter); + if ( !pWndIA || + pWndIA == IntGetDesktopWindow() || + pWndIA == IntGetMessageWindow() ) + { + RETURN(FALSE); + } + } + + /* First make sure that coordinates are valid for WM_WINDOWPOSCHANGING */ + if (!(uFlags & SWP_NOMOVE)) + { + if (X < -32768) X = -32768; + else if (X > 32767) X = 32767; + if (Y < -32768) Y = -32768; + else if (Y > 32767) Y = 32767; + } + if (!(uFlags & SWP_NOSIZE)) + { + if (cx < 0) cx = 0; + else if (cx > 32767) cx = 32767; + if (cy < 0) cy = 0; + else if (cy > 32767) cy = 32767; + } + + UserRefObjectCo(Window, &Ref); + ret = co_WinPosSetWindowPos(Window, hWndInsertAfter, X, Y, cx, cy, uFlags); + UserDerefObjectCo(Window); + + RETURN(ret); + +CLEANUP: + DPRINT("Leave NtUserSetWindowPos, ret=%i\n",_ret_); + UserLeave(); + END_CLEANUP; +} + +/* + * @implemented + */ +INT APIENTRY +NtUserSetWindowRgn( + HWND hWnd, + HRGN hRgn, + BOOL bRedraw) +{ + HRGN hrgnCopy; + PWND Window; + INT flags = (SWP_NOCLIENTSIZE|SWP_NOCLIENTMOVE|SWP_NOACTIVATE|SWP_FRAMECHANGED|SWP_NOSIZE|SWP_NOMOVE); + BOOLEAN Ret = FALSE; + DECLARE_RETURN(INT); + + DPRINT("Enter NtUserSetWindowRgn\n"); + UserEnterExclusive(); + + if (!(Window = UserGetWindowObject(hWnd)) || // FIXME: + Window == IntGetDesktopWindow() || // pWnd->fnid == FNID_DESKTOP + Window == IntGetMessageWindow() ) // pWnd->fnid == FNID_MESSAGEWND + { + RETURN( 0); + } + + if (hRgn) // The region will be deleted in user32. + { + if (GDIOBJ_ValidateHandle(hRgn, GDI_OBJECT_TYPE_REGION)) + { + hrgnCopy = IntSysCreateRectRgn(0, 0, 0, 0); + + NtGdiCombineRgn(hrgnCopy, hRgn, 0, RGN_COPY); + } + else + RETURN( 0); + } + else + { + hrgnCopy = NULL; + } + + if (Window->hrgnClip) + { + /* Delete no longer needed region handle */ + GreDeleteObject(Window->hrgnClip); + } + + if (hrgnCopy) + { + if (Window->fnid != FNID_DESKTOP) + NtGdiOffsetRgn(hrgnCopy, Window->rcWindow.left, Window->rcWindow.top); + + /* Set public ownership */ + IntGdiSetRegionOwner(hrgnCopy, GDI_OBJ_HMGR_PUBLIC); + } + Window->hrgnClip = hrgnCopy; + + Ret = co_WinPosSetWindowPos(Window, HWND_TOP, 0, 0, 0, 0, bRedraw ? flags : (flags|SWP_NOREDRAW) ); + + RETURN( (INT)Ret); + +CLEANUP: + DPRINT("Leave NtUserSetWindowRgn, ret=%i\n",_ret_); + UserLeave(); + END_CLEANUP; +} + +/* + * @implemented + */ +BOOL APIENTRY +NtUserSetWindowPlacement(HWND hWnd, + WINDOWPLACEMENT *lpwndpl) +{ + PWND Wnd; + WINDOWPLACEMENT Safepl; + DECLARE_RETURN(BOOL); + USER_REFERENCE_ENTRY Ref; + + DPRINT("Enter NtUserSetWindowPlacement\n"); + UserEnterExclusive(); + + if (!(Wnd = UserGetWindowObject(hWnd)) || // FIXME: + Wnd == IntGetDesktopWindow() || // pWnd->fnid == FNID_DESKTOP + Wnd == IntGetMessageWindow() ) // pWnd->fnid == FNID_MESSAGEWND + { + RETURN( FALSE); + } + + _SEH2_TRY + { + ProbeForRead(lpwndpl, sizeof(WINDOWPLACEMENT), 1); + RtlCopyMemory(&Safepl, lpwndpl, sizeof(WINDOWPLACEMENT)); + } + _SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER) + { + SetLastNtError(_SEH2_GetExceptionCode()); + _SEH2_YIELD(RETURN( FALSE)); + } + _SEH2_END + + if(Safepl.length != sizeof(WINDOWPLACEMENT)) + { + RETURN( FALSE); + } + + UserRefObjectCo(Wnd, &Ref); + + if ((Wnd->style & (WS_MAXIMIZE | WS_MINIMIZE)) == 0) + { + co_WinPosSetWindowPos(Wnd, NULL, + Safepl.rcNormalPosition.left, Safepl.rcNormalPosition.top, + Safepl.rcNormalPosition.right - Safepl.rcNormalPosition.left, + Safepl.rcNormalPosition.bottom - Safepl.rcNormalPosition.top, + SWP_NOZORDER | SWP_NOACTIVATE); + } + + /* FIXME - change window status */ + co_WinPosShowWindow(Wnd, Safepl.showCmd); + + Wnd->InternalPosInitialized = TRUE; + Wnd->InternalPos.NormalRect = Safepl.rcNormalPosition; + Wnd->InternalPos.IconPos = Safepl.ptMinPosition; + Wnd->InternalPos.MaxPos = Safepl.ptMaxPosition; + + UserDerefObjectCo(Wnd); + RETURN(TRUE); + +CLEANUP: + DPRINT("Leave NtUserSetWindowPlacement, ret=%i\n",_ret_); + UserLeave(); + END_CLEANUP; +} + +/* + * @unimplemented + */ +BOOL APIENTRY +NtUserShowWindowAsync(HWND hWnd, LONG nCmdShow) +{ +#if 0 + UNIMPLEMENTED + return 0; +#else + return NtUserShowWindow(hWnd, nCmdShow); +#endif +} + +/* + * @implemented + */ +BOOL APIENTRY +NtUserShowWindow(HWND hWnd, LONG nCmdShow) +{ + PWND Window; + BOOL ret; + DECLARE_RETURN(BOOL); + USER_REFERENCE_ENTRY Ref; + + DPRINT("Enter NtUserShowWindow\n"); + UserEnterExclusive(); + + if (!(Window = UserGetWindowObject(hWnd)) || // FIXME: + Window == IntGetDesktopWindow() || // pWnd->fnid == FNID_DESKTOP + Window == IntGetMessageWindow() ) // pWnd->fnid == FNID_MESSAGEWND + { + RETURN(FALSE); + } + + if ( nCmdShow > SW_MAX || Window->state2 & WNDS2_INDESTROY) + { + EngSetLastError(ERROR_INVALID_PARAMETER); + RETURN(FALSE); + } + + UserRefObjectCo(Window, &Ref); + ret = co_WinPosShowWindow(Window, nCmdShow); + UserDerefObjectCo(Window); + + RETURN(ret); + +CLEANUP: + DPRINT("Leave NtUserShowWindow, ret=%i\n",_ret_); + UserLeave(); + END_CLEANUP; +} + +//// Ugly NtUser API //// BOOL APIENTRY NtUserGetMinMaxInfo(
13 years, 9 months
1
0
0
0
[jimtabor] 51093: [Win32k] - Fix sign for BeginDeferWindowPos(-1) test, see bug 6025.
by jimtabor@svn.reactos.org
Author: jimtabor Date: Sun Mar 20 00:21:45 2011 New Revision: 51093 URL:
http://svn.reactos.org/svn/reactos?rev=51093&view=rev
Log: [Win32k] - Fix sign for BeginDeferWindowPos(-1) test, see bug 6025. Modified: trunk/reactos/subsystems/win32/win32k/ntuser/simplecall.c Modified: trunk/reactos/subsystems/win32/win32k/ntuser/simplecall.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/simplecall.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/simplecall.c [iso-8859-1] Sun Mar 20 00:21:45 2011 @@ -162,13 +162,15 @@ { PSMWP psmwp; HDWP hDwp = NULL; - if (Param < 0) + INT count = (INT)Param; + + if (count < 0) { EngSetLastError(ERROR_INVALID_PARAMETER); RETURN(0); } /* Windows allows zero count, in which case it allocates context for 8 moves */ - if (Param == 0) Param = 8; + if (count == 0) count = 8; psmwp = (PSMWP) UserCreateObject( gHandleTable, NULL, @@ -176,13 +178,13 @@ otSMWP, sizeof(SMWP)); if (!psmwp) RETURN(0); - psmwp->acvr = ExAllocatePoolWithTag(PagedPool, Param * sizeof(CVR), USERTAG_SWP); + psmwp->acvr = ExAllocatePoolWithTag(PagedPool, count * sizeof(CVR), USERTAG_SWP); if (!psmwp->acvr) { UserDeleteObject(hDwp, otSMWP); RETURN(0); } - RtlZeroMemory(psmwp->acvr, Param * sizeof(CVR)); + RtlZeroMemory(psmwp->acvr, count * sizeof(CVR)); psmwp->bHandle = TRUE; psmwp->ccvr = 0; // actualCount psmwp->ccvrAlloc = Param; // suggestedCount
13 years, 9 months
1
0
0
0
[ekohl] 51092: [SERVICES] RQueryServiceConfig2A/W must return ERROR_SUCCESS if the Description value of a service does not exist. This fixes a winetest failure.
by ekohl@svn.reactos.org
Author: ekohl Date: Sat Mar 19 19:14:53 2011 New Revision: 51092 URL:
http://svn.reactos.org/svn/reactos?rev=51092&view=rev
Log: [SERVICES] RQueryServiceConfig2A/W must return ERROR_SUCCESS if the Description value of a service does not exist. This fixes a winetest failure. Modified: trunk/reactos/base/system/services/rpcserver.c Modified: trunk/reactos/base/system/services/rpcserver.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/system/services/rpcse…
============================================================================== --- trunk/reactos/base/system/services/rpcserver.c [iso-8859-1] (original) +++ trunk/reactos/base/system/services/rpcserver.c [iso-8859-1] Sat Mar 19 19:14:53 2011 @@ -4558,42 +4558,40 @@ LPSERVICE_DESCRIPTIONA lpServiceDescription = (LPSERVICE_DESCRIPTIONA)lpBuffer; LPSTR lpStr; - *pcbBytesNeeded = sizeof(SERVICE_DESCRIPTIONA); - dwError = ScmReadString(hServiceKey, L"Description", &lpDescriptionW); + if (dwError != ERROR_SUCCESS && dwError != ERROR_FILE_NOT_FOUND) + goto done; + + *pcbBytesNeeded = sizeof(SERVICE_DESCRIPTIONA); if (dwError == ERROR_SUCCESS) - { *pcbBytesNeeded += ((wcslen(lpDescriptionW) + 1) * sizeof(WCHAR)); - } - - if (cbBufSize >= *pcbBytesNeeded) - { - - if (dwError == ERROR_SUCCESS) - { - lpStr = (LPSTR)(lpServiceDescription + 1); - - WideCharToMultiByte(CP_ACP, - 0, - lpDescriptionW, - -1, - lpStr, - wcslen(lpDescriptionW), - NULL, - NULL); - lpServiceDescription->lpDescription = (LPSTR)((ULONG_PTR)lpStr - (ULONG_PTR)lpServiceDescription); - } - else - { - lpServiceDescription->lpDescription = NULL; - goto done; - } + + if (cbBufSize < *pcbBytesNeeded) + { + dwError = ERROR_INSUFFICIENT_BUFFER; + goto done; + } + + if (dwError == ERROR_SUCCESS) + { + lpStr = (LPSTR)(lpServiceDescription + 1); + + WideCharToMultiByte(CP_ACP, + 0, + lpDescriptionW, + -1, + lpStr, + wcslen(lpDescriptionW), + NULL, + NULL); + lpServiceDescription->lpDescription = (LPSTR)((ULONG_PTR)lpStr - (ULONG_PTR)lpServiceDescription); } else { - dwError = ERROR_INSUFFICIENT_BUFFER; + lpServiceDescription->lpDescription = NULL; + dwError = ERROR_SUCCESS; goto done; } } @@ -4681,21 +4679,30 @@ dwError = ScmReadString(hServiceKey, L"Description", &lpDescription); - if (dwError != ERROR_SUCCESS) + if (dwError != ERROR_SUCCESS && dwError != ERROR_FILE_NOT_FOUND) goto done; - dwRequiredSize = sizeof(SERVICE_DESCRIPTIONW) + ((wcslen(lpDescription) + 1) * sizeof(WCHAR)); - - if (cbBufSize < dwRequiredSize) - { - *pcbBytesNeeded = dwRequiredSize; + *pcbBytesNeeded = sizeof(SERVICE_DESCRIPTIONW); + if (dwError == ERROR_SUCCESS) + *pcbBytesNeeded += ((wcslen(lpDescription) + 1) * sizeof(WCHAR)); + + if (cbBufSize < *pcbBytesNeeded) + { dwError = ERROR_INSUFFICIENT_BUFFER; goto done; } - lpStr = (LPWSTR)(lpServiceDescription + 1); - wcscpy(lpStr, lpDescription); - lpServiceDescription->lpDescription = (LPWSTR)((ULONG_PTR)lpStr - (ULONG_PTR)lpServiceDescription); + if (dwError == ERROR_SUCCESS) + { + lpStr = (LPWSTR)(lpServiceDescription + 1); + wcscpy(lpStr, lpDescription); + lpServiceDescription->lpDescription = (LPWSTR)((ULONG_PTR)lpStr - (ULONG_PTR)lpServiceDescription); + } + else + { + lpServiceDescription->lpDescription = NULL; + dwError = ERROR_SUCCESS; + } } else if (dwInfoLevel == SERVICE_CONFIG_FAILURE_ACTIONS) {
13 years, 9 months
1
0
0
0
[osiejka] 51091: [DESK.CPL] - Activate "Show window contents while dragging" button for all languages present. Spotted by Piotr_hh See issue #6002 for more details.
by osiejka@svn.reactos.org
Author: osiejka Date: Sat Mar 19 14:11:37 2011 New Revision: 51091 URL:
http://svn.reactos.org/svn/reactos?rev=51091&view=rev
Log: [DESK.CPL] - Activate "Show window contents while dragging" button for all languages present. Spotted by Piotr_hh See issue #6002 for more details. Modified: trunk/reactos/dll/cpl/desk/lang/bg-BG.rc trunk/reactos/dll/cpl/desk/lang/cs-CZ.rc trunk/reactos/dll/cpl/desk/lang/el-GR.rc trunk/reactos/dll/cpl/desk/lang/fr-FR.rc trunk/reactos/dll/cpl/desk/lang/hu-HU.rc trunk/reactos/dll/cpl/desk/lang/id-ID.rc trunk/reactos/dll/cpl/desk/lang/it-IT.rc trunk/reactos/dll/cpl/desk/lang/nl-NL.rc trunk/reactos/dll/cpl/desk/lang/no-NO.rc trunk/reactos/dll/cpl/desk/lang/pl-PL.rc trunk/reactos/dll/cpl/desk/lang/ro-RO.rc trunk/reactos/dll/cpl/desk/lang/ru-RU.rc trunk/reactos/dll/cpl/desk/lang/sk-SK.rc trunk/reactos/dll/cpl/desk/lang/sv-SE.rc trunk/reactos/dll/cpl/desk/lang/uk-UA.rc trunk/reactos/dll/cpl/desk/lang/zh-CN.rc Modified: trunk/reactos/dll/cpl/desk/lang/bg-BG.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/bg-BG.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/bg-BG.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/bg-BG.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -116,7 +116,7 @@ CONTROL "Èçîáðàçÿâàíå íà &ñåíêè ïîä èçáîðíèöòå",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "Ïîêàçâàíå íà ñúäúðæàíèåòî íà &ïðîçîðöèòå ïî âðåìå íà âëà÷åíå",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "Ñ&êðèâàíå íà ïîä÷åðòàâàíåòî çà êëàâèàòóðíîòî íàñî÷âàíå, äî íàòèñêàíå íà Alt",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Îòêàç", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/cs-CZ.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/cs-CZ.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/cs-CZ.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/cs-CZ.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -119,7 +119,7 @@ CONTROL "Show sh&adows under menus",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "Show &window contents while dragging",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "&Hide underlined letters for keyboard navigation until I press the Alt key",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Cancel", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/el-GR.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/el-GR.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/el-GR.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/el-GR.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -112,7 +112,7 @@ CONTROL "Show sh&adows under menus",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "Show &window contents while dragging",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "&Hide underlined letters for keyboard navigation until I press the Alt key",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Cancel", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/fr-FR.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/fr-FR.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/fr-FR.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/fr-FR.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -115,7 +115,7 @@ CONTROL "Show sh&adows under menus",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "Show &window contents while dragging",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "&Hide underlined letters for keyboard navigation until I press the Alt key",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Cancel", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/hu-HU.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/hu-HU.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/hu-HU.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/hu-HU.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -113,7 +113,7 @@ CONTROL "Show sh&adows under menus",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "Show &window contents while dragging",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "&Hide underlined letters for keyboard navigation until I press the Alt key",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Cancel", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/id-ID.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/id-ID.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/id-ID.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/id-ID.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -112,7 +112,7 @@ CONTROL "Show sh&adows under menus",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "Show &window contents while dragging",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "&Hide underlined letters for keyboard navigation until I press the Alt key",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Cancel", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/it-IT.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/it-IT.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/it-IT.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/it-IT.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -112,7 +112,7 @@ CONTROL "&Ombreggiatura sotto i menu",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "Mostrare il contenuto delle finestr mentre le si trascina",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "&Nascondere la sottolineatura delle lettere di navigazione finche non è premuto il tasto Alt",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Annulla", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/nl-NL.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/nl-NL.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/nl-NL.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/nl-NL.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -114,7 +114,7 @@ CONTROL "Sch&aduw onder menu's weergeven",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "De in&houd van het venster tijdens het slepen weergeven",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "Onderstreepte letters voor toetsenbordnavigatie &verbergen tot ALT wordt ingedrukt",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Annuleren", IDCANCEL, 246, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/no-NO.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/no-NO.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/no-NO.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/no-NO.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -114,7 +114,7 @@ CONTROL "Vis sk&ygger under menyer",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "Vis &vindu innholdet ved flytting",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "&Skjul visning av understrekning for tastatur hurtigtast til jeg trykker på Alt tasten",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Avbryt", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/pl-PL.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/pl-PL.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/pl-PL.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/pl-PL.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -122,7 +122,7 @@ CONTROL "Pok&a¿ cienie pod menu",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "Poka¿ za&wartoæ okna podczas przeci¹gania",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "U&kryj podkrelenie liter do nawigacji klawiatur¹ dopóki nie nacisnê klawisza Alt",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Anuluj", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/ro-RO.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/ro-RO.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/ro-RO.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/ro-RO.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -116,7 +116,7 @@ CONTROL "AfiÈare u&mbre sub meniuri",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "AfiÈare c&onÈinut al ferestrelor când sunt trase",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "&Ascundere litere subliniate pentru navigarea cu tastatura pânÄ când apÄs Alt",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Anulare", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/ru-RU.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/ru-RU.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/ru-RU.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/ru-RU.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -112,7 +112,7 @@ CONTROL "Îòîáðàæàòü &òåíè, îòáðàñûâàåìûå ìåíþ",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "&Îòîáðàæàòü ñîäåðæèìîå îêíà ïðè ïåðåòàñêèâàíèè",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "Ñêð&ûâàòü óêàçàòåëè âûçîâà ñ êëàâèàòóðû äî íàæàòèÿ <Alt>",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Îòìåíà", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/sk-SK.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/sk-SK.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/sk-SK.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/sk-SK.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -122,7 +122,7 @@ CONTROL "&Zobrazova tiene pod ponukami",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "Zobrazova &obsah okna poèas presúvania",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "&Skrýva podèiarknuté písmená (klávesové skratky) a do stlaèenia klávesu Alt",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Zrui", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/sv-SE.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/sv-SE.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/sv-SE.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/sv-SE.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -115,7 +115,7 @@ CONTROL "Show sh&adows under menus",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "Show &window contents while dragging",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "&Hide underlined letters for keyboard navigation until I press the Alt key",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Cancel", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/uk-UA.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/uk-UA.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/uk-UA.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/uk-UA.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -120,7 +120,7 @@ CONTROL "³äîáðàæàòè ò³í³ â³ä ìåíþ",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "Ïîêàçàòè &âì³ñò â³êíà ï³ä ÷àñ ïåðåòÿãóâàííÿ",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "&Ïðèõîâóâàòè ïîêàæ÷èêè âèêëèêó ç êëàâ³àòóðè äî íàòèñíåííÿ <Alt>",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "Ñêàñóâàòè", IDCANCEL, 226, 165, 50, 14 Modified: trunk/reactos/dll/cpl/desk/lang/zh-CN.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/lang/zh-CN.rc…
============================================================================== --- trunk/reactos/dll/cpl/desk/lang/zh-CN.rc [iso-8859-1] (original) +++ trunk/reactos/dll/cpl/desk/lang/zh-CN.rc [iso-8859-1] Sat Mar 19 14:11:37 2011 @@ -121,7 +121,7 @@ CONTROL "Ôڲ˵¥ÏÂÏÔʾÒõÓ°(&A)",IDC_EFFAPPEARANCE_SETDROPSHADOW,"button", BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 95, 285, 19 CONTROL "Í϶¯Ê±ÏÔʾ´°¿ÚÄÚÈÝ(&W)",IDC_EFFAPPEARANCE_DRAGFULLWINDOWS,"button", - BS_AUTOCHECKBOX | WS_TABSTOP | WS_DISABLED, 10, 110, 285, 19 + BS_AUTOCHECKBOX | WS_TABSTOP, 10, 110, 285, 19 CONTROL "Ö±µ½ÎÒ°´ Alt ¼ü֮ǰ£¬ÇëÒþ²ØÓÐÏ»®ÏßµÄ×Öĸ¹©¼üÅÌʹÓÃ",IDC_EFFAPPEARANCE_KEYBOARDCUES,"button", BS_AUTOCHECKBOX | WS_TABSTOP, 10, 125, 285, 19 PUSHBUTTON "È¡Ïû", IDCANCEL, 226, 165, 50, 14
13 years, 9 months
1
0
0
0
[pschweitzer] 51090: [HAL] Remove HAL entry point (HalInitSystem) from generic lib, and move it to generic libs that handle different build flags. This fixes HAL MP entry point, for example
by pschweitzer@svn.reactos.org
Author: pschweitzer Date: Sat Mar 19 13:59:23 2011 New Revision: 51090 URL:
http://svn.reactos.org/svn/reactos?rev=51090&view=rev
Log: [HAL] Remove HAL entry point (HalInitSystem) from generic lib, and move it to generic libs that handle different build flags. This fixes HAL MP entry point, for example Modified: trunk/reactos/hal/halx86/hal_generic.rbuild trunk/reactos/hal/halx86/hal_generic_acpi.rbuild trunk/reactos/hal/halx86/hal_generic_pcat.rbuild Modified: trunk/reactos/hal/halx86/hal_generic.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/hal/halx86/hal_generic.rbu…
============================================================================== --- trunk/reactos/hal/halx86/hal_generic.rbuild [iso-8859-1] (original) +++ trunk/reactos/hal/halx86/hal_generic.rbuild [iso-8859-1] Sat Mar 19 13:59:23 2011 @@ -21,7 +21,6 @@ <file>usage.c</file> <if property="ARCH" value="i386"> <file>bios.c</file> - <file>halinit.c</file> <directory name="i386"> <file>portio.c</file> <file>systimer.S</file> Modified: trunk/reactos/hal/halx86/hal_generic_acpi.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/hal/halx86/hal_generic_acp…
============================================================================== --- trunk/reactos/hal/halx86/hal_generic_acpi.rbuild [iso-8859-1] (original) +++ trunk/reactos/hal/halx86/hal_generic_acpi.rbuild [iso-8859-1] Sat Mar 19 13:59:23 2011 @@ -18,6 +18,9 @@ <file>pcibus.c</file> </directory> </directory> + <if property="ARCH" value="i386"> + <file>halinit.c</file> + </if> </directory> </module> </group> Modified: trunk/reactos/hal/halx86/hal_generic_pcat.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/hal/halx86/hal_generic_pca…
============================================================================== --- trunk/reactos/hal/halx86/hal_generic_pcat.rbuild [iso-8859-1] (original) +++ trunk/reactos/hal/halx86/hal_generic_pcat.rbuild [iso-8859-1] Sat Mar 19 13:59:23 2011 @@ -19,6 +19,9 @@ <file>bussupp.c</file> <file>halpcat.c</file> </directory> + <if property="ARCH" value="i386"> + <file>halinit.c</file> + </if> </directory> </module> </group>
13 years, 9 months
1
0
0
0
[jimtabor] 51089: [Win32k] - Implement the set of DeferWindowPos functions. Regedit (one of many application) uses it and allocated three when it should be four. This was a good test to verify the ...
by jimtabor@svn.reactos.org
Author: jimtabor Date: Fri Mar 18 22:41:22 2011 New Revision: 51089 URL:
http://svn.reactos.org/svn/reactos?rev=51089&view=rev
Log: [Win32k] - Implement the set of DeferWindowPos functions. Regedit (one of many application) uses it and allocated three when it should be four. This was a good test to verify the batch list growing routine. Instead of drawing per DeferWindowPos call, now a real list is created and run down as a batch. - ReactOS should handle this the correct way and a good test case is located here:
http://bugs.winehq.org/show_bug.cgi?id=23187
- The code is from wine and modified for the use in ReactOS. Modified: trunk/reactos/dll/win32/user32/windows/window.c trunk/reactos/include/reactos/win32k/ntuser.h trunk/reactos/subsystems/win32/win32k/include/winpos.h trunk/reactos/subsystems/win32/win32k/ntuser/ntstubs.c trunk/reactos/subsystems/win32/win32k/ntuser/object.c trunk/reactos/subsystems/win32/win32k/ntuser/simplecall.c trunk/reactos/subsystems/win32/win32k/ntuser/winpos.c Modified: trunk/reactos/dll/win32/user32/windows/window.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/windows/w…
============================================================================== --- trunk/reactos/dll/win32/user32/windows/window.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/user32/windows/window.c [iso-8859-1] Fri Mar 18 22:41:22 2011 @@ -65,17 +65,7 @@ HDWP WINAPI BeginDeferWindowPos(int nNumWindows) { - if (nNumWindows < 0) - { - SetLastError(ERROR_INVALID_PARAMETER); - return 0; - } -#if 0 - UNIMPLEMENTED; - return (HDWP)0; -#else - return (HDWP)1; -#endif + return (HDWP)NtUserCallOneParam((DWORD_PTR)nNumWindows, ONEPARAM_ROUTINE_BEGINDEFERWNDPOS); } @@ -567,12 +557,7 @@ int cy, UINT uFlags) { -#if 0 return NtUserDeferWindowPos(hWinPosInfo, hWnd, hWndInsertAfter, x, y, cx, cy, uFlags); -#else - SetWindowPos(hWnd, hWndInsertAfter, x, y, cx, cy, uFlags); - return hWinPosInfo; -#endif } @@ -582,12 +567,7 @@ BOOL WINAPI EndDeferWindowPos(HDWP hWinPosInfo) { -#if 0 - UNIMPLEMENTED; - return FALSE; -#else - return TRUE; -#endif + return NtUserEndDeferWindowPosEx(hWinPosInfo, 0); } 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] Fri Mar 18 22:41:22 2011 @@ -1631,10 +1631,10 @@ UINT wSBflags, UINT wArrows); -DWORD +BOOL NTAPI NtUserEndDeferWindowPosEx( - DWORD Unknown0, + HDWP WinPosInfo, DWORD Unknown1); BOOL NTAPI Modified: trunk/reactos/subsystems/win32/win32k/include/winpos.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/in…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/include/winpos.h [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/include/winpos.h [iso-8859-1] Fri Mar 18 22:41:22 2011 @@ -1,4 +1,31 @@ #pragma once + +typedef struct _CVR // Tag Ussw +{ + WINDOWPOS pos; + LONG xClientNew; + LONG yClientNew; + LONG cxClientNew; + LONG cyClientNew; + RECT rcBlt; + LONG dxBlt; + LONG dyBlt; + UINT fsRE; + HRGN hrgnVisOld; + PTHREADINFO pti; + HRGN hrgnClip; + HRGN hrgnInterMonitor; +} CVR, *PCVR; + +typedef struct _SMWP +{ + HEAD head; + UINT bShellNotify:1; + UINT bHandle:1; + INT ccvr; + INT ccvrAlloc; + PCVR acvr; +} SMWP, *PSMWP; #define IntPtInWindow(WndObject,x,y) \ ((x) >= (WndObject)->rcWindow.left && \ @@ -36,3 +63,5 @@ VOID FASTCALL WinPosInitInternalPos(PWND WindowObject, POINT *pt, RECTL *RestoreRect); +BOOL FASTCALL IntEndDeferWindowPosEx(HDWP); +HDWP FASTCALL IntDeferWindowPos(HDWP,HWND,HWND,INT,INT,INT,INT,UINT); 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] Fri Mar 18 22:41:22 2011 @@ -1169,18 +1169,6 @@ } /* - * @unimplemented - */ -DWORD APIENTRY -NtUserEndDeferWindowPosEx(DWORD Unknown0, - DWORD Unknown1) -{ - UNIMPLEMENTED - - return 0; -} - -/* * FillWindow: Called from User; Dialog, Edit and ListBox procs during a WM_ERASEBKGND. */ /* @@ -1205,7 +1193,7 @@ { UNIMPLEMENTED - return 0; + return 1; } /* @@ -1306,25 +1294,6 @@ } /* - * @unimplemented - */ -HDWP APIENTRY -NtUserDeferWindowPos(HDWP WinPosInfo, - HWND Wnd, - HWND WndInsertAfter, - int x, - int y, - int cx, - int cy, - UINT Flags) -{ - UNIMPLEMENTED - - return 0; -} - - -/* * NtUserResolveDesktopForWOW * * Status Modified: trunk/reactos/subsystems/win32/win32k/ntuser/object.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/object.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/object.c [iso-8859-1] Fri Mar 18 22:41:22 2011 @@ -177,6 +177,7 @@ case otHook: case otCallProc: case otAccel: + case otSMWP: pi = GetW32ProcessInfo(); break; Modified: trunk/reactos/subsystems/win32/win32k/ntuser/simplecall.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/simplecall.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/simplecall.c [iso-8859-1] Fri Mar 18 22:41:22 2011 @@ -157,6 +157,38 @@ MsqPostQuitMessage(pti->MessageQueue, Param); RETURN(TRUE); } + + case ONEPARAM_ROUTINE_BEGINDEFERWNDPOS: + { + PSMWP psmwp; + HDWP hDwp = NULL; + if (Param < 0) + { + EngSetLastError(ERROR_INVALID_PARAMETER); + RETURN(0); + } + /* Windows allows zero count, in which case it allocates context for 8 moves */ + if (Param == 0) Param = 8; + + psmwp = (PSMWP) UserCreateObject( gHandleTable, + NULL, + (PHANDLE)&hDwp, + otSMWP, + sizeof(SMWP)); + if (!psmwp) RETURN(0); + psmwp->acvr = ExAllocatePoolWithTag(PagedPool, Param * sizeof(CVR), USERTAG_SWP); + if (!psmwp->acvr) + { + UserDeleteObject(hDwp, otSMWP); + RETURN(0); + } + RtlZeroMemory(psmwp->acvr, Param * sizeof(CVR)); + psmwp->bHandle = TRUE; + psmwp->ccvr = 0; // actualCount + psmwp->ccvrAlloc = Param; // suggestedCount + RETURN((DWORD_PTR)hDwp); + } + case ONEPARAM_ROUTINE_SHOWCURSOR: RETURN( (DWORD_PTR)UserShowCursor((BOOL)Param) ); Modified: trunk/reactos/subsystems/win32/win32k/ntuser/winpos.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/winpos.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/winpos.c [iso-8859-1] Fri Mar 18 22:41:22 2011 @@ -1673,6 +1673,204 @@ return Window; } +HDWP +FASTCALL +IntDeferWindowPos( HDWP hdwp, + HWND hwnd, + HWND hwndAfter, + INT x, + INT y, + INT cx, + INT cy, + UINT flags ) +{ + PSMWP pDWP; + int i; + HDWP retvalue = hdwp; + + DPRINT("hdwp %p, hwnd %p, after %p, %d,%d (%dx%d), flags %08x\n", + hdwp, hwnd, hwndAfter, x, y, cx, cy, flags); + + if (flags & ~(SWP_NOSIZE | SWP_NOMOVE | + SWP_NOZORDER | SWP_NOREDRAW | + SWP_NOACTIVATE | SWP_NOCOPYBITS | + SWP_NOOWNERZORDER|SWP_SHOWWINDOW | + SWP_HIDEWINDOW | SWP_FRAMECHANGED)) + { + EngSetLastError(ERROR_INVALID_PARAMETER); + return NULL; + } + + if (!(pDWP = (PSMWP)UserGetObject(gHandleTable, hdwp, otSMWP))) + { + EngSetLastError(ERROR_INVALID_DWP_HANDLE); + return NULL; + } + + for (i = 0; i < pDWP->ccvr; i++) + { + if (pDWP->acvr[i].pos.hwnd == hwnd) + { + /* Merge with the other changes */ + if (!(flags & SWP_NOZORDER)) + { + pDWP->acvr[i].pos.hwndInsertAfter = hwndAfter; + } + if (!(flags & SWP_NOMOVE)) + { + pDWP->acvr[i].pos.x = x; + pDWP->acvr[i].pos.y = y; + } + if (!(flags & SWP_NOSIZE)) + { + pDWP->acvr[i].pos.cx = cx; + pDWP->acvr[i].pos.cy = cy; + } + pDWP->acvr[i].pos.flags &= flags | ~(SWP_NOSIZE | SWP_NOMOVE | + SWP_NOZORDER | SWP_NOREDRAW | + SWP_NOACTIVATE | SWP_NOCOPYBITS| + SWP_NOOWNERZORDER); + pDWP->acvr[i].pos.flags |= flags & (SWP_SHOWWINDOW | SWP_HIDEWINDOW | + SWP_FRAMECHANGED); + goto END; + } + } + if (pDWP->ccvr >= pDWP->ccvrAlloc) + { + PCVR newpos = ExAllocatePoolWithTag(PagedPool, pDWP->ccvrAlloc * 2 * sizeof(CVR), USERTAG_SWP); + if (!newpos) + { + retvalue = NULL; + goto END; + } + RtlZeroMemory(newpos, pDWP->ccvrAlloc * 2 * sizeof(CVR)); + RtlCopyMemory(newpos, pDWP->acvr, pDWP->ccvrAlloc * sizeof(CVR)); + ExFreePoolWithTag(pDWP->acvr, USERTAG_SWP); + pDWP->ccvrAlloc *= 2; + pDWP->acvr = newpos; + } + pDWP->acvr[pDWP->ccvr].pos.hwnd = hwnd; + pDWP->acvr[pDWP->ccvr].pos.hwndInsertAfter = hwndAfter; + pDWP->acvr[pDWP->ccvr].pos.x = x; + pDWP->acvr[pDWP->ccvr].pos.y = y; + pDWP->acvr[pDWP->ccvr].pos.cx = cx; + pDWP->acvr[pDWP->ccvr].pos.cy = cy; + pDWP->acvr[pDWP->ccvr].pos.flags = flags; + pDWP->acvr[pDWP->ccvr].hrgnClip = NULL; + pDWP->acvr[pDWP->ccvr].hrgnInterMonitor = NULL; + pDWP->ccvr++; +END: + return retvalue; +} + +BOOL FASTCALL IntEndDeferWindowPosEx( HDWP hdwp ) +{ + PSMWP pDWP; + PCVR winpos; + BOOL res = TRUE; + int i; + + DPRINT("%p\n", hdwp); + + if (!(pDWP = (PSMWP)UserGetObject(gHandleTable, hdwp, otSMWP))) + { + EngSetLastError(ERROR_INVALID_DWP_HANDLE); + return FALSE; + } + + for (i = 0, winpos = pDWP->acvr; res && i < pDWP->ccvr; i++, winpos++) + { + DPRINT("hwnd %p, after %p, %d,%d (%dx%d), flags %08x\n", + winpos->pos.hwnd, winpos->pos.hwndInsertAfter, winpos->pos.x, winpos->pos.y, + winpos->pos.cx, winpos->pos.cy, winpos->pos.flags); + + res = co_WinPosSetWindowPos( UserGetWindowObject(winpos->pos.hwnd), + winpos->pos.hwndInsertAfter, + winpos->pos.x, + winpos->pos.y, + winpos->pos.cx, + winpos->pos.cy, + winpos->pos.flags); + } + ExFreePoolWithTag(pDWP->acvr, USERTAG_SWP); + UserDeleteObject(hdwp, otSMWP); + return res; +} + +/* + * @implemented + */ +BOOL APIENTRY +NtUserEndDeferWindowPosEx(HDWP WinPosInfo, + DWORD Unknown1) +{ + BOOL Ret; + DPRINT("Enter NtUserEndDeferWindowPosEx\n"); + UserEnterExclusive(); + Ret = IntEndDeferWindowPosEx(WinPosInfo); + DPRINT("Leave NtUserEndDeferWindowPosEx, ret=%i\n", Ret); + UserLeave(); + return Ret; +} + +/* + * @implemented + */ +HDWP APIENTRY +NtUserDeferWindowPos(HDWP WinPosInfo, + HWND Wnd, + HWND WndInsertAfter, + int x, + int y, + int cx, + int cy, + UINT Flags) +{ + PWND pWnd, pWndIA; + HDWP Ret = NULL; + UINT Tmp = ~(SWP_ASYNCWINDOWPOS|SWP_DEFERERASE|SWP_NOSENDCHANGING|SWP_NOREPOSITION| + SWP_NOCOPYBITS|SWP_HIDEWINDOW|SWP_SHOWWINDOW|SWP_FRAMECHANGED| + SWP_NOACTIVATE|SWP_NOREDRAW|SWP_NOZORDER|SWP_NOMOVE|SWP_NOSIZE); + + DPRINT("Enter NtUsereferWindowPos\n"); + UserEnterExclusive(); + + if ( Flags & Tmp ) + { + EngSetLastError(ERROR_INVALID_FLAGS); + goto Exit; + } + + pWnd = UserGetWindowObject(Wnd); + if ( !pWnd || + pWnd == IntGetDesktopWindow() || + pWnd == IntGetMessageWindow() ) + { + goto Exit; + } + + if ( WndInsertAfter && + WndInsertAfter != HWND_BOTTOM && + WndInsertAfter != HWND_TOPMOST && + WndInsertAfter != HWND_NOTOPMOST ) + { + pWndIA = UserGetWindowObject(WndInsertAfter); + if ( !pWndIA || + pWndIA == IntGetDesktopWindow() || + pWndIA == IntGetMessageWindow() ) + { + goto Exit; + } + } + + Ret = IntDeferWindowPos(WinPosInfo, Wnd, WndInsertAfter, x, y, cx, cy, Flags); + +Exit: + DPRINT("Leave NtUserDeferWindowPos, ret=%i\n", Ret); + UserLeave(); + return Ret; +} + BOOL APIENTRY NtUserGetMinMaxInfo(
13 years, 9 months
1
0
0
0
[fireball] 51088: [NTDLL] - Rewrite the very first initialization routine: LdrpInit(). - Rename LdrpInit2() to LdrpInitializeProcess(), and LdrpAttachThread() to LdrpInitializeThread(). Still old c...
by fireball@svn.reactos.org
Author: fireball Date: Fri Mar 18 20:23:18 2011 New Revision: 51088 URL:
http://svn.reactos.org/svn/reactos?rev=51088&view=rev
Log: [NTDLL] - Rewrite the very first initialization routine: LdrpInit(). - Rename LdrpInit2() to LdrpInitializeProcess(), and LdrpAttachThread() to LdrpInitializeThread(). Still old code there. Modified: trunk/reactos/dll/ntdll/include/ntdllp.h trunk/reactos/dll/ntdll/ldr/ldrinit.c trunk/reactos/dll/ntdll/ldr/startup.c trunk/reactos/dll/ntdll/ldr/utils.c Modified: trunk/reactos/dll/ntdll/include/ntdllp.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/ntdll/include/ntdllp.h…
============================================================================== --- trunk/reactos/dll/ntdll/include/ntdllp.h [iso-8859-1] (original) +++ trunk/reactos/dll/ntdll/include/ntdllp.h [iso-8859-1] Fri Mar 18 20:23:18 2011 @@ -27,11 +27,14 @@ /* ldrinit.c */ NTSTATUS NTAPI LdrpRunInitializeRoutines(IN PCONTEXT Context OPTIONAL); +NTSTATUS NTAPI LdrpInitializeThread(IN PCONTEXT Context); NTSTATUS NTAPI LdrpInitializeTls(VOID); NTSTATUS NTAPI LdrpAllocateTls(VOID); VOID NTAPI LdrpFreeTls(VOID); VOID NTAPI LdrpTlsCallback(PVOID BaseAddress, ULONG Reason); BOOLEAN NTAPI LdrpCallDllEntry(PDLLMAIN_FUNC EntryPoint, PVOID BaseAddress, ULONG Reason, PVOID Context); +NTSTATUS NTAPI LdrpInitializeProcess(PCONTEXT Context, PVOID SystemArgument1); + /* ldrpe.c */ NTSTATUS Modified: trunk/reactos/dll/ntdll/ldr/ldrinit.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/ntdll/ldr/ldrinit.c?re…
============================================================================== --- trunk/reactos/dll/ntdll/ldr/ldrinit.c [iso-8859-1] (original) +++ trunk/reactos/dll/ntdll/ldr/ldrinit.c [iso-8859-1] Fri Mar 18 20:23:18 2011 @@ -21,6 +21,7 @@ UNICODE_STRING Wow64OptionsString = RTL_CONSTANT_STRING(L""); BOOLEAN LdrpInLdrInit; +LONG LdrpProcessInitialized; PLDR_DATA_TABLE_ENTRY LdrpImageEntry; PUNICODE_STRING LdrpTopLevelDllBeingLoaded; @@ -38,6 +39,11 @@ RTL_CRITICAL_SECTION LdrpLoaderLock; BOOLEAN ShowSnaps; + +ULONG LdrpFatalHardErrorCount; + +VOID RtlpInitializeVectoredExceptionHandling(VOID); +VOID NTAPI RtlpInitDeferedCriticalSection(VOID); /* FUNCTIONS *****************************************************************/ @@ -832,5 +838,148 @@ TlsVector); } +VOID +NTAPI +LdrpInitFailure(NTSTATUS Status) +{ + ULONG Response; + + /* Print a debug message */ + DPRINT1("LDR: Process initialization failure; NTSTATUS = %08lx\n", Status); + + /* Raise a hard error */ + if (!LdrpFatalHardErrorCount) + { + ZwRaiseHardError(STATUS_APP_INIT_FAILURE, 1, 0, (PULONG_PTR)&Status, OptionOk, &Response); + } +} + +VOID +NTAPI +LdrpInit(PCONTEXT Context, + PVOID SystemArgument1, + PVOID SystemArgument2) +{ + LARGE_INTEGER Timeout; + PTEB Teb = NtCurrentTeb(); + NTSTATUS Status, LoaderStatus = STATUS_SUCCESS; + MEMORY_BASIC_INFORMATION MemoryBasicInfo; + PPEB Peb = NtCurrentPeb(); + + DPRINT("LdrpInit()\n"); + + /* Check if we have a deallocation stack */ + if (!Teb->DeallocationStack) + { + /* We don't, set one */ + Status = NtQueryVirtualMemory(NtCurrentProcess(), + Teb->NtTib.StackLimit, + MemoryBasicInformation, + &MemoryBasicInfo, + sizeof(MEMORY_BASIC_INFORMATION), + NULL); + if (!NT_SUCCESS(Status)) + { + /* Fail */ + LdrpInitFailure(Status); + RtlRaiseStatus(Status); + return; + } + + /* Set the stack */ + Teb->DeallocationStack = MemoryBasicInfo.AllocationBase; + } + + /* Now check if the process is already being initialized */ + while (_InterlockedCompareExchange(&LdrpProcessInitialized, + 1, + 0) == 1) + { + /* Set the timeout to 30 seconds */ + Timeout.QuadPart = Int32x32To64(30, -10000); + + /* Make sure the status hasn't changed */ + while (!LdrpProcessInitialized) + { + /* Do the wait */ + ZwDelayExecution(FALSE, &Timeout); + } + } + + /* Check if we have already setup LDR data */ + if (!Peb->Ldr) + { + /* Setup the Loader Lock */ + Peb->LoaderLock = &LdrpLoaderLock; + + /* Let other code know we're initializing */ + LdrpInLdrInit = TRUE; + + /* Initialize Critical Section Data */ + RtlpInitDeferedCriticalSection(); + + /* Initialize VEH Call lists */ + RtlpInitializeVectoredExceptionHandling(); + + /* Protect with SEH */ + _SEH2_TRY + { + /* Initialize the Process */ + LoaderStatus = LdrpInitializeProcess(Context, + SystemArgument1); + + /* Check for success and if MinimumStackCommit was requested */ + if (NT_SUCCESS(LoaderStatus) && Peb->MinimumStackCommit) + { + /* Enforce the limit */ + //LdrpTouchThreadStack(Peb->MinimumStackCommit); + UNIMPLEMENTED; + } + } + _SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER) + { + /* Fail with the SEH error */ + LoaderStatus = _SEH2_GetExceptionCode(); + } + _SEH2_END; + + /* We're not initializing anymore */ + LdrpInLdrInit = FALSE; + + /* Check if init worked */ + if (NT_SUCCESS(LoaderStatus)) + { + /* Set the process as Initialized */ + _InterlockedIncrement(&LdrpProcessInitialized); + } + } + else + { + /* Loader data is there... is this a fork() ? */ + if(Peb->InheritedAddressSpace) + { + /* Handle the fork() */ + //LoaderStatus = LdrpForkProcess(); + LoaderStatus = STATUS_NOT_IMPLEMENTED; + UNIMPLEMENTED; + } + else + { + /* This is a new thread initializing */ + LdrpInitializeThread(Context); + } + } + + /* All done, test alert the thread */ + NtTestAlert(); + + /* Return */ + if (!NT_SUCCESS(LoaderStatus)) + { + /* Fail */ + LdrpInitFailure(LoaderStatus); + RtlRaiseStatus(LoaderStatus); + } +} /* EOF */ Modified: trunk/reactos/dll/ntdll/ldr/startup.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/ntdll/ldr/startup.c?re…
============================================================================== --- trunk/reactos/dll/ntdll/ldr/startup.c [iso-8859-1] (original) +++ trunk/reactos/dll/ntdll/ldr/startup.c [iso-8859-1] Fri Mar 18 20:23:18 2011 @@ -16,9 +16,6 @@ VOID RtlInitializeHeapManager(VOID); VOID LdrpInitLoader(VOID); -VOID NTAPI RtlpInitDeferedCriticalSection(VOID); -NTSTATUS LdrpAttachThread(VOID); -VOID RtlpInitializeVectoredExceptionHandling(VOID); extern PTEB LdrpTopLevelDllBeingLoadedTeb; /* GLOBALS *******************************************************************/ @@ -27,8 +24,6 @@ static RTL_CRITICAL_SECTION PebLock; static RTL_BITMAP TlsBitMap; static RTL_BITMAP TlsExpansionBitMap; -static volatile BOOLEAN LdrpInitialized = FALSE; -static LONG LdrpInitLock = 0; #define VALUE_BUFFER_SIZE 256 @@ -312,11 +307,10 @@ return FALSE; } -static -VOID -LdrpInit2(PCONTEXT Context, - PVOID SystemArgument1, - PVOID SystemArgument2) +NTSTATUS +NTAPI +LdrpInitializeProcess(PCONTEXT Context, + PVOID SystemArgument1) { PIMAGE_NT_HEADERS NTHeaders; PEPFUNC EntryPoint; @@ -378,9 +372,6 @@ Peb->NumberOfProcessors = SystemInformation.NumberOfProcessors; - /* Initialize Critical Section Data */ - RtlpInitDeferedCriticalSection(); - /* Load execution options */ LoadImageFileExecutionOptions(Peb); @@ -439,9 +430,6 @@ ZwTerminateProcess(NtCurrentProcess(), STATUS_IMAGE_MACHINE_TYPE_MISMATCH_EXE); } - /* initialized vectored exception handling */ - RtlpInitializeVectoredExceptionHandling(); - /* initalize peb lock support */ RtlInitializeCriticalSection(&PebLock); Peb->FastPebLock = &PebLock; @@ -585,37 +573,8 @@ /* Break into debugger */ if (Peb->BeingDebugged) DbgBreakPoint(); + + return STATUS_SUCCESS; } -VOID -NTAPI -LdrpInit(PCONTEXT Context, - PVOID SystemArgument1, - PVOID SystemArgument2) -{ - if (!LdrpInitialized) - { - if (!_InterlockedExchange(&LdrpInitLock, 1)) - { - LdrpInit2(Context, SystemArgument1, SystemArgument2); - LdrpInitialized = TRUE; - } - else - { - LARGE_INTEGER Interval = {{-200000, -1}}; - - do - { - NtDelayExecution(FALSE, &Interval); - } - while (!LdrpInitialized); - } - } - - /* attach the thread */ - RtlEnterCriticalSection(NtCurrentPeb()->LoaderLock); - LdrpAttachThread(); - RtlLeaveCriticalSection(NtCurrentPeb()->LoaderLock); -} - /* EOF */ Modified: trunk/reactos/dll/ntdll/ldr/utils.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/ntdll/ldr/utils.c?rev=…
============================================================================== --- trunk/reactos/dll/ntdll/ldr/utils.c [iso-8859-1] (original) +++ trunk/reactos/dll/ntdll/ldr/utils.c [iso-8859-1] Fri Mar 18 20:23:18 2011 @@ -2664,9 +2664,9 @@ /* * @implemented */ - NTSTATUS -LdrpAttachThread (VOID) +NTAPI +LdrpInitializeThread(IN PCONTEXT Context) { PLIST_ENTRY ModuleListHead; PLIST_ENTRY Entry;
13 years, 9 months
1
0
0
0
[janderwald] 51087: [Y] - Fix argument checking - Close correct handle - Patch by Kuts Alexey - bug 6004
by janderwald@svn.reactos.org
Author: janderwald Date: Fri Mar 18 16:28:21 2011 New Revision: 51087 URL:
http://svn.reactos.org/svn/reactos?rev=51087&view=rev
Log: [Y] - Fix argument checking - Close correct handle - Patch by Kuts Alexey - bug 6004 Modified: trunk/rosapps/applications/cmdutils/y/y.c Modified: trunk/rosapps/applications/cmdutils/y/y.c URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/applications/cmdutils/y/y.…
============================================================================== --- trunk/rosapps/applications/cmdutils/y/y.c [iso-8859-1] (original) +++ trunk/rosapps/applications/cmdutils/y/y.c [iso-8859-1] Fri Mar 18 16:28:21 2011 @@ -53,7 +53,7 @@ hConsoleIn = GetStdHandle(STD_INPUT_HANDLE); hConsoleOut = GetStdHandle(STD_OUTPUT_HANDLE); - if (_tcsncmp (argv[1], _T("/?"), 2) == 0) + if (argc == 2 && _tcsncmp (argv[1], _T("/?"), 2) == 0) { ConOutPuts(_T("copy stdin to stdout and then files to stdout\n" "\n" @@ -115,7 +115,7 @@ } while(FindNextFile(hFind,&FindData)); - FindClose(hFile); + FindClose(hFind); } return 0;
13 years, 9 months
1
0
0
0
← Newer
1
...
10
11
12
13
14
15
16
...
28
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
Results per page:
10
25
50
100
200