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 2009
----- 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
28 participants
483 discussions
Start a n
N
ew thread
[dchapyshev] 39851: - Sync comdlg32 with Wine head
by dchapyshev@svn.reactos.org
Author: dchapyshev Date: Tue Mar 3 12:10:25 2009 New Revision: 39851 URL:
http://svn.reactos.org/svn/reactos?rev=39851&view=rev
Log: - Sync comdlg32 with Wine head Added: trunk/reactos/dll/win32/comdlg32/cdlg_Lt.rc (with props) Modified: trunk/reactos/dll/win32/comdlg32/cdlg.h trunk/reactos/dll/win32/comdlg32/cdlg32.c trunk/reactos/dll/win32/comdlg32/cdlg_Bg.rc trunk/reactos/dll/win32/comdlg32/cdlg_Cs.rc trunk/reactos/dll/win32/comdlg32/cdlg_Da.rc trunk/reactos/dll/win32/comdlg32/cdlg_De.rc trunk/reactos/dll/win32/comdlg32/cdlg_El.rc trunk/reactos/dll/win32/comdlg32/cdlg_En.rc trunk/reactos/dll/win32/comdlg32/cdlg_Eo.rc trunk/reactos/dll/win32/comdlg32/cdlg_Es.rc trunk/reactos/dll/win32/comdlg32/cdlg_Fi.rc trunk/reactos/dll/win32/comdlg32/cdlg_Fr.rc trunk/reactos/dll/win32/comdlg32/cdlg_It.rc trunk/reactos/dll/win32/comdlg32/cdlg_Ja.rc trunk/reactos/dll/win32/comdlg32/cdlg_Ko.rc trunk/reactos/dll/win32/comdlg32/cdlg_Nl.rc trunk/reactos/dll/win32/comdlg32/cdlg_No.rc trunk/reactos/dll/win32/comdlg32/cdlg_Pl.rc trunk/reactos/dll/win32/comdlg32/cdlg_Pt.rc trunk/reactos/dll/win32/comdlg32/cdlg_Ro.rc trunk/reactos/dll/win32/comdlg32/cdlg_Ru.rc trunk/reactos/dll/win32/comdlg32/cdlg_Si.rc trunk/reactos/dll/win32/comdlg32/cdlg_Sk.rc trunk/reactos/dll/win32/comdlg32/cdlg_Sv.rc trunk/reactos/dll/win32/comdlg32/cdlg_Th.rc trunk/reactos/dll/win32/comdlg32/cdlg_Tr.rc trunk/reactos/dll/win32/comdlg32/cdlg_Uk.rc trunk/reactos/dll/win32/comdlg32/cdlg_Zh.rc trunk/reactos/dll/win32/comdlg32/colordlg.c trunk/reactos/dll/win32/comdlg32/filedlg.c trunk/reactos/dll/win32/comdlg32/filedlg31.c trunk/reactos/dll/win32/comdlg32/filedlgbrowser.c trunk/reactos/dll/win32/comdlg32/finddlg32.c trunk/reactos/dll/win32/comdlg32/fontdlg.c trunk/reactos/dll/win32/comdlg32/printdlg.c trunk/reactos/dll/win32/comdlg32/rsrc.rc [This mail would be too long, it was shortened to contain the URLs only.] Modified: trunk/reactos/dll/win32/comdlg32/cdlg.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg.h?…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg32.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg32.…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Bg.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Bg…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Cs.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Cs…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Da.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Da…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_De.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_De…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_El.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_El…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_En.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_En…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Eo.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Eo…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Es.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Es…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Fi.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Fi…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Fr.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Fr…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_It.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_It…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Ja.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Ja…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Ko.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Ko…
Added: trunk/reactos/dll/win32/comdlg32/cdlg_Lt.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Lt…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Nl.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Nl…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_No.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_No…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Pl.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Pl…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Pt.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Pt…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Ro.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Ro…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Ru.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Ru…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Si.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Si…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Sk.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Sk…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Sv.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Sv…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Th.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Th…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Tr.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Tr…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Uk.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Uk…
Modified: trunk/reactos/dll/win32/comdlg32/cdlg_Zh.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/cdlg_Zh…
Modified: trunk/reactos/dll/win32/comdlg32/colordlg.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/colordl…
Modified: trunk/reactos/dll/win32/comdlg32/filedlg.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/filedlg…
Modified: trunk/reactos/dll/win32/comdlg32/filedlg31.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/filedlg…
Modified: trunk/reactos/dll/win32/comdlg32/filedlgbrowser.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/filedlg…
Modified: trunk/reactos/dll/win32/comdlg32/finddlg32.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/finddlg…
Modified: trunk/reactos/dll/win32/comdlg32/fontdlg.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/fontdlg…
Modified: trunk/reactos/dll/win32/comdlg32/printdlg.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/printdl…
Modified: trunk/reactos/dll/win32/comdlg32/rsrc.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comdlg32/rsrc.rc…
15 years, 9 months
1
0
0
0
[dchapyshev] 39850: - Sync comctl32 with Wine head
by dchapyshev@svn.reactos.org
Author: dchapyshev Date: Tue Mar 3 12:09:59 2009 New Revision: 39850 URL:
http://svn.reactos.org/svn/reactos?rev=39850&view=rev
Log: - Sync comctl32 with Wine head Added: trunk/reactos/dll/win32/comctl32/comctl_Lt.rc (with props) Modified: trunk/reactos/dll/win32/comctl32/animate.c trunk/reactos/dll/win32/comctl32/comctl32undoc.c trunk/reactos/dll/win32/comctl32/commctrl.c trunk/reactos/dll/win32/comctl32/flatsb.c trunk/reactos/dll/win32/comctl32/header.c trunk/reactos/dll/win32/comctl32/imagelist.c trunk/reactos/dll/win32/comctl32/listview.c trunk/reactos/dll/win32/comctl32/propsheet.c trunk/reactos/dll/win32/comctl32/rebar.c trunk/reactos/dll/win32/comctl32/rsrc.rc trunk/reactos/dll/win32/comctl32/status.c trunk/reactos/dll/win32/comctl32/syslink.c trunk/reactos/dll/win32/comctl32/tab.c trunk/reactos/dll/win32/comctl32/toolbar.c trunk/reactos/dll/win32/comctl32/tooltips.c trunk/reactos/dll/win32/comctl32/treeview.c trunk/reactos/dll/win32/comctl32/updown.c Modified: trunk/reactos/dll/win32/comctl32/animate.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/animate…
============================================================================== --- trunk/reactos/dll/win32/comctl32/animate.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/animate.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -121,7 +121,7 @@ memset(&mminfo, 0, sizeof(mminfo)); mminfo.fccIOProc = FOURCC_MEM; - mminfo.pchBuffer = (LPSTR)lpAvi; + mminfo.pchBuffer = lpAvi; mminfo.cchBuffer = SizeofResource(hInst, hrsrc); infoPtr->hMMio = mmioOpenW(NULL, &mminfo, MMIO_READ); if (!infoPtr->hMMio) @@ -391,7 +391,7 @@ static DWORD CALLBACK ANIMATE_AnimationThread(LPVOID ptr_) { - ANIMATE_INFO *infoPtr = (ANIMATE_INFO *)ptr_; + ANIMATE_INFO *infoPtr = ptr_; HANDLE event; DWORD timeout; @@ -472,7 +472,7 @@ TRACE("Using an animation thread\n"); infoPtr->hStopEvent = CreateEventW( NULL, TRUE, FALSE, NULL ); infoPtr->hThread = CreateThread(0, 0, ANIMATE_AnimationThread, - (LPVOID)infoPtr, 0, &infoPtr->threadId); + infoPtr, 0, &infoPtr->threadId); if(!infoPtr->hThread) return FALSE; } Modified: trunk/reactos/dll/win32/comctl32/comctl32undoc.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/comctl3…
============================================================================== --- trunk/reactos/dll/win32/comctl32/comctl32undoc.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/comctl32undoc.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -339,7 +339,7 @@ */ void WINAPI FreeMRUList (HANDLE hMRUList) { - LPWINEMRULIST mp = (LPWINEMRULIST)hMRUList; + LPWINEMRULIST mp = hMRUList; UINT i; TRACE("(%p)\n", hMRUList); @@ -380,7 +380,7 @@ INT WINAPI FindMRUData (HANDLE hList, LPCVOID lpData, DWORD cbData, LPINT lpRegNum) { - const WINEMRULIST *mp = (LPWINEMRULIST)hList; + const WINEMRULIST *mp = hList; INT ret; UINT i; LPSTR dataA = NULL; @@ -454,7 +454,7 @@ */ INT WINAPI AddMRUData (HANDLE hList, LPCVOID lpData, DWORD cbData) { - LPWINEMRULIST mp = (LPWINEMRULIST)hList; + LPWINEMRULIST mp = hList; LPWINEMRUITEM witem; INT i, replace; @@ -718,7 +718,7 @@ mp->extview.cbSize, mp->extview.nMaxItems, mp->extview.dwFlags, mp->extview.hKey, debugstr_w(mp->extview.lpszSubKey), mp->extview.lpfnCompare, mp->cursize); - return (HANDLE)mp; + return mp; } /************************************************************************** @@ -830,7 +830,7 @@ INT WINAPI EnumMRUListW (HANDLE hList, INT nItemPos, LPVOID lpBuffer, DWORD nBufferSize) { - const WINEMRULIST *mp = (LPWINEMRULIST) hList; + const WINEMRULIST *mp = hList; const WINEMRUITEM *witem; INT desired, datasize; @@ -855,7 +855,7 @@ INT WINAPI EnumMRUListA (HANDLE hList, INT nItemPos, LPVOID lpBuffer, DWORD nBufferSize) { - const WINEMRULIST *mp = (LPWINEMRULIST) hList; + const WINEMRULIST *mp = hList; LPWINEMRUITEM witem; INT desired, datasize; DWORD lenA; Added: trunk/reactos/dll/win32/comctl32/comctl_Lt.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/comctl_…
============================================================================== --- trunk/reactos/dll/win32/comctl32/comctl_Lt.rc (added) +++ trunk/reactos/dll/win32/comctl32/comctl_Lt.rc [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -1,0 +1,92 @@ +/* + * Copyright 2009 Aurimas FiÅ¡eras <aurimas(a)gmail.com> + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library 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 + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +/* UTF-8 */ +#pragma code_page(65001) + +LANGUAGE LANG_LITHUANIAN, SUBLANG_NEUTRAL + +IDD_PROPSHEET DIALOG DISCARDABLE 0, 0, 220, 140 +STYLE DS_CONTEXTHELP | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE +CAPTION "%s savybÄs" +FONT 8, "MS Shell Dlg" +BEGIN + DEFPUSHBUTTON "Gerai", IDOK,4,122,50,14, WS_TABSTOP | WS_GROUP + PUSHBUTTON "Atsisakyti", IDCANCEL,58,122,50,14 + PUSHBUTTON "&Vykdyti", IDC_APPLY_BUTTON,112,122,50,14,WS_DISABLED + PUSHBUTTON "Žinynas", IDHELP,166,122,50,14,WS_TABSTOP|WS_GROUP + CONTROL "Tab", IDC_TABCONTROL,"SysTabControl32",WS_CLIPSIBLINGS|WS_GROUP|WS_TABSTOP|TCS_MULTILINE,4,4,212,114 +END + + +IDD_WIZARD DIALOG DISCARDABLE 0, 0, 290, 159 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_VISIBLE +CAPTION "Vediklis" +FONT 8, "MS Shell Dlg" +BEGIN + PUSHBUTTON "< &Atgal", IDC_BACK_BUTTON,71,138,50,14 + DEFPUSHBUTTON "&Toliau >", IDC_NEXT_BUTTON,121,138,50,14 + DEFPUSHBUTTON "Baigti", IDC_FINISH_BUTTON,121,138,50,14 + PUSHBUTTON "Atsisakyti", IDCANCEL,178,138,50,14 + PUSHBUTTON "Žinynas", IDHELP,235,138,50,14,WS_GROUP + LTEXT "", IDC_SUNKEN_LINE,7,129,278,1,SS_SUNKEN + CONTROL "Tab", IDC_TABCONTROL,"SysTabControl32",WS_CLIPSIBLINGS | WS_DISABLED,7,7,258,5 + LTEXT "", IDC_SUNKEN_LINEHEADER,0,35,290,1,SS_LEFT | SS_SUNKEN | WS_CHILD | WS_VISIBLE +END + + +IDD_TBCUSTOMIZE DIALOG DISCARDABLE 10, 20, 357, 125 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "Tinkinti mygtukų juostÄ " +FONT 8, "MS Shell Dlg" +BEGIN + DEFPUSHBUTTON "&Užverti", IDCANCEL,308,6,44,14 + PUSHBUTTON "A&tstatyti", IDC_RESET_BTN,308,23,44,14 + PUSHBUTTON "&Žinynas", IDC_HELP_BTN,308,40,44,14 + PUSHBUTTON "P&akelti", IDC_MOVEUP_BTN,308,74,44,14 + PUSHBUTTON "&Nuleisti", IDC_MOVEDN_BTN,308,91,44,14 + LTEXT "P&rieinami mygtukai:", -1,4,5,84,10 + LISTBOX IDC_AVAILBTN_LBOX,4,17,120,100, LBS_NOTIFY | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT | LBS_DISABLENOSCROLL | WS_BORDER | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP + PUSHBUTTON "&PridÄti ->", IDOK, 131, 42, 44, 14 + PUSHBUTTON "<- Å a&linti", IDC_REMOVE_BTN,131,62,44,14 + LTEXT "&Mygtukų juostos turinys:", -1,182,5,84,10 + LISTBOX IDC_TOOLBARBTN_LBOX, 182,17,120,100,LBS_NOTIFY | LBS_OWNERDRAWFIXED | LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT | LBS_DISABLENOSCROLL | WS_BORDER | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP +END + +STRINGTABLE DISCARDABLE +{ + IDS_CLOSE "Užverti" +} + +STRINGTABLE DISCARDABLE +{ + IDM_TODAY "Å iandien:" + IDM_GOTODAY "Eiti į Å¡iandien" +} + +STRINGTABLE DISCARDABLE +{ + IDS_SEPARATOR "Skirtukas" +} + +STRINGTABLE DISCARDABLE +{ + HKY_NONE "Joks" +} + +#pragma code_page(default) Propchange: trunk/reactos/dll/win32/comctl32/comctl_Lt.rc ------------------------------------------------------------------------------ svn:eol-style = native Modified: trunk/reactos/dll/win32/comctl32/commctrl.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/commctr…
============================================================================== --- trunk/reactos/dll/win32/comctl32/commctrl.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/commctrl.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -869,7 +869,7 @@ internalColorMap[2].to = GetSysColor (COLOR_BTNFACE); internalColorMap[3].to = GetSysColor (COLOR_BTNHIGHLIGHT); iMaps = 4; - sysColorMap = (LPCOLORMAP)internalColorMap; + sysColorMap = internalColorMap; } hRsrc = FindResourceW (hInstance, (LPWSTR)idBitmap, (LPWSTR)RT_BITMAP); @@ -1125,7 +1125,7 @@ ERR ("Failed to allocate our Subclassing stack\n"); return FALSE; } - SetPropW (hWnd, COMCTL32_wSubclass, (HANDLE)stack); + SetPropW (hWnd, COMCTL32_wSubclass, stack); /* set window procedure to our own and save the current one */ if (IsWindowUnicode (hWnd)) Modified: trunk/reactos/dll/win32/comctl32/flatsb.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/flatsb.…
============================================================================== --- trunk/reactos/dll/win32/comctl32/flatsb.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/flatsb.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -46,8 +46,6 @@ DWORD dwDummy; /* just to keep the compiler happy ;-) */ } FLATSB_INFO, *LPFLATSB_INFO; -#define FlatSB_GetInfoPtr(hwnd) ((FLATSB_INFO*)GetWindowLongPtrW (hwnd, 0)) - /*********************************************************************** * InitializeFlatSB (COMCTL32.@) @@ -245,7 +243,7 @@ static LRESULT WINAPI FlatSB_WindowProc (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) { - if (!FlatSB_GetInfoPtr(hwnd) && (uMsg != WM_CREATE)) + if (!GetWindowLongPtrW(hwnd, 0) && (uMsg != WM_CREATE)) return DefWindowProcW( hwnd, uMsg, wParam, lParam ); switch (uMsg) Modified: trunk/reactos/dll/win32/comctl32/header.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/header.…
============================================================================== --- trunk/reactos/dll/win32/comctl32/header.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/header.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -405,7 +405,7 @@ } if ((phdi->fmt & HDF_BITMAP) && (phdi->hbm)) { - GetObjectW (phdi->hbm, sizeof(BITMAP), (LPVOID)&bmp); + GetObjectW (phdi->hbm, sizeof(BITMAP), &bmp); bw = bmp.bmWidth + 2 * infoPtr->iMargin; if (!iw) { x = &bx; @@ -903,7 +903,7 @@ if (mask & HDI_TEXT) pvBuffer = Alloc(MAX_HEADER_TEXT_LEN * sizeof(CHAR)); } - dispInfo.pszText = (LPWSTR)pvBuffer; + dispInfo.pszText = pvBuffer; dispInfo.cchTextMax = (pvBuffer!=NULL?MAX_HEADER_TEXT_LEN:0); dispInfo.iItem = iItem; dispInfo.mask = mask; @@ -923,7 +923,7 @@ { if (infoPtr->nNotifyFormat == NFR_UNICODE) { - lpItem->pszText = (LPWSTR)pvBuffer; + lpItem->pszText = pvBuffer; /* the user might have used his own buffer */ if (dispInfo.pszText != lpItem->pszText) Modified: trunk/reactos/dll/win32/comctl32/imagelist.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/imageli…
============================================================================== --- trunk/reactos/dll/win32/comctl32/imagelist.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/imagelist.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -243,7 +243,7 @@ if (!is_valid(himl)) return -1; - if (!GetObjectW(hbmImage, sizeof(BITMAP), (LPVOID)&bmp)) + if (!GetObjectW(hbmImage, sizeof(BITMAP), &bmp)) return -1; nImageCount = bmp.bmWidth / himl->cx; @@ -1730,14 +1730,14 @@ DeleteObject (handle); return NULL; } - ImageList_AddMasked (himl, (HBITMAP)handle, clrMask); + ImageList_AddMasked (himl, handle, clrMask); } else if ((uType == IMAGE_ICON) || (uType == IMAGE_CURSOR)) { ICONINFO ii; BITMAP bmp; GetIconInfo (handle, &ii); - GetObjectW (ii.hbmColor, sizeof(BITMAP), (LPVOID)&bmp); + GetObjectW (ii.hbmColor, sizeof(BITMAP), &bmp); himl = ImageList_Create (bmp.bmWidth, bmp.bmHeight, ILC_MASK | ILC_COLOR, 1, cGrow); if (!himl) { @@ -2196,7 +2196,7 @@ return FALSE; } - if (!GetObjectW(hbmImage, sizeof(BITMAP), (LPVOID)&bmp)) + if (!GetObjectW(hbmImage, sizeof(BITMAP), &bmp)) return FALSE; hdcImage = CreateCompatibleDC (0); @@ -2291,7 +2291,7 @@ return -1; } - ret = GetObjectW (ii.hbmMask, sizeof(BITMAP), (LPVOID)&bmp); + ret = GetObjectW (ii.hbmMask, sizeof(BITMAP), &bmp); if (!ret) { ERR("couldn't get mask bitmap info\n"); if (ii.hbmColor) @@ -2686,7 +2686,7 @@ HDC xdc; BOOL result = FALSE; - if (!GetObjectW(hBitmap, sizeof(BITMAP), (LPVOID)&bm)) + if (!GetObjectW(hBitmap, sizeof(BITMAP), &bm)) return FALSE; bitCount = bm.bmBitsPixel == 1 ? 1 : 24; Modified: trunk/reactos/dll/win32/comctl32/listview.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/listvie…
============================================================================== --- trunk/reactos/dll/win32/comctl32/listview.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/listview.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -106,7 +106,6 @@ * -- LVN_GETINFOTIP * -- LVN_HOTTRACK * -- LVN_MARQUEEBEGIN - * -- LVN_ODFINDITEM * -- LVN_SETDISPINFO * -- NM_HOVER * -- LVN_BEGINRDRAG @@ -1373,7 +1372,7 @@ if (nSubItem == 0 && DPA_GetPtrCount(infoPtr->hdpaColumns) == 0) return &mainItem; assert (nSubItem >= 0 && nSubItem < DPA_GetPtrCount(infoPtr->hdpaColumns)); - return (COLUMN_INFO *)DPA_GetPtr(infoPtr->hdpaColumns, nSubItem); + return DPA_GetPtr(infoPtr->hdpaColumns, nSubItem); } static inline void LISTVIEW_GetHeaderRect(const LISTVIEW_INFO *infoPtr, INT nSubItem, LPRECT lprc) @@ -1530,7 +1529,7 @@ if (!charCode || !keyData) return 0; /* only allow the valid WM_CHARs through */ - if (!isalnum(charCode) && + if (!isalnumW(charCode) && charCode != '.' && charCode != '`' && charCode != '!' && charCode != '@' && charCode != '#' && charCode != '$' && charCode != '%' && charCode != '^' && charCode != '&' && @@ -1574,6 +1573,28 @@ endidx=infoPtr->nItemCount; idx=0; } + + /* Let application handle this for virtual listview */ + if (infoPtr->dwStyle & LVS_OWNERDATA) + { + NMLVFINDITEMW nmlv; + LVFINDINFOW lvfi; + + ZeroMemory(&lvfi, sizeof(lvfi)); + lvfi.flags = (LVFI_WRAP | LVFI_PARTIAL); + infoPtr->szSearchParam[infoPtr->nSearchParamLength] = '\0'; + lvfi.psz = infoPtr->szSearchParam; + nmlv.iStart = idx; + nmlv.lvfi = lvfi; + + nItem = notify_hdr(infoPtr, LVN_ODFINDITEMW, (LPNMHDR)&nmlv.hdr); + + if (nItem != -1) + LISTVIEW_KeySelection(infoPtr, nItem); + + return 0; + } + do { if (idx == infoPtr->nItemCount) { if (endidx == infoPtr->nItemCount || endidx == 0) @@ -2584,8 +2605,8 @@ cmp = 1; else cmp = 0; - - TRACE("range1=%s, range2=%s, cmp=%d\n", debugrange((RANGE*)range1), debugrange((RANGE*)range2), cmp); + + TRACE("range1=%s, range2=%s, cmp=%d\n", debugrange(range1), debugrange(range2), cmp); return cmp; } @@ -4511,10 +4532,11 @@ for (i = infoPtr->nItemCount - 1; i >= 0; i--) { - /* send LVN_DELETEITEM notification, if not suppressed */ - if (!bSuppress) notify_deleteitem(infoPtr, i); if (!(infoPtr->dwStyle & LVS_OWNERDATA)) { + /* send LVN_DELETEITEM notification, if not suppressed + and if it is not a virtual listview */ + if (!bSuppress) notify_deleteitem(infoPtr, i); hdpaSubItems = DPA_GetPtr(infoPtr->hdpaItems, i); for (j = 0; j < DPA_GetPtrCount(hdpaSubItems); j++) { @@ -5074,6 +5096,17 @@ ULONG xdist, ydist, dist, mindist = 0x7fffffff; POINT Position, Destination; LVITEMW lvItem; + + /* Search in virtual listviews should be done by application, not by + listview control, so we just send LVN_ODFINDITEMW and return the result */ + if (infoPtr->dwStyle & LVS_OWNERDATA) + { + NMLVFINDITEMW nmlv; + + nmlv.iStart = nStart; + nmlv.lvfi = *lpFindInfo; + return notify_hdr(infoPtr, LVN_ODFINDITEMW, (LPNMHDR)&nmlv.hdr); + } if (!lpFindInfo || nItem < 0) return -1; @@ -6473,8 +6506,8 @@ */ static INT WINAPI LISTVIEW_InsertCompare( LPVOID first, LPVOID second, LPARAM lParam) { - ITEM_INFO* lv_first = DPA_GetPtr( (HDPA)first, 0 ); - ITEM_INFO* lv_second = DPA_GetPtr( (HDPA)second, 0 ); + ITEM_INFO* lv_first = DPA_GetPtr( first, 0 ); + ITEM_INFO* lv_second = DPA_GetPtr( second, 0 ); INT cmpv = textcmpWT(lv_first->hdr.pszText, lv_second->hdr.pszText, TRUE); /* if we're sorting descending, negate the return value */ @@ -7755,8 +7788,8 @@ static INT WINAPI LISTVIEW_CallBackCompare(LPVOID first, LPVOID second, LPARAM lParam) { LISTVIEW_INFO *infoPtr = (LISTVIEW_INFO *)lParam; - ITEM_INFO* lv_first = DPA_GetPtr( (HDPA)first, 0 ); - ITEM_INFO* lv_second = DPA_GetPtr( (HDPA)second, 0 ); + ITEM_INFO* lv_first = DPA_GetPtr( first, 0 ); + ITEM_INFO* lv_second = DPA_GetPtr( second, 0 ); /* Forward the call to the client defined callback */ return (infoPtr->pfnCompare)( lv_first->lParam , lv_second->lParam, infoPtr->lParamSort ); @@ -8953,6 +8986,7 @@ nmlv.iItem = -1; nmlv.iSubItem = lpnmh->iItem; notify_listview(infoPtr, LVN_COLUMNCLICK, &nmlv); + notify_forward_header(infoPtr, lpnmh); } break; Modified: trunk/reactos/dll/win32/comctl32/propsheet.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/propshe…
============================================================================== --- trunk/reactos/dll/win32/comctl32/propsheet.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/propsheet.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -673,19 +673,15 @@ if( psInfo->unicode ) { ret = (INT_PTR)CreateDialogIndirectParamW(psInfo->ppshheader.hInstance, - (LPDLGTEMPLATEW) temp, - psInfo->ppshheader.hwndParent, - PROPSHEET_DialogProc, - (LPARAM)psInfo); + temp, psInfo->ppshheader.hwndParent, + PROPSHEET_DialogProc, (LPARAM)psInfo); if ( !ret ) ret = -1; } else { ret = (INT_PTR)CreateDialogIndirectParamA(psInfo->ppshheader.hInstance, - (LPDLGTEMPLATEA) temp, - psInfo->ppshheader.hwndParent, - PROPSHEET_DialogProc, - (LPARAM)psInfo); + temp, psInfo->ppshheader.hwndParent, + PROPSHEET_DialogProc, (LPARAM)psInfo); if ( !ret ) ret = -1; } @@ -740,9 +736,10 @@ HWND hwndTabCtrl = GetDlgItem(hwndDlg, IDC_TABCONTROL); HWND hwndButton = GetDlgItem(hwndDlg, IDOK); RECT rc,tabRect; - int tabOffsetX, tabOffsetY, buttonHeight; + int buttonHeight; PADDING_INFO padding = PROPSHEET_GetPaddingInfo(hwndDlg); RECT units; + LONG style; /* Get the height of buttons */ GetClientRect(hwndButton, &rc); @@ -783,9 +780,6 @@ } SendMessageW(hwndTabCtrl, TCM_ADJUSTRECT, TRUE, (LPARAM)&rc); - - tabOffsetX = -(rc.left); - tabOffsetY = -(rc.top); rc.right -= rc.left; rc.bottom -= rc.top; @@ -798,8 +792,15 @@ TRACE("tab client rc %s\n", wine_dbgstr_rect(&rc)); - rc.right += ((padding.x * 2) + tabOffsetX); - rc.bottom += (buttonHeight + (3 * padding.y) + tabOffsetY); + rc.right += (padding.x * 2); + rc.bottom += buttonHeight + (3 * padding.y); + + style = GetWindowLongW(hwndDlg, GWL_STYLE); + if (!(style & WS_CHILD)) + AdjustWindowRect(&rc, style, FALSE); + + rc.right -= rc.left; + rc.bottom -= rc.top; /* * Resize the property sheet. @@ -2439,7 +2440,6 @@ return TRUE; } - /****************************************************************************** * PROPSHEET_SetWizButtons * @@ -2756,7 +2756,7 @@ Free(psInfo->strPropertiesFor); ImageList_Destroy(psInfo->hImageList); - GlobalFree((HGLOBAL)psInfo); + GlobalFree(psInfo); } static INT do_loop(const PropSheetInfo *psInfo) @@ -3268,7 +3268,7 @@ MapWindowPoints(hwndLineHeader, hwnd, (LPPOINT) &r, 2); SetRect(&rzone, 0, 0, r.right + 1, r.top - 1); - GetObjectW(psInfo->ppshheader.u5.hbmHeader, sizeof(BITMAP), (LPVOID)&bm); + GetObjectW(psInfo->ppshheader.u5.hbmHeader, sizeof(BITMAP), &bm); if (psInfo->ppshheader.dwFlags & PSH_WIZARD97_OLD) { @@ -3376,7 +3376,7 @@ hbr = GetSysColorBrush(COLOR_WINDOW); FillRect(hdc, &rzone, hbr); - GetObjectW(psInfo->ppshheader.u4.hbmWatermark, sizeof(BITMAP), (LPVOID)&bm); + GetObjectW(psInfo->ppshheader.u4.hbmWatermark, sizeof(BITMAP), &bm); hbmp = SelectObject(hdcSrc, psInfo->ppshheader.u4.hbmWatermark); /* The watermark is truncated to a width of 164 pixels */ @@ -3431,7 +3431,7 @@ /* Using PropSheetInfoStr to store extra data doesn't match the native * common control: native uses TCM_[GS]ETITEM */ - SetPropW(hwnd, PropSheetInfoStr, (HANDLE)psInfo); + SetPropW(hwnd, PropSheetInfoStr, psInfo); /* * psInfo->hwnd is not being used by WINE code - it exists Modified: trunk/reactos/dll/win32/comctl32/rebar.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/rebar.c…
============================================================================== --- trunk/reactos/dll/win32/comctl32/rebar.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/rebar.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -3469,19 +3469,19 @@ static LRESULT -REBAR_StyleChanged (REBAR_INFO *infoPtr, LPARAM lParam) -{ - STYLESTRUCT *ss = (STYLESTRUCT *)lParam; - +REBAR_StyleChanged (REBAR_INFO *infoPtr, INT nType, const STYLESTRUCT *lpStyle) +{ TRACE("current style=%08x, styleOld=%08x, style being set to=%08x\n", - infoPtr->dwStyle, ss->styleOld, ss->styleNew); - infoPtr->orgStyle = infoPtr->dwStyle = ss->styleNew; - if (GetWindowTheme (infoPtr->hwndSelf)) - infoPtr->dwStyle &= ~WS_BORDER; - /* maybe it should be COMMON_STYLES like in toolbar */ - if ((ss->styleNew ^ ss->styleOld) & CCS_VERT) - REBAR_Layout(infoPtr); - + infoPtr->dwStyle, lpStyle->styleOld, lpStyle->styleNew); + if (nType == GWL_STYLE) + { + infoPtr->orgStyle = infoPtr->dwStyle = lpStyle->styleNew; + if (GetWindowTheme (infoPtr->hwndSelf)) + infoPtr->dwStyle &= ~WS_BORDER; + /* maybe it should be COMMON_STYLES like in toolbar */ + if ((lpStyle->styleNew ^ lpStyle->styleOld) & CCS_VERT) + REBAR_Layout(infoPtr); + } return FALSE; } @@ -3715,7 +3715,7 @@ return REBAR_Size (infoPtr, wParam, lParam); case WM_STYLECHANGED: - return REBAR_StyleChanged (infoPtr, lParam); + return REBAR_StyleChanged (infoPtr, wParam, (LPSTYLESTRUCT)lParam); case WM_THEMECHANGED: return theme_changed (infoPtr); Modified: trunk/reactos/dll/win32/comctl32/rsrc.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/rsrc.rc…
============================================================================== --- trunk/reactos/dll/win32/comctl32/rsrc.rc [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/rsrc.rc [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -102,6 +102,7 @@ #include "comctl_It.rc" #include "comctl_Ja.rc" #include "comctl_Ko.rc" +#include "comctl_Lt.rc" #include "comctl_Nl.rc" #include "comctl_No.rc" #include "comctl_Pl.rc" @@ -109,6 +110,7 @@ #include "comctl_Ro.rc" #include "comctl_Ru.rc" #include "comctl_Si.rc" +#include "comctl_Sk.rc" #include "comctl_Sv.rc" #include "comctl_Th.rc" #include "comctl_Tr.rc" Modified: trunk/reactos/dll/win32/comctl32/status.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/status.…
============================================================================== --- trunk/reactos/dll/win32/comctl32/status.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/status.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -95,7 +95,6 @@ #define HORZ_BORDER 0 #define VERT_BORDER 2 #define HORZ_GAP 2 -#define MIN_PANE_HEIGHT 18 static const WCHAR themeClass[] = { 'S','t','a','t','u','s',0 }; @@ -649,7 +648,9 @@ static BOOL STATUSBAR_SetMinHeight (STATUS_INFO *infoPtr, INT height) { - infoPtr->minHeight = max(height, MIN_PANE_HEIGHT); + DWORD ysize = GetSystemMetrics(SM_CYSIZE); + if (ysize & 1) ysize--; + infoPtr->minHeight = max(height, ysize); infoPtr->height = STATUSBAR_ComputeHeight(infoPtr); /* like native, don't resize the control */ return TRUE; @@ -758,8 +759,6 @@ if (style & SBT_OWNERDRAW) { if (!(oldStyle & SBT_OWNERDRAW)) Free (part->text); - else if (part->text == text) - return TRUE; part->text = (LPWSTR)text; } else { LPWSTR ntext; @@ -921,7 +920,8 @@ infoPtr->horizontalBorder = HORZ_BORDER; infoPtr->verticalBorder = VERT_BORDER; infoPtr->horizontalGap = HORZ_GAP; - infoPtr->minHeight = MIN_PANE_HEIGHT; + infoPtr->minHeight = GetSystemMetrics(SM_CYSIZE); + if (infoPtr->minHeight & 1) infoPtr->minHeight--; STATUSBAR_NotifyFormat(infoPtr, infoPtr->Notify, NF_REQUERY); Modified: trunk/reactos/dll/win32/comctl32/syslink.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/syslink…
============================================================================== --- trunk/reactos/dll/win32/comctl32/syslink.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/syslink.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -602,8 +602,8 @@ * SYSLINK_WrapLine * Tries to wrap a line. */ -static BOOL SYSLINK_WrapLine (HDC hdc, LPWSTR Text, WCHAR BreakChar, int *LineLen, - int nFit, LPSIZE Extent, int Width) +static BOOL SYSLINK_WrapLine (LPWSTR Text, WCHAR BreakChar, int *LineLen, + int nFit, LPSIZE Extent) { WCHAR *Current; @@ -720,7 +720,7 @@ if(n != 0) { - Wrap = SYSLINK_WrapLine(hdc, tx, infoPtr->BreakChar, &LineLen, nFit, &szDim, rc.right - x); + Wrap = SYSLINK_WrapLine(tx, infoPtr->BreakChar, &LineLen, nFit, &szDim); if(LineLen == 0) { @@ -1317,7 +1317,7 @@ * SYSLINK_SetFocus * Handles receiving the input focus. */ -static LRESULT SYSLINK_SetFocus (SYSLINK_INFO *infoPtr, HWND PrevFocusWindow) +static LRESULT SYSLINK_SetFocus (SYSLINK_INFO *infoPtr) { PDOC_ITEM Focus; @@ -1340,7 +1340,7 @@ * SYSLINK_KillFocus * Handles losing the input focus. */ -static LRESULT SYSLINK_KillFocus (SYSLINK_INFO *infoPtr, HWND NewFocusWindow) +static LRESULT SYSLINK_KillFocus (SYSLINK_INFO *infoPtr) { PDOC_ITEM Focus; @@ -1385,7 +1385,7 @@ * SYSLINK_LButtonDown * Handles mouse clicks */ -static LRESULT SYSLINK_LButtonDown (SYSLINK_INFO *infoPtr, DWORD Buttons, const POINT *pt) +static LRESULT SYSLINK_LButtonDown (SYSLINK_INFO *infoPtr, const POINT *pt) { PDOC_ITEM Current, Old; int id; @@ -1411,7 +1411,7 @@ * SYSLINK_LButtonUp * Handles mouse clicks */ -static LRESULT SYSLINK_LButtonUp (SYSLINK_INFO *infoPtr, DWORD Buttons, const POINT *pt) +static LRESULT SYSLINK_LButtonUp (SYSLINK_INFO *infoPtr, const POINT *pt) { if(infoPtr->MouseDownID > -1) { @@ -1601,14 +1601,14 @@ POINT pt; pt.x = (short)LOWORD(lParam); pt.y = (short)HIWORD(lParam); - return SYSLINK_LButtonDown(infoPtr, wParam, &pt); + return SYSLINK_LButtonDown(infoPtr, &pt); } case WM_LBUTTONUP: { POINT pt; pt.x = (short)LOWORD(lParam); pt.y = (short)HIWORD(lParam); - return SYSLINK_LButtonUp(infoPtr, wParam, &pt); + return SYSLINK_LButtonUp(infoPtr, &pt); } case WM_KEYDOWN: @@ -1694,10 +1694,10 @@ return SYSLINK_GetIdealHeight(infoPtr); case WM_SETFOCUS: - return SYSLINK_SetFocus(infoPtr, (HWND)wParam); + return SYSLINK_SetFocus(infoPtr); case WM_KILLFOCUS: - return SYSLINK_KillFocus(infoPtr, (HWND)wParam); + return SYSLINK_KillFocus(infoPtr); case WM_ENABLE: infoPtr->Style &= ~WS_DISABLED; Modified: trunk/reactos/dll/win32/comctl32/tab.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/tab.c?r…
============================================================================== --- trunk/reactos/dll/win32/comctl32/tab.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/tab.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -916,7 +916,7 @@ * This method will handle the notification from the scroll control and * perform the scrolling operation on the tab control. */ -static LRESULT TAB_OnHScroll(TAB_INFO *infoPtr, int nScrollCode, int nPos, HWND hwndScroll) +static LRESULT TAB_OnHScroll(TAB_INFO *infoPtr, int nScrollCode, int nPos) { if(nScrollCode == SB_THUMBPOSITION && nPos != infoPtr->leftmostVisible) { @@ -2936,7 +2936,7 @@ } -static LRESULT TAB_Create (HWND hwnd, WPARAM wParam, LPARAM lParam) +static LRESULT TAB_Create (HWND hwnd, LPARAM lParam) { TAB_INFO *infoPtr; TEXTMETRICW fontMetrics; @@ -3076,7 +3076,7 @@ return 0; } -static LRESULT TAB_NCCalcSize(HWND hwnd, WPARAM wParam, LPARAM lParam) +static LRESULT TAB_NCCalcSize(WPARAM wParam) { if (!wParam) return 0; @@ -3211,7 +3211,7 @@ return TAB_SetFont (infoPtr, (HFONT)wParam); case WM_CREATE: - return TAB_Create (hwnd, wParam, lParam); + return TAB_Create (hwnd, lParam); case WM_NCDESTROY: return TAB_Destroy (infoPtr); @@ -3245,7 +3245,7 @@ return TAB_SetRedraw (infoPtr, (BOOL)wParam); case WM_HSCROLL: - return TAB_OnHScroll(infoPtr, (int)LOWORD(wParam), (int)HIWORD(wParam), (HWND)lParam); + return TAB_OnHScroll(infoPtr, (int)LOWORD(wParam), (int)HIWORD(wParam)); case WM_STYLECHANGED: TAB_SetItemBounds (infoPtr); @@ -3270,7 +3270,7 @@ return TAB_NCHitTest(infoPtr, lParam); case WM_NCCALCSIZE: - return TAB_NCCalcSize(hwnd, wParam, lParam); + return TAB_NCCalcSize(wParam); default: if (uMsg >= WM_USER && uMsg < WM_APP && !COMCTL32_IsReflectedMessage(uMsg)) Modified: trunk/reactos/dll/win32/comctl32/toolbar.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/toolbar…
============================================================================== --- trunk/reactos/dll/win32/comctl32/toolbar.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/toolbar.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -225,6 +225,7 @@ #define TBSTYLE_EX_ALL (TBSTYLE_EX_DRAWDDARROWS | \ TBSTYLE_EX_UNDOC1 | \ TBSTYLE_EX_MIXEDBUTTONS | \ + TBSTYLE_EX_DOUBLEBUFFER | \ TBSTYLE_EX_HIDECLIPPEDBUTTONS) /* all of the CCS_ styles */ @@ -250,6 +251,7 @@ static void TOOLBAR_LayoutToolbar(HWND hwnd); static LRESULT TOOLBAR_AutoSize(HWND hwnd); static void TOOLBAR_CheckImageListIconSize(TOOLBAR_INFO *infoPtr); +static void TOOLBAR_TooltipAddTool(const TOOLBAR_INFO *infoPtr, const TBUTTON_INFO *button); static void TOOLBAR_TooltipSetRect(const TOOLBAR_INFO *infoPtr, const TBUTTON_INFO *button); static LRESULT @@ -275,18 +277,24 @@ } static void -TOOLBAR_DumpButton(const TOOLBAR_INFO *infoPtr, const TBUTTON_INFO *bP, INT btn_num, BOOL internal) +TOOLBAR_DumpTBButton(const TBBUTTON *tbb, BOOL fUnicode) +{ + TRACE("TBBUTTON: id %d, bitmap=%d, state=%02x, style=%02x, data=%08lx, stringid=0x%08lx (%s)\n", + tbb->idCommand,tbb->iBitmap, tbb->fsState, tbb->fsStyle, tbb->dwData, tbb->iString, + (fUnicode ? wine_dbgstr_w((LPWSTR)tbb->iString) : wine_dbgstr_a((LPSTR)tbb->iString))); +} + +static void +TOOLBAR_DumpButton(const TOOLBAR_INFO *infoPtr, const TBUTTON_INFO *bP, INT btn_num) { if (TRACE_ON(toolbar)){ TRACE("button %d id %d, bitmap=%d, state=%02x, style=%02x, data=%08lx, stringid=0x%08lx\n", btn_num, bP->idCommand, GETIBITMAP(infoPtr, bP->iBitmap), bP->fsState, bP->fsStyle, bP->dwData, bP->iString); TRACE("string %s\n", debugstr_w(TOOLBAR_GetText(infoPtr,bP))); - if (internal) - TRACE("button %d id %d, hot=%s, row=%d, rect=(%s)\n", - btn_num, bP->idCommand, - (bP->bHot) ? "TRUE":"FALSE", bP->nRow, - wine_dbgstr_rect(&bP->rect)); + TRACE("button %d id %d, hot=%s, row=%d, rect=(%s)\n", + btn_num, bP->idCommand, (bP->bHot) ? "TRUE":"FALSE", bP->nRow, + wine_dbgstr_rect(&bP->rect)); } } @@ -306,7 +314,7 @@ iP->himlInt, iP->himlDef, iP->himlHot, iP->himlDis, (iP->bDoRedraw) ? "TRUE" : "FALSE"); for(i=0; i<iP->nNumButtons; i++) { - TOOLBAR_DumpButton(iP, &iP->buttons[i], i, TRUE); + TOOLBAR_DumpButton(iP, &iP->buttons[i], i); } } } @@ -1813,6 +1821,62 @@ } +/* worker for TB_ADDBUTTONS and TB_INSERTBUTTON */ +static BOOL +TOOLBAR_InternalInsertButtonsT(TOOLBAR_INFO *infoPtr, INT iIndex, UINT nAddButtons, TBBUTTON *lpTbb, BOOL fUnicode) +{ + INT nOldButtons, nNewButtons, iButton; + BOOL fHasString = FALSE; + + if (iIndex < 0) /* iIndex can be negative, what means adding at the end */ + iIndex = infoPtr->nNumButtons; + + nOldButtons = infoPtr->nNumButtons; + nNewButtons = nOldButtons + nAddButtons; + + infoPtr->buttons = ReAlloc(infoPtr->buttons, sizeof(TBUTTON_INFO)*nNewButtons); + memmove(&infoPtr->buttons[iIndex + nAddButtons], &infoPtr->buttons[iIndex], + (nOldButtons - iIndex) * sizeof(TBUTTON_INFO)); + infoPtr->nNumButtons += nAddButtons; + + /* insert new buttons data */ + for (iButton = 0; iButton < nAddButtons; iButton++) { + TBUTTON_INFO *btnPtr = &infoPtr->buttons[iIndex + iButton]; + + TOOLBAR_DumpTBButton(lpTbb, fUnicode); + + ZeroMemory(btnPtr, sizeof(*btnPtr)); + btnPtr->iBitmap = lpTbb[iButton].iBitmap; + btnPtr->idCommand = lpTbb[iButton].idCommand; + btnPtr->fsState = lpTbb[iButton].fsState; + btnPtr->fsStyle = lpTbb[iButton].fsStyle; + btnPtr->dwData = lpTbb[iButton].dwData; + if(HIWORD(lpTbb[iButton].iString) && lpTbb[iButton].iString != -1) + { + if (fUnicode) + Str_SetPtrW((LPWSTR*)&btnPtr->iString, (LPWSTR)lpTbb[iButton].iString ); + else + Str_SetPtrAtoW((LPWSTR*)&btnPtr->iString, (LPSTR)lpTbb[iButton].iString); + fHasString = TRUE; + } + else + btnPtr->iString = lpTbb[iButton].iString; + + TOOLBAR_TooltipAddTool(infoPtr, btnPtr); + } + + if (infoPtr->nNumStrings > 0 || fHasString) + TOOLBAR_CalcToolbar(infoPtr->hwndSelf); + else + TOOLBAR_LayoutToolbar(infoPtr->hwndSelf); + TOOLBAR_AutoSize(infoPtr->hwndSelf); + + TOOLBAR_DumpToolbar(infoPtr, __LINE__); + InvalidateRect(infoPtr->hwndSelf, NULL, TRUE); + return TRUE; +} + + static INT TOOLBAR_GetButtonIndex (const TOOLBAR_INFO *infoPtr, INT idCommand, BOOL CommandIsIndex) { @@ -2838,52 +2902,11 @@ { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); LPTBBUTTON lpTbb = (LPTBBUTTON)lParam; - INT nOldButtons, nNewButtons, nAddButtons, nCount; - BOOL fHasString = FALSE; + INT nAddButtons = (UINT)wParam; TRACE("adding %ld buttons (unicode=%d)!\n", wParam, fUnicode); - nAddButtons = (UINT)wParam; - nOldButtons = infoPtr->nNumButtons; - nNewButtons = nOldButtons + nAddButtons; - - infoPtr->buttons = ReAlloc(infoPtr->buttons, sizeof(TBUTTON_INFO)*nNewButtons); - infoPtr->nNumButtons = nNewButtons; - - /* insert new button data */ - for (nCount = 0; nCount < nAddButtons; nCount++) { - TBUTTON_INFO *btnPtr = &infoPtr->buttons[nOldButtons+nCount]; - btnPtr->iBitmap = lpTbb[nCount].iBitmap; - btnPtr->idCommand = lpTbb[nCount].idCommand; - btnPtr->fsState = lpTbb[nCount].fsState; - btnPtr->fsStyle = lpTbb[nCount].fsStyle; - btnPtr->dwData = lpTbb[nCount].dwData; - btnPtr->bHot = FALSE; - if(HIWORD(lpTbb[nCount].iString) && lpTbb[nCount].iString != -1) - { - if (fUnicode) - Str_SetPtrW ((LPWSTR*)&btnPtr->iString, (LPWSTR)lpTbb[nCount].iString ); - else - Str_SetPtrAtoW((LPWSTR*)&btnPtr->iString, (LPSTR)lpTbb[nCount].iString); - fHasString = TRUE; - } - else - btnPtr->iString = lpTbb[nCount].iString; - - TOOLBAR_TooltipAddTool(infoPtr, btnPtr); - } - - if (infoPtr->nNumStrings > 0 || fHasString) - TOOLBAR_CalcToolbar(hwnd); - else - TOOLBAR_LayoutToolbar(hwnd); - TOOLBAR_AutoSize (hwnd); - - TOOLBAR_DumpToolbar (infoPtr, __LINE__); - - InvalidateRect(hwnd, NULL, TRUE); - - return TRUE; + return TOOLBAR_InternalInsertButtonsT(infoPtr, -1, nAddButtons, lpTbb, fUnicode); } @@ -3184,9 +3207,7 @@ return FALSE; ret = DialogBoxIndirectParamW ((HINSTANCE)GetWindowLongPtrW(hwnd, GWLP_HINSTANCE), - (LPCDLGTEMPLATEW)template, - hwnd, - TOOLBAR_CustomizeDialogProc, + template, hwnd, TOOLBAR_CustomizeDialogProc, (LPARAM)&custInfo); /* send TBN_ENDADJUST notification */ @@ -3310,7 +3331,7 @@ static inline LRESULT -TOOLBAR_GetBitmapFlags (HWND hwnd) +TOOLBAR_GetBitmapFlags (void) { return (GetDeviceCaps (0, LOGPIXELSX) >= 120) ? TBBF_LARGE : 0; } @@ -3720,7 +3741,7 @@ static inline LRESULT -TOOLBAR_HitTest (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_HitTest (HWND hwnd, LPARAM lParam) { return TOOLBAR_InternalHitTest (hwnd, (LPPOINT)lParam); } @@ -3761,8 +3782,6 @@ if (lpTbb == NULL) return FALSE; - - TOOLBAR_DumpButton(infoPtr, (TBUTTON_INFO *)lpTbb, nIndex, FALSE); if (nIndex == -1) { /* EPP: this seems to be an undocumented call (from my IE4) @@ -3782,45 +3801,14 @@ TRACE("adjust index=%d\n", nIndex); } - infoPtr->nNumButtons++; - infoPtr->buttons = ReAlloc(infoPtr->buttons, sizeof(TBUTTON_INFO) * infoPtr->nNumButtons); - memmove(&infoPtr->buttons[nIndex+1], &infoPtr->buttons[nIndex], - (infoPtr->nNumButtons - nIndex - 1) * sizeof(TBUTTON_INFO)); - - /* insert new button */ - infoPtr->buttons[nIndex].iBitmap = lpTbb->iBitmap; - infoPtr->buttons[nIndex].idCommand = lpTbb->idCommand; - infoPtr->buttons[nIndex].fsState = lpTbb->fsState; - infoPtr->buttons[nIndex].fsStyle = lpTbb->fsStyle; - infoPtr->buttons[nIndex].dwData = lpTbb->dwData; - /* if passed string and not index, then add string */ - if(HIWORD(lpTbb->iString) && lpTbb->iString!=-1) { - if (fUnicode) - Str_SetPtrW((LPWSTR *)&infoPtr->buttons[nIndex].iString, (LPWSTR)lpTbb->iString); - else - Str_SetPtrAtoW((LPWSTR *)&infoPtr->buttons[nIndex].iString, (LPCSTR )lpTbb->iString); - } - else - infoPtr->buttons[nIndex].iString = lpTbb->iString; - - TOOLBAR_TooltipAddTool(infoPtr, &infoPtr->buttons[nIndex]); - - if (infoPtr->nNumStrings > 0) - TOOLBAR_CalcToolbar(hwnd); - else - TOOLBAR_LayoutToolbar(hwnd); - TOOLBAR_AutoSize (hwnd); - - InvalidateRect (hwnd, NULL, TRUE); - - return TRUE; + return TOOLBAR_InternalInsertButtonsT(infoPtr, nIndex, 1, lpTbb, fUnicode); } /* << TOOLBAR_InsertMarkHitTest >> */ static LRESULT -TOOLBAR_IsButtonChecked (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_IsButtonChecked (HWND hwnd, WPARAM wParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); INT nIndex; @@ -3834,7 +3822,7 @@ static LRESULT -TOOLBAR_IsButtonEnabled (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_IsButtonEnabled (HWND hwnd, WPARAM wParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); INT nIndex; @@ -3848,7 +3836,7 @@ static LRESULT -TOOLBAR_IsButtonHidden (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_IsButtonHidden (HWND hwnd, WPARAM wParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); INT nIndex; @@ -3862,7 +3850,7 @@ static LRESULT -TOOLBAR_IsButtonHighlighted (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_IsButtonHighlighted (HWND hwnd, WPARAM wParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); INT nIndex; @@ -3876,7 +3864,7 @@ static LRESULT -TOOLBAR_IsButtonIndeterminate (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_IsButtonIndeterminate (HWND hwnd, WPARAM wParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); INT nIndex; @@ -3890,7 +3878,7 @@ static LRESULT -TOOLBAR_IsButtonPressed (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_IsButtonPressed (HWND hwnd, WPARAM wParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); INT nIndex; @@ -4089,7 +4077,7 @@ /* FIXME: there might still be some confusion her between number of buttons * and number of bitmaps */ static LRESULT -TOOLBAR_ReplaceBitmap (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_ReplaceBitmap (HWND hwnd, LPARAM lParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); LPTBREPLACEBITMAP lpReplace = (LPTBREPLACEBITMAP) lParam; @@ -4168,7 +4156,7 @@ /* helper for TOOLBAR_SaveRestoreW */ static BOOL -TOOLBAR_Save(const TOOLBAR_INFO *infoPtr, const TBSAVEPARAMSW *lpSave) +TOOLBAR_Save(const TBSAVEPARAMSW *lpSave) { FIXME("save to %s %s\n", debugstr_w(lpSave->pszSubKey), debugstr_w(lpSave->pszValueName)); @@ -4308,7 +4296,7 @@ if (lpSave == NULL) return 0; if (wParam) - return TOOLBAR_Save(infoPtr, lpSave); + return TOOLBAR_Save(lpSave); else return TOOLBAR_Restore(infoPtr, lpSave); } @@ -4457,7 +4445,7 @@ /* save the button rect to see if we need to redraw the whole toolbar */ oldBtnRect = btnPtr->rect; - TOOLBAR_CalcToolbar(hwnd); + TOOLBAR_LayoutToolbar(hwnd); if (!EqualRect(&oldBtnRect, &btnPtr->rect)) InvalidateRect(hwnd, NULL, TRUE); @@ -4510,7 +4498,7 @@ /* save the button rect to see if we need to redraw the whole toolbar */ oldBtnRect = btnPtr->rect; - TOOLBAR_CalcToolbar(hwnd); + TOOLBAR_LayoutToolbar(hwnd); if (!EqualRect(&oldBtnRect, &btnPtr->rect)) InvalidateRect(hwnd, NULL, TRUE); @@ -4522,7 +4510,7 @@ static LRESULT -TOOLBAR_SetButtonSize (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_SetButtonSize (HWND hwnd, LPARAM lParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); INT cx = (short)LOWORD(lParam), cy = (short)HIWORD(lParam); @@ -4562,7 +4550,7 @@ static LRESULT -TOOLBAR_SetButtonWidth (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_SetButtonWidth (HWND hwnd, LPARAM lParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); @@ -4655,14 +4643,13 @@ * (MSDN says that this parameter is reserved) */ static LRESULT -TOOLBAR_SetExtendedStyle (HWND hwnd, WPARAM wParam, LPARAM lParam) -{ - TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); - DWORD dwTemp; - - dwTemp = infoPtr->dwExStyle; - infoPtr->dwExStyle &= ~wParam; - infoPtr->dwExStyle |= (DWORD)lParam; +TOOLBAR_SetExtendedStyle (HWND hwnd, LPARAM lParam) +{ + TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); + DWORD dwOldStyle; + + dwOldStyle = infoPtr->dwExStyle; + infoPtr->dwExStyle = (DWORD)lParam; TRACE("new style 0x%08x\n", infoPtr->dwExStyle); @@ -4670,13 +4657,15 @@ FIXME("Unknown Toolbar Extended Style 0x%08x. Please report.\n", (infoPtr->dwExStyle & ~TBSTYLE_EX_ALL)); - TOOLBAR_CalcToolbar (hwnd); + if ((dwOldStyle ^ infoPtr->dwExStyle) & TBSTYLE_EX_MIXEDBUTTONS) + TOOLBAR_CalcToolbar(hwnd); + else + TOOLBAR_LayoutToolbar(hwnd); TOOLBAR_AutoSize(hwnd); - InvalidateRect(hwnd, NULL, TRUE); - return (LRESULT)dwTemp; + return (LRESULT)dwOldStyle; } @@ -4812,7 +4801,7 @@ } TOOLBAR_CalcToolbar(hwnd); if (infoPtr->nButtonWidth < oldButtonWidth) - TOOLBAR_SetButtonSize(hwnd, 0, MAKELONG(oldButtonWidth, infoPtr->nButtonHeight)); + TOOLBAR_SetButtonSize(hwnd, MAKELONG(oldButtonWidth, infoPtr->nButtonHeight)); TRACE("hwnd %p, new himl=%p, id = %d, count=%d, bitmap w=%d, h=%d\n", hwnd, infoPtr->himlDef, id, infoPtr->nNumBitmaps, @@ -4825,7 +4814,7 @@ static LRESULT -TOOLBAR_SetIndent (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_SetIndent (HWND hwnd, WPARAM wParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); @@ -4846,7 +4835,7 @@ static LRESULT -TOOLBAR_SetInsertMark (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_SetInsertMark (HWND hwnd, LPARAM lParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); TBINSERTMARK *lptbim = (TBINSERTMARK*)lParam; @@ -4875,7 +4864,7 @@ static LRESULT -TOOLBAR_SetInsertMarkColor (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_SetInsertMarkColor (HWND hwnd, LPARAM lParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); @@ -4889,7 +4878,7 @@ static LRESULT -TOOLBAR_SetMaxTextRows (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_SetMaxTextRows (HWND hwnd, WPARAM wParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); @@ -4912,7 +4901,7 @@ * See blueprints in comments above TOOLBAR_MeasureButton for more info. */ static LRESULT -TOOLBAR_SetPadding (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_SetPadding (HWND hwnd, LPARAM lParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); DWORD oldPad; @@ -4927,7 +4916,7 @@ static LRESULT -TOOLBAR_SetParent (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_SetParent (HWND hwnd, WPARAM wParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); HWND hwndOldNotify; @@ -5096,7 +5085,7 @@ static LRESULT -TOOLBAR_SetStyle (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_SetStyle (HWND hwnd, LPARAM lParam) { SetWindowLongW(hwnd, GWL_STYLE, lParam); @@ -5117,7 +5106,7 @@ static LRESULT -TOOLBAR_SetUnicodeFormat (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_SetUnicodeFormat (HWND hwnd, WPARAM wParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); BOOL bTemp; @@ -5171,7 +5160,7 @@ infoPtr->iVersion = iVersion; if (infoPtr->iVersion >= 5) - TOOLBAR_SetUnicodeFormat(hwnd, TRUE, 0); + TOOLBAR_SetUnicodeFormat(hwnd, TRUE); return iOldVersion; } @@ -5270,7 +5259,7 @@ /* Sets the toolbar global iListGap parameter which controls the amount of * spacing between the image and the text of buttons for TBSTYLE_LIST * toolbars. */ -static LRESULT TOOLBAR_SetListGap(HWND hwnd, WPARAM wParam, LPARAM lParam) +static LRESULT TOOLBAR_SetListGap(HWND hwnd, WPARAM wParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr(hwnd); @@ -5355,7 +5344,7 @@ static LRESULT -TOOLBAR_Create (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_Create (HWND hwnd, LPARAM lParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); DWORD dwStyle = GetWindowLongW (hwnd, GWL_STYLE); @@ -5412,7 +5401,7 @@ static LRESULT -TOOLBAR_Destroy (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_Destroy (HWND hwnd) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); @@ -5532,7 +5521,7 @@ static LRESULT -TOOLBAR_GetFont (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_GetFont (HWND hwnd) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); @@ -5998,7 +5987,7 @@ } static LRESULT -TOOLBAR_MouseLeave (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_MouseLeave (HWND hwnd) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); @@ -6377,7 +6366,7 @@ static inline LRESULT -TOOLBAR_Notify (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_Notify (HWND hwnd, LPARAM lParam) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); LPNMHDR lpnmh = (LPNMHDR)lParam; @@ -6471,7 +6460,7 @@ static LRESULT -TOOLBAR_SetFocus (HWND hwnd, WPARAM wParam) +TOOLBAR_SetFocus (HWND hwnd) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); @@ -6504,7 +6493,7 @@ } static LRESULT -TOOLBAR_SetRedraw (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_SetRedraw (HWND hwnd, WPARAM wParam) /***************************************************** * * Function; @@ -6533,7 +6522,7 @@ static LRESULT -TOOLBAR_Size (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLBAR_Size (HWND hwnd) { TOOLBAR_INFO *infoPtr = TOOLBAR_GetInfoPtr (hwnd); @@ -6621,7 +6610,7 @@ static LRESULT -TOOLBAR_SysColorChange (HWND hwnd) +TOOLBAR_SysColorChange () { COMCTL32_RefreshSysColors(); @@ -6701,7 +6690,7 @@ return TOOLBAR_GetBitmap (hwnd, wParam); case TB_GETBITMAPFLAGS: - return TOOLBAR_GetBitmapFlags (hwnd); + return TOOLBAR_GetBitmapFlags (); case TB_GETBUTTON: return TOOLBAR_GetButton (hwnd, wParam, lParam); @@ -6784,7 +6773,7 @@ return TOOLBAR_HideButton (hwnd, wParam, lParam); case TB_HITTEST: - return TOOLBAR_HitTest (hwnd, wParam, lParam); + return TOOLBAR_HitTest (hwnd, lParam); case TB_INDETERMINATE: return TOOLBAR_Indeterminate (hwnd, wParam, lParam); @@ -6798,22 +6787,22 @@ /* case TB_INSERTMARKHITTEST: */ /* 4.71 */ case TB_ISBUTTONCHECKED: - return TOOLBAR_IsButtonChecked (hwnd, wParam, lParam); + return TOOLBAR_IsButtonChecked (hwnd, wParam); case TB_ISBUTTONENABLED: - return TOOLBAR_IsButtonEnabled (hwnd, wParam, lParam); + return TOOLBAR_IsButtonEnabled (hwnd, wParam); case TB_ISBUTTONHIDDEN: - return TOOLBAR_IsButtonHidden (hwnd, wParam, lParam); + return TOOLBAR_IsButtonHidden (hwnd, wParam); case TB_ISBUTTONHIGHLIGHTED: - return TOOLBAR_IsButtonHighlighted (hwnd, wParam, lParam); + return TOOLBAR_IsButtonHighlighted (hwnd, wParam); case TB_ISBUTTONINDETERMINATE: - return TOOLBAR_IsButtonIndeterminate (hwnd, wParam, lParam); + return TOOLBAR_IsButtonIndeterminate (hwnd, wParam); case TB_ISBUTTONPRESSED: - return TOOLBAR_IsButtonPressed (hwnd, wParam, lParam); + return TOOLBAR_IsButtonPressed (hwnd, wParam); case TB_LOADIMAGES: return TOOLBAR_LoadImages (hwnd, wParam, lParam); @@ -6832,7 +6821,7 @@ return TOOLBAR_PressButton (hwnd, wParam, lParam); case TB_REPLACEBITMAP: - return TOOLBAR_ReplaceBitmap (hwnd, wParam, lParam); + return TOOLBAR_ReplaceBitmap (hwnd, lParam); case TB_SAVERESTOREA: return TOOLBAR_SaveRestoreA (hwnd, wParam, (LPTBSAVEPARAMSA)lParam); @@ -6853,10 +6842,10 @@ return TOOLBAR_SetButtonInfoW (hwnd, wParam, lParam); case TB_SETBUTTONSIZE: - return TOOLBAR_SetButtonSize (hwnd, wParam, lParam); + return TOOLBAR_SetButtonSize (hwnd, lParam); case TB_SETBUTTONWIDTH: - return TOOLBAR_SetButtonWidth (hwnd, wParam, lParam); + return TOOLBAR_SetButtonWidth (hwnd, lParam); case TB_SETCMDID: return TOOLBAR_SetCmdId (hwnd, wParam, lParam); @@ -6868,7 +6857,7 @@ return TOOLBAR_SetDrawTextFlags (hwnd, wParam, lParam); case TB_SETEXTENDEDSTYLE: - return TOOLBAR_SetExtendedStyle (hwnd, wParam, lParam); + return TOOLBAR_SetExtendedStyle (hwnd, lParam); case TB_SETHOTIMAGELIST: return TOOLBAR_SetHotImageList (hwnd, wParam, lParam); @@ -6880,22 +6869,22 @@ return TOOLBAR_SetImageList (hwnd, wParam, lParam); case TB_SETINDENT: - return TOOLBAR_SetIndent (hwnd, wParam, lParam); + return TOOLBAR_SetIndent (hwnd, wParam); case TB_SETINSERTMARK: - return TOOLBAR_SetInsertMark (hwnd, wParam, lParam); + return TOOLBAR_SetInsertMark (hwnd, lParam); case TB_SETINSERTMARKCOLOR: - return TOOLBAR_SetInsertMarkColor (hwnd, wParam, lParam); + return TOOLBAR_SetInsertMarkColor (hwnd, lParam); case TB_SETMAXTEXTROWS: - return TOOLBAR_SetMaxTextRows (hwnd, wParam, lParam); + return TOOLBAR_SetMaxTextRows (hwnd, wParam); case TB_SETPADDING: - return TOOLBAR_SetPadding (hwnd, wParam, lParam); + return TOOLBAR_SetPadding (hwnd, lParam); case TB_SETPARENT: - return TOOLBAR_SetParent (hwnd, wParam, lParam); + return TOOLBAR_SetParent (hwnd, wParam); case TB_SETROWS: return TOOLBAR_SetRows (hwnd, wParam, lParam); @@ -6904,13 +6893,13 @@ return TOOLBAR_SetState (hwnd, wParam, lParam); case TB_SETSTYLE: - return TOOLBAR_SetStyle (hwnd, wParam, lParam); + return TOOLBAR_SetStyle (hwnd, lParam); case TB_SETTOOLTIPS: return TOOLBAR_SetToolTips (hwnd, wParam, lParam); case TB_SETUNICODEFORMAT: - return TOOLBAR_SetUnicodeFormat (hwnd, wParam, lParam); + return TOOLBAR_SetUnicodeFormat (hwnd, wParam); case TB_UNKWN45D: return TOOLBAR_Unkwn45D(hwnd, wParam, lParam); @@ -6919,7 +6908,7 @@ return TOOLBAR_SetHotItem2 (hwnd, wParam, lParam); case TB_SETLISTGAP: - return TOOLBAR_SetListGap(hwnd, wParam, lParam); + return TOOLBAR_SetListGap(hwnd, wParam); case TB_GETIMAGELISTCOUNT: return TOOLBAR_GetImageListCount(hwnd, wParam, lParam); @@ -6950,16 +6939,16 @@ /* case WM_CHAR: */ case WM_CREATE: - return TOOLBAR_Create (hwnd, wParam, lParam); + return TOOLBAR_Create (hwnd, lParam); case WM_DESTROY: - return TOOLBAR_Destroy (hwnd, wParam, lParam); + return TOOLBAR_Destroy (hwnd); case WM_ERASEBKGND: return TOOLBAR_EraseBackground (hwnd, wParam, lParam); case WM_GETFONT: - return TOOLBAR_GetFont (hwnd, wParam, lParam); + return TOOLBAR_GetFont (hwnd); case WM_KEYDOWN: return TOOLBAR_KeyDown (hwnd, wParam, lParam); @@ -6985,7 +6974,7 @@ return TOOLBAR_MouseMove (hwnd, wParam, lParam); case WM_MOUSELEAVE: - return TOOLBAR_MouseLeave (hwnd, wParam, lParam); + return TOOLBAR_MouseLeave (hwnd); case WM_CAPTURECHANGED: return TOOLBAR_CaptureChanged(hwnd); @@ -7003,7 +6992,7 @@ return TOOLBAR_NCPaint (hwnd, wParam, lParam); case WM_NOTIFY: - return TOOLBAR_Notify (hwnd, wParam, lParam); + return TOOLBAR_Notify (hwnd, lParam); case WM_NOTIFYFORMAT: return TOOLBAR_NotifyFormat (infoPtr, wParam, lParam); @@ -7013,22 +7002,22 @@ return TOOLBAR_Paint (hwnd, wParam); case WM_SETFOCUS: - return TOOLBAR_SetFocus (hwnd, wParam); + return TOOLBAR_SetFocus (hwnd); case WM_SETFONT: return TOOLBAR_SetFont(hwnd, wParam, lParam); case WM_SETREDRAW: - return TOOLBAR_SetRedraw (hwnd, wParam, lParam); + return TOOLBAR_SetRedraw (hwnd, wParam); case WM_SIZE: - return TOOLBAR_Size (hwnd, wParam, lParam); + return TOOLBAR_Size (hwnd); case WM_STYLECHANGED: return TOOLBAR_StyleChanged (hwnd, (INT)wParam, (LPSTYLESTRUCT)lParam); case WM_SYSCOLORCHANGE: - return TOOLBAR_SysColorChange (hwnd); + return TOOLBAR_SysColorChange (); case WM_THEMECHANGED: return theme_changed (hwnd); @@ -7178,7 +7167,7 @@ { int ccht = strlen(nmtba.pszText); if (ccht) - MultiByteToWideChar(CP_ACP, 0, (LPCSTR)nmtba.pszText, -1, + MultiByteToWideChar(CP_ACP, 0, nmtba.pszText, -1, nmtb->pszText, nmtb->cchText); nmtb->tbButton = nmtba.tbButton; Modified: trunk/reactos/dll/win32/comctl32/tooltips.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/tooltip…
============================================================================== --- trunk/reactos/dll/win32/comctl32/tooltips.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/tooltips.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -368,7 +368,7 @@ ttnmdi.hdr.hwndFrom = hwnd; ttnmdi.hdr.idFrom = toolPtr->uId; ttnmdi.hdr.code = TTN_GETDISPINFOA; /* == TTN_NEEDTEXTA */ - ttnmdi.lpszText = (LPSTR)ttnmdi.szText; + ttnmdi.lpszText = ttnmdi.szText; ttnmdi.uFlags = toolPtr->uFlags; ttnmdi.lParam = toolPtr->lParam; @@ -424,7 +424,7 @@ ttnmdi.hdr.hwndFrom = hwnd; ttnmdi.hdr.idFrom = toolPtr->uId; ttnmdi.hdr.code = TTN_GETDISPINFOW; /* == TTN_NEEDTEXTW */ - ttnmdi.lpszText = (LPWSTR)ttnmdi.szText; + ttnmdi.lpszText = ttnmdi.szText; ttnmdi.uFlags = toolPtr->uFlags; ttnmdi.lParam = toolPtr->lParam; @@ -1006,7 +1006,7 @@ static LRESULT -TOOLTIPS_Activate (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_Activate (HWND hwnd, WPARAM wParam) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); @@ -1023,7 +1023,7 @@ static LRESULT -TOOLTIPS_AddToolA (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_AddToolA (HWND hwnd, LPARAM lParam) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); LPTTTOOLINFOA lpToolInfo = (LPTTTOOLINFOA)lParam; @@ -1114,7 +1114,7 @@ static LRESULT -TOOLTIPS_AddToolW (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_AddToolW (HWND hwnd, LPARAM lParam) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); LPTTTOOLINFOW lpToolInfo = (LPTTTOOLINFOW)lParam; @@ -1280,7 +1280,7 @@ } static LRESULT -TOOLTIPS_DelToolA (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_DelToolA (HWND hwnd, LPARAM lParam) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); LPTTTOOLINFOA lpToolInfo = (LPTTTOOLINFOA)lParam; @@ -1302,7 +1302,7 @@ static LRESULT -TOOLTIPS_DelToolW (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_DelToolW (HWND hwnd, LPARAM lParam) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); LPTTTOOLINFOW lpToolInfo = (LPTTTOOLINFOW)lParam; @@ -1451,7 +1451,7 @@ static LRESULT -TOOLTIPS_GetCurrentToolW (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_GetCurrentToolW (HWND hwnd, LPARAM lParam) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); LPTTTOOLINFOW lpToolInfo = (LPTTTOOLINFOW)lParam; @@ -1485,7 +1485,7 @@ static LRESULT -TOOLTIPS_GetDelayTime (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_GetDelayTime (HWND hwnd, WPARAM wParam) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); @@ -1510,7 +1510,7 @@ static LRESULT -TOOLTIPS_GetMargin (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_GetMargin (HWND hwnd, LPARAM lParam) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); LPRECT lpRect = (LPRECT)lParam; @@ -1600,7 +1600,7 @@ static inline LRESULT -TOOLTIPS_GetToolCount (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_GetToolCount (HWND hwnd) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); return infoPtr->uNumTools; @@ -1608,7 +1608,7 @@ static LRESULT -TOOLTIPS_GetToolInfoA (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_GetToolInfoA (HWND hwnd, LPARAM lParam) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); LPTTTOOLINFOA lpToolInfo = (LPTTTOOLINFOA)lParam; @@ -1717,7 +1717,7 @@ static LRESULT -TOOLTIPS_HitTestW (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_HitTestW (HWND hwnd, LPARAM lParam) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); LPTTHITTESTINFOW lptthit = (LPTTHITTESTINFOW)lParam; @@ -1800,7 +1800,7 @@ static inline LRESULT -TOOLTIPS_Pop (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_Pop (HWND hwnd) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); TOOLTIPS_Hide (hwnd, infoPtr); @@ -1918,7 +1918,7 @@ static LRESULT -TOOLTIPS_SetMargin (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_SetMargin (HWND hwnd, LPARAM lParam) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); LPRECT lpRect = (LPRECT)lParam; @@ -1956,7 +1956,7 @@ static inline LRESULT -TOOLTIPS_SetTipTextColor (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_SetTipTextColor (HWND hwnd, WPARAM wParam) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); @@ -2035,7 +2035,7 @@ static LRESULT -TOOLTIPS_SetToolInfoA (HWND hwnd, WPARAM wParam, LPARAM lParam) +TOOLTIPS_SetToolInfoA (HWND hwnd, LPARAM lParam) { TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd); LPTTTOOLINFOA lpToolInfo = (LPTTTOOLINFOA)lParam; @@ -2697,19 +2697,19 @@ switch (uMsg) { case TTM_ACTIVATE: - return TOOLTIPS_Activate (hwnd, wParam, lParam); + return TOOLTIPS_Activate (hwnd, wParam); case TTM_ADDTOOLA: - return TOOLTIPS_AddToolA (hwnd, wParam, lParam); + return TOOLTIPS_AddToolA (hwnd, lParam); case TTM_ADDTOOLW: - return TOOLTIPS_AddToolW (hwnd, wParam, lParam); + return TOOLTIPS_AddToolW (hwnd, lParam); case TTM_DELTOOLA: - return TOOLTIPS_DelToolA (hwnd, wParam, lParam); + return TOOLTIPS_DelToolA (hwnd, lParam); case TTM_DELTOOLW: - return TOOLTIPS_DelToolW (hwnd, wParam, lParam); + return TOOLTIPS_DelToolW (hwnd, lParam); case TTM_ENUMTOOLSA: return TOOLTIPS_EnumToolsA (hwnd, wParam, lParam); @@ -2724,13 +2724,13 @@ return TOOLTIPS_GetCurrentToolA (hwnd, wParam, lParam); case TTM_GETCURRENTTOOLW: - return TOOLTIPS_GetCurrentToolW (hwnd, wParam, lParam); + return TOOLTIPS_GetCurrentToolW (hwnd, lParam); case TTM_GETDELAYTIME: - return TOOLTIPS_GetDelayTime (hwnd, wParam, lParam); + return TOOLTIPS_GetDelayTime (hwnd, wParam); case TTM_GETMARGIN: - return TOOLTIPS_GetMargin (hwnd, wParam, lParam); + return TOOLTIPS_GetMargin (hwnd, lParam); case TTM_GETMAXTIPWIDTH: return TOOLTIPS_GetMaxTipWidth (hwnd, wParam, lParam); @@ -2748,10 +2748,10 @@ return TOOLTIPS_GetTipTextColor (hwnd, wParam, lParam); case TTM_GETTOOLCOUNT: - return TOOLTIPS_GetToolCount (hwnd, wParam, lParam); + return TOOLTIPS_GetToolCount (hwnd); case TTM_GETTOOLINFOA: - return TOOLTIPS_GetToolInfoA (hwnd, wParam, lParam); + return TOOLTIPS_GetToolInfoA (hwnd, lParam); case TTM_GETTOOLINFOW: return TOOLTIPS_GetToolInfoW (hwnd, wParam, lParam); @@ -2760,7 +2760,7 @@ return TOOLTIPS_HitTestA (hwnd, wParam, lParam); case TTM_HITTESTW: - return TOOLTIPS_HitTestW (hwnd, wParam, lParam); + return TOOLTIPS_HitTestW (hwnd, lParam); case TTM_NEWTOOLRECTA: return TOOLTIPS_NewToolRectA (hwnd, wParam, lParam); @@ -2769,7 +2769,7 @@ return TOOLTIPS_NewToolRectW (hwnd, wParam, lParam); case TTM_POP: - return TOOLTIPS_Pop (hwnd, wParam, lParam); + return TOOLTIPS_Pop (hwnd); case TTM_RELAYEVENT: return TOOLTIPS_RelayEvent (hwnd, wParam, lParam); @@ -2778,7 +2778,7 @@ return TOOLTIPS_SetDelayTime (hwnd, wParam, lParam); case TTM_SETMARGIN: - return TOOLTIPS_SetMargin (hwnd, wParam, lParam); + return TOOLTIPS_SetMargin (hwnd, lParam); case TTM_SETMAXTIPWIDTH: return TOOLTIPS_SetMaxTipWidth (hwnd, wParam, lParam); @@ -2787,7 +2787,7 @@ return TOOLTIPS_SetTipBkColor (hwnd, wParam, lParam); case TTM_SETTIPTEXTCOLOR: - return TOOLTIPS_SetTipTextColor (hwnd, wParam, lParam); + return TOOLTIPS_SetTipTextColor (hwnd, wParam); case TTM_SETTITLEA: return TOOLTIPS_SetTitleA (hwnd, wParam, lParam); @@ -2796,7 +2796,7 @@ return TOOLTIPS_SetTitleW (hwnd, wParam, lParam); case TTM_SETTOOLINFOA: - return TOOLTIPS_SetToolInfoA (hwnd, wParam, lParam); + return TOOLTIPS_SetToolInfoA (hwnd, lParam); case TTM_SETTOOLINFOW: return TOOLTIPS_SetToolInfoW (hwnd, wParam, lParam); Modified: trunk/reactos/dll/win32/comctl32/treeview.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/treevie…
============================================================================== --- trunk/reactos/dll/win32/comctl32/treeview.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/treeview.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -1112,7 +1112,7 @@ if (tvItem->mask & TVIF_TEXT) { wineItem->textWidth = 0; /* force width recalculation */ - if (tvItem->pszText != LPSTR_TEXTCALLBACKW) /* covers != TEXTCALLBACKA too */ + if (tvItem->pszText != LPSTR_TEXTCALLBACKW && tvItem->pszText != NULL) /* covers != TEXTCALLBACKA too, and undocumented: pszText of NULL also means TEXTCALLBACK */ { int len; LPWSTR newText; Modified: trunk/reactos/dll/win32/comctl32/updown.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/updown.…
============================================================================== --- trunk/reactos/dll/win32/comctl32/updown.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/comctl32/updown.c [iso-8859-1] Tue Mar 3 12:09:59 2009 @@ -570,7 +570,7 @@ good to break the window proc chain. */ if (!GetPropW(bud, BUDDY_SUPERCLASS_WNDPROC)) { baseWndProc = (WNDPROC)SetWindowLongPtrW(bud, GWLP_WNDPROC, (LPARAM)UPDOWN_Buddy_SubclassProc); - SetPropW(bud, BUDDY_SUPERCLASS_WNDPROC, (HANDLE)baseWndProc); + SetPropW(bud, BUDDY_SUPERCLASS_WNDPROC, baseWndProc); } }
15 years, 9 months
1
0
0
0
[tkreuzer] 39849: Initial version of a gdi font driver for bitmap fonts (.fon / .fnt). It starts to work, but not yet correctly. Glyphs are truncated. Developed on Windows XP.
by tkreuzer@svn.reactos.org
Author: tkreuzer Date: Tue Mar 3 05:42:00 2009 New Revision: 39849 URL:
http://svn.reactos.org/svn/reactos?rev=39849&view=rev
Log: Initial version of a gdi font driver for bitmap fonts (.fon / .fnt). It starts to work, but not yet correctly. Glyphs are truncated. Developed on Windows XP. Added: trunk/reactos/drivers/video/font/ (with props) trunk/reactos/drivers/video/font/bmfd/ (with props) trunk/reactos/drivers/video/font/bmfd/bmfd.h (with props) trunk/reactos/drivers/video/font/bmfd/bmfd.rbuild (with props) trunk/reactos/drivers/video/font/bmfd/enable.c (with props) trunk/reactos/drivers/video/font/bmfd/font.c (with props) trunk/reactos/drivers/video/font/bmfd/glyph.c (with props) trunk/reactos/drivers/video/font/directory.rbuild (with props) Modified: trunk/reactos/drivers/video/directory.rbuild Modified: trunk/reactos/drivers/video/directory.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/directory.rb…
============================================================================== --- trunk/reactos/drivers/video/directory.rbuild [iso-8859-1] (original) +++ trunk/reactos/drivers/video/directory.rbuild [iso-8859-1] Tue Mar 3 05:42:00 2009 @@ -3,6 +3,9 @@ <group xmlns:xi="
http://www.w3.org/2001/XInclude
"> <directory name="displays"> <xi:include href="displays/directory.rbuild" /> +</directory> +<directory name="font"> + <xi:include href="font/directory.rbuild" /> </directory> <directory name="miniport"> <xi:include href="miniport/directory.rbuild" /> Propchange: trunk/reactos/drivers/video/font/ ------------------------------------------------------------------------------ --- bugtraq:logregex (added) +++ bugtraq:logregex Tue Mar 3 05:42:00 2009 @@ -1,0 +1,2 @@ +([Ii]ssue|[Bb]ug)s? #?(\d+)(,? ?#?(\d+))*(,? ?(and |or )?#?(\d+))? +(\d+) Propchange: trunk/reactos/drivers/video/font/ ------------------------------------------------------------------------------ bugtraq:message = See issue #%BUGID% for more details. Propchange: trunk/reactos/drivers/video/font/ ------------------------------------------------------------------------------ bugtraq:url =
http://www.reactos.org/bugzilla/show_bug.cgi?id=%BUGID%
Propchange: trunk/reactos/drivers/video/font/ ------------------------------------------------------------------------------ tsvn:logminsize = 10 Propchange: trunk/reactos/drivers/video/font/bmfd/ ------------------------------------------------------------------------------ svn:mergeinfo = Added: trunk/reactos/drivers/video/font/bmfd/bmfd.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/font/bmfd/bm…
============================================================================== --- trunk/reactos/drivers/video/font/bmfd/bmfd.h (added) +++ trunk/reactos/drivers/video/font/bmfd/bmfd.h [iso-8859-1] Tue Mar 3 05:42:00 2009 @@ -1,0 +1,359 @@ +/* + * PROJECT: ReactOS win32 subsystem + * LICENSE: GPL - See COPYING in the top level directory + * PURPOSE: GDI font driver for bitmap fonts + * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org) + */ + +#include <stdarg.h> +#include <windef.h> +#include <wingdi.h> +#include <winddi.h> + +#if defined(_M_IX86) || defined(_M_AMD64) +/* on x86 and x64, unaligned access is allowed, byteorder is LE */ +#define GETVAL(x) (x) +#else +// FIXME: BE +#define GETVAL(x) \ + sizeof(x) == 1 ? (x) : \ + sizeof(x) == 2 ? (((PCHAR)&(x))[0] + (((PCHAR)&(x))[1] << 8)) : \ + (((PCHAR)&(x))[0] + (((PCHAR)&(x))[1] << 8) + (((PCHAR)&(x))[2] << 16) + \ + (((PCHAR)&(x))[3] << 24)) + +#endif + +#define FDM_MASK \ + FDM_TYPE_CONST_BEARINGS | FDM_TYPE_ZERO_BEARINGS | \ + FDM_TYPE_CHAR_INC_EQUAL_BM_BASE | FDM_TYPE_MAXEXT_EQUAL_BM_SIDE | \ + FDM_TYPE_BM_SIDE_CONST + +#define FM_INFO_MASK \ + FM_INFO_TECH_BITMAP | FM_INFO_1BPP | FM_INFO_INTEGER_WIDTH | \ + FM_INFO_RETURNS_BITMAPS | FM_INFO_RIGHT_HANDED | FM_INFO_INTEGRAL_SCALING |\ + FM_INFO_90DEGREE_ROTATIONS | FM_INFO_OPTICALLY_FIXED_PITCH | FM_INFO_NONNEGATIVE_AC + +#define FLOATL_1 0x3f800000 + +#define TAG_PDEV 'veDP' +#define TAG_GLYPHSET 'GlSt' +#define TAG_IFIMETRICS 'Ifim' +#define TAG_FONTINFO 'Font' + + +/** FON / FNT specific types **************************************************/ + +#define IMAGE_DOS_MAGIC 0x594D // FIXME: hack hack hack + +#include <pshpack1.h> +typedef struct +{ + WORD offset; + WORD length; + WORD flags; + WORD id; + WORD handle; + WORD usage; +} NE_NAMEINFO, *PNE_NAMEINFO; + +#define NE_RSCTYPE_FONT 0x8008 +#define NE_RSCTYPE_FONTDIR 0x8007 +typedef struct +{ + WORD type_id; + WORD count; + DWORD resloader; + NE_NAMEINFO nameinfo[1]; +} NE_TYPEINFO, *PNE_TYPEINFO; + +typedef struct +{ + WORD size_shift; + NE_TYPEINFO typeinfo[1]; +} NE_RESTABLE, *PNE_RESTABLE; + +// Values of dfFlags: +#define DFF_FIXED 0x0001 +#define DFF_PROPORTIONAL 0x0002 +#define DFF_ABCFIXED 0x0004 +#define DFF_ABCPROPORTIONAL 0x0008 +#define DFF_1COLOR 0x0010 +#define DFF_16COLOR 0x0020 +#define DFF_256COLOR 0x0040 +#define DFF_RGBCOLOR 0x0080 + +// see
http://msdn.microsoft.com/en-us/library/ms648014(VS.85).aspx
+typedef struct _FONTDIRENTRY +{ + WORD dfVersion; + DWORD dfSize; + char dfCopyright[60]; + WORD dfType; + WORD dfPoints; + WORD dfVertRes; + WORD dfHorizRes; + WORD dfAscent; + WORD dfInternalLeading; + WORD dfExternalLeading; + BYTE dfItalic; + BYTE dfUnderline; + BYTE dfStrikeOut; + WORD dfWeight; + BYTE dfCharSet; + WORD dfPixWidth; + WORD dfPixHeight; + BYTE dfPitchAndFamily; + WORD dfAvgWidth; + WORD dfMaxWidth; + BYTE dfFirstChar; + BYTE dfLastChar; + BYTE dfDefaultChar; + BYTE dfBreakChar; + WORD dfWidthBytes; + DWORD dfDevice; + DWORD dfFace; + DWORD dfReserved; + char szDeviceName[1]; + char szFaceName[1]; +} FONTDIRENTRY, *PFONTDIRENTRY; + +typedef struct _DIRENTRY +{ + WORD fontOrdinal; + FONTDIRENTRY fde; +} DIRENTRY, *PDIRENTRY; + +typedef struct _FONTGROUPHDR +{ + WORD NumberOfFonts; + DIRENTRY ade[1]; +} FONTGROUPHDR, *PFONTGROUPHDR; + +typedef struct +{ + WORD dfVersion; + DWORD dfSize; + CHAR dfCopyright[60]; + WORD dfType; + WORD dfPoints; + WORD dfVertRes; + WORD dfHorizRes; + WORD dfAscent; + WORD dfInternalLeading; + WORD dfExternalLeading; + BYTE dfItalic; + BYTE dfUnderline; + BYTE dfStrikeOut; + WORD dfWeight; + BYTE dfCharSet; + WORD dfPixWidth; + WORD dfPixHeight; + BYTE dfPitchAndFamily; + WORD dfAvgWidth; + WORD dfMaxWidth; + BYTE dfFirstChar; + BYTE dfLastChar; + BYTE dfDefaultChar; + BYTE dfBreakChar; + WORD dfWidthBytes; + DWORD dfDevice; + DWORD dfFace; + DWORD dfBitsPointer; + DWORD dfBitsOffset; + BYTE dfReserved; + /* Version 3.00: */ + DWORD dfFlags; + WORD dfAspace; + WORD dfBspace; + WORD dfCspace; + DWORD dfColorPointer; + DWORD dfReserved1[4]; + BYTE dfCharTable[1]; +} FONTINFO16, *LPFONTINFO16, *PFONTINFO16; + +typedef struct +{ + WORD geWidth; + WORD geOffset; +} GLYPHENTRY20, *PGLYPHENTRY20; + +typedef struct +{ + WORD geWidth; + DWORD geOffset; +} GLYPHENTRY30, *PGLYPHENTRY30; + +typedef union +{ + GLYPHENTRY20 ge20; + GLYPHENTRY30 ge30; +} GLYPHENTRY, *PGLYPHENTRY; + +#include <poppack.h> + + +/** Driver specific types *****************************************************/ + +typedef enum +{ + FONTTYPE_FON, + FONTTYPE_FNT, +} FONTTYPE; + +typedef struct +{ + PFONTDIRENTRY pFontDirEntry; + PFONTINFO16 pFontInfo; + PBYTE pCharTable; + ULONG cjEntrySize; + ULONG ulVersion; + PCHAR pszFaceName; + PCHAR pszCopyright; + ULONG cGlyphs; + CHAR chFirstChar; + CHAR chLastChar; + WCHAR wcFirstChar; + WCHAR wcLastChar; + WCHAR wcDefaultChar; + WCHAR wcBreakChar; + WORD wPixHeight; + WORD wPixWidth; + WORD wWidthBytes; + WORD wA; + WORD wB; + WORD wC; + WORD wAscent; + WORD wDescent; + FLONG flInfo; +} DRVFACE, *PDRVFACE; + +typedef struct +{ + PVOID pvView; + ULONG_PTR iFile; + PFONTGROUPHDR pFontDir; + FONTTYPE ulFontType; + ULONG cNumFaces; + DRVFACE aface[1]; +} DRVFONT, *PDRVFONT; + +//"Bold Italic Underline Strikeout" +#define MAX_STYLESIZE 35 +typedef struct +{ + IFIMETRICS ifim; + BYTE ajCharSet[16]; + WCHAR wszFamilyName[LF_FACESIZE]; + WCHAR wszFaceName[LF_FACESIZE]; + WCHAR wszStyleName[MAX_STYLESIZE]; +} DRVIFIMETRICS, *PDRVIFIMETRICS; + + +/** Function prototypes *******************************************************/ + +ULONG +DbgPrint(IN PCHAR Format, IN ...); + +static __inline__ +void +DbgBreakPoint(void) +{ + asm volatile ("int $3"); +} + +DHPDEV +APIENTRY +BmfdEnablePDEV( + IN DEVMODEW *pdm, + IN LPWSTR pwszLogAddress, + IN ULONG cPat, + OUT HSURF *phsurfPatterns, + IN ULONG cjCaps, + OUT ULONG *pdevcaps, + IN ULONG cjDevInfo, + OUT DEVINFO *pdi, + IN HDEV hdev, + IN LPWSTR pwszDeviceName, + IN HANDLE hDriver); + +VOID +APIENTRY +BmfdCompletePDEV( + IN DHPDEV dhpdev, + IN HDEV hdev); + +VOID +APIENTRY +BmfdDisablePDEV( + IN DHPDEV dhpdev); + +ULONG_PTR +APIENTRY +BmfdLoadFontFile( + ULONG cFiles, + ULONG_PTR *piFile, + PVOID *ppvView, + ULONG *pcjView, + DESIGNVECTOR *pdv, + ULONG ulLangID, + ULONG ulFastCheckSum); + +BOOL +APIENTRY +BmfdUnloadFontFile( + IN ULONG_PTR iFile); + +LONG +APIENTRY +BmfdQueryFontFile( + ULONG_PTR iFile, + ULONG ulMode, + ULONG cjBuf, + ULONG *pulBuf); + +LONG +APIENTRY +BmfdQueryFontCaps( + ULONG culCaps, + ULONG *pulCaps); + +PVOID +APIENTRY +BmfdQueryFontTree( + DHPDEV dhpdev, + ULONG_PTR iFile, + ULONG iFace, + ULONG iMode, + ULONG_PTR *pid); + +PIFIMETRICS +APIENTRY +BmfdQueryFont( + IN DHPDEV dhpdev, + IN ULONG_PTR iFile, + IN ULONG iFace, + IN ULONG_PTR *pid); + +VOID +APIENTRY +BmfdFree( + PVOID pv, + ULONG_PTR id); + +PFD_GLYPHATTR +APIENTRY +BmfdQueryGlyphAttrs( + FONTOBJ *pfo, + ULONG iMode); + +LONG +APIENTRY +BmfdQueryFontData( + DHPDEV dhpdev, + FONTOBJ *pfo, + ULONG iMode, + HGLYPH hg, + OUT GLYPHDATA *pgd, + PVOID pv, + ULONG cjSize); + Propchange: trunk/reactos/drivers/video/font/bmfd/bmfd.h ------------------------------------------------------------------------------ svn:eol-style = native Added: trunk/reactos/drivers/video/font/bmfd/bmfd.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/font/bmfd/bm…
============================================================================== --- trunk/reactos/drivers/video/font/bmfd/bmfd.rbuild (added) +++ trunk/reactos/drivers/video/font/bmfd/bmfd.rbuild [iso-8859-1] Tue Mar 3 05:42:00 2009 @@ -1,0 +1,9 @@ +<?xml version="1.0"?> +<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd"> +<module name="bmfd" type="kernelmodedriver" entrypoint="FonfdEnableDriver@12" installbase="system32" installname="bmfd.dll" crt="static"> + <library>win32k</library> + <library>libcntpr</library> + <file>enable.c</file> + <file>font.c</file> + <file>glyph.c</file> +</module> Propchange: trunk/reactos/drivers/video/font/bmfd/bmfd.rbuild ------------------------------------------------------------------------------ svn:eol-style = native Added: trunk/reactos/drivers/video/font/bmfd/enable.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/font/bmfd/en…
============================================================================== --- trunk/reactos/drivers/video/font/bmfd/enable.c (added) +++ trunk/reactos/drivers/video/font/bmfd/enable.c [iso-8859-1] Tue Mar 3 05:42:00 2009 @@ -1,0 +1,104 @@ +/* + * PROJECT: ReactOS win32 subsystem + * LICENSE: GPL - See COPYING in the top level directory + * PURPOSE: GDI font driver for bitmap fonts + * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org) + */ + +#include "bmfd.h" + +static DRVFN gadrvfn[] = +{ + {INDEX_DrvEnablePDEV, (PFN)BmfdEnablePDEV}, + {INDEX_DrvCompletePDEV, (PFN)BmfdCompletePDEV}, + {INDEX_DrvDisablePDEV, (PFN)BmfdDisablePDEV}, + {INDEX_DrvLoadFontFile, (PFN)BmfdLoadFontFile}, + {INDEX_DrvUnloadFontFile, (PFN)BmfdUnloadFontFile}, + {INDEX_DrvQueryFontFile, (PFN)BmfdQueryFontFile}, + {INDEX_DrvQueryFontCaps, (PFN)BmfdQueryFontCaps}, + {INDEX_DrvQueryFontTree, (PFN)BmfdQueryFontTree}, + {INDEX_DrvQueryFont, (PFN)BmfdQueryFont}, + {INDEX_DrvFree, (PFN)BmfdFree}, + {INDEX_DrvQueryGlyphAttrs, (PFN)BmfdQueryGlyphAttrs}, + {INDEX_DrvQueryFontData, (PFN)BmfdQueryFontData}, +}; + + +ULONG +DbgPrint(IN PCHAR Format, IN ...) +{ + va_list args; + + va_start(args, Format); + EngDebugPrint("Bmfd: ", (PCHAR)Format, args); + va_end(args); + return 0; +} + + +BOOL +APIENTRY +BmfdEnableDriver( + ULONG iEngineVersion, + ULONG cj, + PDRVENABLEDATA pded) +{ + DbgPrint("BmfdEnableDriver()\n"); + + /* Check parameter */ + if (cj < sizeof(DRVENABLEDATA)) + { + return FALSE; + } + + /* Fill DRVENABLEDATA */ + pded->c = sizeof(gadrvfn) / sizeof(DRVFN); + pded->pdrvfn = gadrvfn; + pded->iDriverVersion = DDI_DRIVER_VERSION_NT5; + + /* Success */ + return TRUE; +} + + +DHPDEV +APIENTRY +BmfdEnablePDEV( + IN DEVMODEW *pdm, + IN LPWSTR pwszLogAddress, + IN ULONG cPat, + OUT HSURF *phsurfPatterns, + IN ULONG cjCaps, + OUT ULONG *pdevcaps, + IN ULONG cjDevInfo, + OUT DEVINFO *pdi, + IN HDEV hdev, + IN LPWSTR pwszDeviceName, + IN HANDLE hDriver) +{ + DbgPrint("BmfdEnablePDEV(hdev=%p)\n", hdev); + + /* Return a dummy DHPDEV */ + return (PVOID)1; +} + + +VOID +APIENTRY +BmfdCompletePDEV( + IN DHPDEV dhpdev, + IN HDEV hdev) +{ + DbgPrint("BmfdCompletePDEV()\n"); + /* Nothing to do */ +} + + +VOID +APIENTRY +BmfdDisablePDEV( + IN DHPDEV dhpdev) +{ + DbgPrint("BmfdDisablePDEV()\n"); + /* Nothing to do */ +} Propchange: trunk/reactos/drivers/video/font/bmfd/enable.c ------------------------------------------------------------------------------ svn:eol-style = native Added: trunk/reactos/drivers/video/font/bmfd/font.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/font/bmfd/fo…
============================================================================== --- trunk/reactos/drivers/video/font/bmfd/font.c (added) +++ trunk/reactos/drivers/video/font/bmfd/font.c [iso-8859-1] Tue Mar 3 05:42:00 2009 @@ -1,0 +1,682 @@ +/* + * PROJECT: ReactOS win32 subsystem + * LICENSE: GPL - See COPYING in the top level directory + * PURPOSE: GDI font driver for bitmap fonts + * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org) + */ + +#include "bmfd.h" + +static +BOOLEAN +IsValidPtr( + PVOID p, + ULONG cjSize, + PVOID pStart, + PVOID pEnd, + ULONG cjAlign) +{ + if ((ULONG_PTR)p < (ULONG_PTR)pStart || + (ULONG_PTR)p + cjSize >= (ULONG_PTR)pEnd || + (ULONG_PTR)p & (cjAlign -1)) + { + return FALSE; + } + return TRUE; +} + +static +BOOL +FillFaceInfo( + PDRVFACE pface, + PFONTINFO16 pFontInfo) +{ + CHAR ansi[4]; + WCHAR unicode[4]; + ULONG written; + DWORD dfFlags; + + pface->pFontInfo = pFontInfo; + pface->ulVersion = GETVAL(pFontInfo->dfVersion); + pface->cGlyphs = pFontInfo->dfLastChar - pFontInfo->dfFirstChar + 1; + + /* Convert chars to unicode */ + ansi[0] = pFontInfo->dfFirstChar; + ansi[1] = pFontInfo->dfLastChar; + ansi[2] = pFontInfo->dfFirstChar + pFontInfo->dfDefaultChar; + ansi[3] = pFontInfo->dfFirstChar + pFontInfo->dfBreakChar; + EngMultiByteToUnicodeN(unicode, 4 * sizeof(WCHAR), &written, ansi, 4); + pface->wcFirstChar = unicode[0]; + pface->wcLastChar = unicode[1]; + pface->wcDefaultChar = unicode[2]; + pface->wcBreakChar = unicode[3]; + + /* Copy some values */ + pface->wPixHeight = GETVAL(pFontInfo->dfPixHeight); + pface->wPixWidth = GETVAL(pFontInfo->dfPixWidth); + pface->wWidthBytes = GETVAL(pFontInfo->dfWidthBytes); + pface->wAscent = GETVAL(pFontInfo->dfAscent); + pface->wDescent = pface->wPixHeight - pface->wAscent; + + /* Some version specific members */ + if (pface->ulVersion >= 0x300) + { + dfFlags = GETVAL(pFontInfo->dfFlags); + pface->wA = GETVAL(pFontInfo->dfAspace); + pface->wB = GETVAL(pFontInfo->dfBspace); + pface->wC = GETVAL(pFontInfo->dfCspace); + pface->pCharTable = pface->pFontInfo->dfCharTable; + pface->cjEntrySize = sizeof(GLYPHENTRY30); + } + else + { + dfFlags = DFF_1COLOR; + pface->wA = 0; + pface->wB = 0; + pface->wC = 0; + pface->pCharTable = &pface->pFontInfo->dfReserved + 1; + pface->cjEntrySize = sizeof(GLYPHENTRY20); + } + + pface->flInfo = FM_INFO_MASK; + + /* If dfWidth is non-null, we have a fixed width font */ + if (dfFlags & DFF_FIXED || pface->wPixWidth) + pface->flInfo |= FM_INFO_CONSTANT_WIDTH; + + /* Initialize color depth flags */ + if (dfFlags & DFF_1COLOR) + pface->flInfo |= FM_INFO_1BPP; + else if (dfFlags & DFF_16COLOR) + pface->flInfo |= FM_INFO_4BPP; + else if (dfFlags & DFF_256COLOR) + pface->flInfo |= FM_INFO_8BPP; + else if (dfFlags & DFF_RGBCOLOR) + pface->flInfo |= FM_INFO_24BPP; + + // TODO: walk through all glyphs and veryfy them and calculate max values + + // FIXME: After this point, the whole font data should be verified! + + return TRUE; +} + +static +PVOID +ParseFntFile( + PVOID pvView, + ULONG cjView) +{ + /* unimplemented */ + return NULL; +} + + +static +PVOID +ParseFonFile( + PVOID pvView, + ULONG cjView) +{ + PIMAGE_DOS_HEADER pDosHeader = pvView; + PIMAGE_OS2_HEADER pOs2Header; + PNE_RESTABLE pResTable; + PNE_TYPEINFO pTInfo; + PFONTINFO16 pFontInfo; + PCHAR pStart, pEnd; + PDRVFONT pfont = NULL; + WORD wShift; + ULONG i, cjOffset, cjLength; + ULONG type_id, count; + + /* Initial margins for valid pointers */ + pStart = pvView; + pEnd = pStart + cjView; + + /* Check for image dos header */ + if (GETVAL(pDosHeader->e_magic) != IMAGE_DOS_MAGIC) + { + return NULL; + } + + /* Get pointer to OS2 header and veryfy it is valid */ + pOs2Header = (PVOID)((PCHAR)pDosHeader + GETVAL(pDosHeader->e_lfanew)); + pStart += sizeof(IMAGE_DOS_HEADER); + if (!IsValidPtr(pOs2Header, sizeof(IMAGE_OS2_HEADER), pStart, pEnd, 4)) + { + DbgPrint("e_lfanew is invalid: 0x%lx\n", pDosHeader->e_lfanew); + return NULL; + } + + /* Get pointer to resource table and verify it is valid */ + pResTable = (PVOID)((PCHAR)pOs2Header + GETVAL(pOs2Header->ne_rsrctab)); + pStart = (PCHAR)pOs2Header; + if (!IsValidPtr(pResTable, sizeof(NE_RESTABLE), pStart, pEnd, 1)) + { + DbgPrint("pTInfo is invalid: 0x%p\n", pResTable); + return NULL; + } + + wShift = GETVAL(pResTable->size_shift); + pTInfo = pResTable->typeinfo; + type_id = GETVAL(pTInfo->type_id); + + /* Loop the resource table to find a font resource */ + while (type_id) + { + /* Get number of nameinfo entries */ + count = GETVAL(pTInfo->count); + + /* Look for a font resource */ + if (type_id == NE_RSCTYPE_FONT && count > 0) + { + DbgPrint("Found NE_RSCTYPE_FONT\n"); + + /* Allocate an info structure for this font and all faces */ + cjLength = sizeof(DRVFONT) + (count-1) * sizeof(DRVFACE); + pfont = EngAllocMem(0, cjLength, TAG_FONTINFO); + if (!pfont) + { + DbgPrint("Not enough memory: %ld\n", cjLength); + return NULL; + } + + pfont->cNumFaces = count; + + /* Fill all face info structures */ + for (i = 0; i < count; i++) + { + cjOffset = GETVAL(pTInfo->nameinfo[i].offset) << wShift; + cjLength = GETVAL(pTInfo->nameinfo[i].length) << wShift; + pFontInfo = (PVOID)((PCHAR)pDosHeader + cjOffset); + + if (!IsValidPtr(pFontInfo, cjLength, pStart, pEnd, 1)) + { + DbgPrint("pFontInfo is invalid: 0x%p\n", pFontInfo); + EngFreeMem(pfont); + return NULL; + } + + /* Validate FONTINFO and fill face info */ + if (!FillFaceInfo(&pfont->aface[i], pFontInfo)) + { + DbgPrint("pFontInfo is invalid: 0x%p\n", pFontInfo); + EngFreeMem(pfont); + return NULL; + } + } + + /* Break out of the loop */ + break; + } + + /* Following pointers must be bigger than this */ + pStart = (PCHAR)pTInfo; + + /* Goto next entry in resource table */ + pTInfo = (PVOID)&pTInfo->nameinfo[count]; + + /* Verify that the new pTInfo pointer is valid */ + if (!IsValidPtr(pTInfo, sizeof(NE_TYPEINFO), pStart, pEnd, 1)) + { + DbgPrint("pTInfo is invalid: 0x%p\n", pTInfo); + return NULL; + } + + type_id = GETVAL(pTInfo->type_id); + } + + return pfont; +} + +/** Public Interface **********************************************************/ + +ULONG_PTR +APIENTRY +BmfdLoadFontFile( + ULONG cFiles, + ULONG_PTR *piFile, + PVOID *ppvView, + ULONG *pcjView, + DESIGNVECTOR *pdv, + ULONG ulLangID, + ULONG ulFastCheckSum) +{ + PDRVFONT pfont = NULL; + PVOID pvView; + ULONG cjView; + + DbgPrint("BmfdLoadFontFile()\n"); + DbgBreakPoint(); + + /* Check parameters */ + if (cFiles != 1) + { + DbgPrint("Only 1 File is allowed, got %ld!\n", cFiles); + return HFF_INVALID; + } + + /* Map the font file */ + if (!EngMapFontFileFD(*piFile, (PULONG*)&pvView, &cjView)) + { + DbgPrint("Could not map font file!\n", cFiles); + return HFF_INVALID; + } + + DbgPrint("mapped font file to %p, site if %ld\n", pvView, cjView); + + /* Try to parse a .fon file */ + pfont = ParseFonFile(pvView, cjView); + + if (!pfont) + { + /* Could be a .fnt file */ + pfont = ParseFntFile(pvView, cjView); + } + + /* Check whether we succeeded finding a font */ + if (!pfont) + { + DbgPrint("No font data found\n"); + + /* Unmap the file */ + EngUnmapFontFileFD(*piFile); + + /* Failure! */ + return HFF_INVALID; + } + + pfont->iFile = *piFile; + pfont->pvView = pvView; + + /* Success, return the pointer to font info structure */ + return (ULONG_PTR)pfont; +} + +BOOL +APIENTRY +BmfdUnloadFontFile( + IN ULONG_PTR iFile) +{ + PDRVFONT pfont = (PDRVFONT)iFile; + + DbgPrint("BmfdUnloadFontFile()\n"); + + /* Free the memory that was allocated for the font */ + EngFreeMem(pfont); + + /* Unmap the font file */ + EngUnmapFontFileFD(pfont->iFile); + + return TRUE; +} + + +LONG +APIENTRY +BmfdQueryFontFile( + ULONG_PTR iFile, + ULONG ulMode, + ULONG cjBuf, + ULONG *pulBuf) +{ + PDRVFONT pfont = (PDRVFONT)iFile; + + DbgPrint("BmfdQueryFontFile()\n"); +// DbgBreakPoint(); + + switch (ulMode) + { + case QFF_DESCRIPTION: + { + /* We copy the face name of the 1st face */ + PCHAR pDesc = pfont->aface[0].pszFaceName; + ULONG cOutSize; + if (pulBuf) + { + EngMultiByteToUnicodeN((LPWSTR)pulBuf, + cjBuf, + &cOutSize, + pDesc, + strnlen(pDesc, LF_FACESIZE)); + } + else + { + cOutSize = (strnlen(pDesc, LF_FACESIZE) + 1) * sizeof(WCHAR); + } + return cOutSize; + } + + case QFF_NUMFACES: + /* return the number of faces in the file */ + return pfont->cNumFaces; + + default: + return FD_ERROR; + } +} + +LONG +APIENTRY +BmfdQueryFontCaps( + ULONG culCaps, + ULONG *pulCaps) +{ + DbgPrint("BmfdQueryFontCaps()\n"); + + /* We need room for 2 ULONGs */ + if (culCaps < 2) + { + return FD_ERROR; + } + + /* We only support 1 bpp */ + pulCaps[0] = 2; + pulCaps[1] = QC_1BIT; + + return 2; +} + + +PVOID +APIENTRY +BmfdQueryFontTree( + DHPDEV dhpdev, + ULONG_PTR iFile, + ULONG iFace, + ULONG iMode, + ULONG_PTR *pid) +{ + PDRVFONT pfont = (PDRVFONT)iFile; + PDRVFACE pface; + ULONG i, j, cjOffset, cjSize, cGlyphs, cRuns; + CHAR ch, chFirst, ach[256]; + WCHAR wc, awc[256]; + PFD_GLYPHSET pGlyphSet; + WCRUN *pwcrun; + HGLYPH * phglyphs; + + DbgPrint("DrvQueryFontTree(iMode=%ld)\n", iMode); + DbgBreakPoint(); + + /* Check parameters, we only support QFT_GLYPHSET */ + if (!iFace || iFace > pfont->cNumFaces || iMode != QFT_GLYPHSET) + { + DbgPrint("iFace = %ld, cNumFaces = %ld\n", iFace, pfont->cNumFaces); + return NULL; + } + + /* Get a pointer to the face data */ + pface = &pfont->aface[iFace - 1]; + + /* Get the number of characters in the face */ + cGlyphs = pface->cGlyphs; + + chFirst = pface->pFontInfo->dfFirstChar; + + /* Build array of supported chars */ + for (i = 0; i < cGlyphs; i++) + { + ach[i] = chFirst + i; + } + + /* Convert the chars to unicode */ + EngMultiByteToUnicodeN(awc, sizeof(awc), NULL, ach, cGlyphs); + + /* Sort both arrays in wchar order */ + for (i = 0; i < cGlyphs - 1; i++) + { + wc = awc[i]; + for (j = i + 1; j < cGlyphs; j++) + { + if (awc[j] < wc) + { + awc[i] = awc[j]; + awc[j] = wc; + wc = awc[i]; + ch = ach[i]; + ach[i] = ach[j]; + ach[j] = ch; + } + } + } + + /* Find number of WCRUNs */ + cRuns = 1; + for (i = 1; i < cGlyphs; i++) + { + if (awc[i] != awc[i - 1] + 1) + { + cRuns++; + } + } + + /* Calculate FD_GLYPHSET size */ + cjSize = sizeof(FD_GLYPHSET) + + (cRuns - 1) * sizeof(WCRUN) + + cGlyphs * sizeof(HGLYPH); + + /* Allocate the FD_GLYPHSET structure */ + pGlyphSet = EngAllocMem(0, cjSize, TAG_GLYPHSET); + if (!pGlyphSet) + { + return NULL; + } + + /* Initialize FD_GLYPHSET */ + pGlyphSet->cjThis = cjSize; + pGlyphSet->flAccel = 0; + pGlyphSet->cGlyphsSupported = cGlyphs; + pGlyphSet->cRuns = cRuns; + + /* Initialize 1st WCRUN */ + pwcrun = pGlyphSet->awcrun; + phglyphs = (PHGLYPH)&pGlyphSet->awcrun[cRuns]; + pwcrun[0].wcLow = awc[0]; + pwcrun[0].cGlyphs = 1; + pwcrun[0].phg = phglyphs; + phglyphs[0] = (HGLYPH)pface->pCharTable; + + /* Walk through all supported chars */ + for (i = 1, j = 0; i < cGlyphs; i++) + { + /* Use pointer to glyph entry as hglyph */ + cjOffset = (ach[i] - chFirst) * pface->cjEntrySize; + phglyphs[i] = (HGLYPH)pface->pCharTable + cjOffset; + + /* Check whether we can append the wchar to a run */ + if (awc[i] == awc[i - 1] + 1) + { + /* Append to current WCRUN */ + pwcrun[j].cGlyphs++; + } + else + { + /* Add a new WCRUN */ + j++; + pwcrun[j].wcLow = awc[i]; + pwcrun[j].cGlyphs = 1; + pwcrun[j].phg = &phglyphs[i]; + } + } + + /* Set *pid to the allocated structure for use in BmfdFree */ + *pid = (ULONG_PTR)pGlyphSet; + + return pGlyphSet; +} + +PIFIMETRICS +APIENTRY +BmfdQueryFont( + IN DHPDEV dhpdev, + IN ULONG_PTR iFile, + IN ULONG iFace, + IN ULONG_PTR *pid) +{ + PDRVFONT pfont = (PDRVFONT)iFile; + PDRVFACE pface; + PFONTINFO16 pFontInfo; + PIFIMETRICS pifi; + PDRVIFIMETRICS pDrvIM; + PANOSE panose = {0}; + + DbgPrint("BmfdQueryFont()\n"); +// DbgBreakPoint(); + + /* Validate parameters */ + if (iFace > pfont->cNumFaces || !pid) + { + return NULL; + } + + pface = &pfont->aface[iFace - 1]; + pFontInfo = pface->pFontInfo; + + /* Allocate the structure */ + pDrvIM = EngAllocMem(FL_ZERO_MEMORY, sizeof(DRVIFIMETRICS), TAG_IFIMETRICS); + if (!pDrvIM) + { + return NULL; + } + + /* Return a pointer to free it later */ + *pid = (ULONG_PTR)pDrvIM; + + /* Fill IFIMETRICS */ + pifi = &pDrvIM->ifim; + pifi->cjThis = sizeof(DRVIFIMETRICS); + pifi->cjIfiExtra = 0; + pifi->dpwszFamilyName = FIELD_OFFSET(DRVIFIMETRICS, wszFamilyName); + pifi->dpwszStyleName = FIELD_OFFSET(DRVIFIMETRICS, wszFamilyName); + pifi->dpwszFaceName = FIELD_OFFSET(DRVIFIMETRICS, wszFaceName); + pifi->dpwszUniqueName = FIELD_OFFSET(DRVIFIMETRICS, wszFaceName); + pifi->dpFontSim = 0; + pifi->lEmbedId = 0; + pifi->lItalicAngle = 0; + pifi->lCharBias = 0; + pifi->dpCharSets = 0; + pifi->jWinCharSet = pFontInfo->dfCharSet; + pifi->jWinPitchAndFamily = pFontInfo->dfPitchAndFamily; + pifi->usWinWeight = GETVAL(pFontInfo->dfWeight); + pifi->flInfo = pface->flInfo; + pifi->fsSelection = 0; + pifi->fsType = 0; + pifi->fwdUnitsPerEm = GETVAL(pFontInfo->dfPixHeight); + pifi->fwdLowestPPEm = 0; + pifi->fwdWinAscender = GETVAL(pFontInfo->dfAscent); + pifi->fwdWinDescender = pifi->fwdUnitsPerEm - pifi->fwdWinAscender; + pifi->fwdMacAscender = pifi->fwdWinAscender; + pifi->fwdMacDescender = - pifi->fwdWinDescender; + pifi->fwdMacLineGap = 0; + pifi->fwdTypoAscender = pifi->fwdWinAscender; + pifi->fwdTypoDescender = - pifi->fwdWinDescender; + pifi->fwdTypoLineGap = 0; + pifi->fwdAveCharWidth = GETVAL(pFontInfo->dfAvgWidth); + pifi->fwdMaxCharInc = GETVAL(pFontInfo->dfMaxWidth); + pifi->fwdCapHeight = pifi->fwdUnitsPerEm / 2; + pifi->fwdXHeight = pifi->fwdUnitsPerEm / 4; + pifi->fwdSubscriptXSize = 0; + pifi->fwdSubscriptYSize = 0; + pifi->fwdSubscriptXOffset = 0; + pifi->fwdSubscriptYOffset = 0; + pifi->fwdSuperscriptXSize = 0; + pifi->fwdSuperscriptYSize = 0; + pifi->fwdSuperscriptXOffset = 0; + pifi->fwdSuperscriptYOffset = 0; + pifi->fwdUnderscoreSize = 01; + pifi->fwdUnderscorePosition = -1; + pifi->fwdStrikeoutSize = 1; + pifi->fwdStrikeoutPosition = pifi->fwdXHeight + 1; + pifi->chFirstChar = pFontInfo->dfFirstChar; + pifi->chLastChar = pFontInfo->dfLastChar; + pifi->chDefaultChar = pFontInfo->dfFirstChar + pFontInfo->dfDefaultChar; + pifi->chBreakChar = pFontInfo->dfFirstChar + pFontInfo->dfBreakChar; + pifi->wcFirstChar = pface->wcFirstChar; + pifi->wcLastChar = pface->wcLastChar; + pifi->wcDefaultChar = pface->wcDefaultChar; + pifi->wcBreakChar = pface->wcBreakChar; + pifi->ptlBaseline.x = 1; + pifi->ptlBaseline.y = 0; + pifi->ptlAspect.x = pFontInfo->dfVertRes; // CHECKME + pifi->ptlAspect.y = pFontInfo->dfHorizRes; + pifi->ptlCaret.x = 0; + pifi->ptlCaret.y = 1; + pifi->rclFontBox.left = 0; + pifi->rclFontBox.right = pifi->fwdAveCharWidth; + pifi->rclFontBox.top = pifi->fwdWinAscender; + pifi->rclFontBox.bottom = - pifi->fwdWinDescender; + *(DWORD*)&pifi->achVendId = 0x30303030; // FIXME + pifi->cKerningPairs = 0; + pifi->ulPanoseCulture = FM_PANOSE_CULTURE_LATIN; + pifi->panose = panose; + + /* Set char sets */ + pDrvIM->ajCharSet[0] = pifi->jWinCharSet; + pDrvIM->ajCharSet[1] = DEFAULT_CHARSET; + + if (pface->flInfo & FM_INFO_CONSTANT_WIDTH) + pifi->jWinPitchAndFamily |= FIXED_PITCH; + +#if 0 + EngMultiByteToUnicodeN(pDrvIM->wszFaceName, + LF_FACESIZE * sizeof(WCHAR), + NULL, + pFontInfo->, + strnlen(pDesc, LF_FACESIZE)); +#endif + wcscpy(pDrvIM->wszFaceName, L"Courier-X"); + wcscpy(pDrvIM->wszFamilyName, L"Courier-X"); + + /* Initialize font weight style flags and string */ + if (pifi->usWinWeight == FW_REGULAR) + { + // pifi->fsSelection |= FM_SEL_REGULAR; + } + else if (pifi->usWinWeight > FW_SEMIBOLD) + { + pifi->fsSelection |= FM_SEL_BOLD; + wcscat(pDrvIM->wszStyleName, L"Bold "); + } + else if (pifi->usWinWeight <= FW_LIGHT) + { + wcscat(pDrvIM->wszStyleName, L"Light "); + } + + if (pFontInfo->dfItalic) + { + pifi->fsSelection |= FM_SEL_ITALIC; + wcscat(pDrvIM->wszStyleName, L"Italic "); + } + + if (pFontInfo->dfUnderline) + { + pifi->fsSelection |= FM_SEL_UNDERSCORE; + wcscat(pDrvIM->wszStyleName, L"Underscore "); + } + + if (pFontInfo->dfStrikeOut) + { + pifi->fsSelection |= FM_SEL_STRIKEOUT; + wcscat(pDrvIM->wszStyleName, L"Strikeout "); + } + + return pifi; +} + + +VOID +APIENTRY +BmfdFree( + PVOID pv, + ULONG_PTR id) +{ + DbgPrint("BmfdFree()\n"); + if (id) + { + EngFreeMem((PVOID)id); + } +} + + + Propchange: trunk/reactos/drivers/video/font/bmfd/font.c ------------------------------------------------------------------------------ svn:eol-style = native Added: trunk/reactos/drivers/video/font/bmfd/glyph.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/font/bmfd/gl…
============================================================================== --- trunk/reactos/drivers/video/font/bmfd/glyph.c (added) +++ trunk/reactos/drivers/video/font/bmfd/glyph.c [iso-8859-1] Tue Mar 3 05:42:00 2009 @@ -1,0 +1,192 @@ +/* + * PROJECT: ReactOS win32 subsystem + * LICENSE: GPL - See COPYING in the top level directory + * PURPOSE: GDI font driver for bitmap fonts + * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org) + */ + +#include "bmfd.h" + +static +VOID +FillFDDM( + PFD_DEVICEMETRICS pfddm, + PFONTINFO16 pFontInfo) +{ + /* Fill FD_DEVICEMETRICS */ + pfddm->flRealizedType = FDM_MASK; + pfddm->pteBase.x = FLOATL_1; + pfddm->pteBase.y = 0; + pfddm->pteSide.x = 0; + pfddm->pteSide.y = FLOATL_1; + pfddm->ptlUnderline1.x = 0; + pfddm->ptlUnderline1.y = 1; + pfddm->ptlStrikeout.x = 0; + pfddm->ptlStrikeout.y = -4; + pfddm->ptlULThickness.x = 0; + pfddm->ptlULThickness.y = 1; + pfddm->ptlSOThickness.x = 0; + pfddm->ptlSOThickness.y = 1; + pfddm->lD = GETVAL(pFontInfo->dfPixWidth); + pfddm->cxMax = GETVAL(pFontInfo->dfMaxWidth); + pfddm->cyMax = GETVAL(pFontInfo->dfPixHeight); + pfddm->cjGlyphMax = pfddm->cyMax * ((pfddm->cxMax + 7) / 8); + pfddm->fxMaxAscender = GETVAL(pFontInfo->dfAscent) << 4; + pfddm->fxMaxDescender = (pfddm->cyMax << 4) - pfddm->fxMaxAscender; + pfddm->lMinA = 0; + pfddm->lMinC = 0; + pfddm->lMinD = 0; + + /* NOTE: fdxQuantized and NonLinear... stay unchanged */ +} + +/** Public Interface **********************************************************/ + +PFD_GLYPHATTR +APIENTRY +BmfdQueryGlyphAttrs( + FONTOBJ *pfo, + ULONG iMode) +{ + DbgPrint("BmfdQueryGlyphAttrs()\n"); + /* We don't support FO_ATTR_MODE_ROTATE */ + return NULL; +} + +LONG +APIENTRY +BmfdQueryFontData( + DHPDEV dhpdev, + FONTOBJ *pfo, + ULONG iMode, + HGLYPH hg, + OUT GLYPHDATA *pgd, + PVOID pv, + ULONG cjSize) +{ + PDRVFONT pfont = (PDRVFONT)pfo->iFile; + PDRVFACE pface = &pfont->aface[pfo->iFace - 1]; + PGLYPHENTRY pge = (PGLYPHENTRY)hg; + ULONG ulGlyphOffset, ulWidthBytes, ulPixWidth, ulPixHeight, x, y, cjRow; + + DbgPrint("BmfdQueryFontData(pfo=%p, iMode=%ld, hg=%p, pgd=%p, pv=%p, cjSize=%ld)\n", + pfo, iMode, hg, pgd, pv, cjSize); +// DbgBreakPoint(); + + switch (iMode) + { + case QFD_GLYPHANDBITMAP: /* 1 */ + { + GLYPHBITS *pgb = pv; + BYTE j, *pjGlyphBits; + +// DbgPrint("QFD_GLYPHANDBITMAP, hg=%p, pgd=%p, pv=%p, cjSize=%d\n", +// hg, pgd, pv, cjSize); + + if (!hg) + { + DbgPrint("no glyph handle given!\n"); + return FD_ERROR; + } + + /* Get the bitmap offset depending on file version */ + if (pface->ulVersion >= 0x300) + { + ulPixWidth = GETVAL(pge->ge20.geWidth); + ulGlyphOffset = GETVAL(pge->ge30.geOffset); + } + else + { + ulPixWidth = GETVAL(pge->ge30.geWidth); + ulGlyphOffset = GETVAL(pge->ge20.geOffset); + } + ulPixHeight = pface->wPixHeight; + + /* Calculate number of bytes per row for gdi */ + cjRow = (ulPixWidth + 7) / 8; // FIXME: other bpp values + + if (pgd) + { + /* Fill GLYPHDATA structure */ + pgd->gdf.pgb = pgb; + pgd->hg = hg; + pgd->fxD = (pface->wA + ulPixWidth + pface->wC) << 4; + pgd->fxA = pface->wA << 4; + pgd->fxAB = (pface->wA + ulPixWidth) << 4; + pgd->fxInkTop = pface->wAscent << 4; + pgd->fxInkBottom = - (pface->wDescent << 4); + pgd->rclInk.top = - pface->wAscent; + pgd->rclInk.bottom = pface->wDescent ; + pgd->rclInk.left = pface->wA; + pgd->rclInk.right = pface->wA + ulPixWidth; + pgd->ptqD.x.LowPart = 0; + pgd->ptqD.x.HighPart = pgd->fxD; + pgd->ptqD.y.LowPart = 0; + pgd->ptqD.y.HighPart = 0; + } + + if (pgb) + { +// DbgBreakPoint(); + + /* Verify that the buffer is big enough */ + if (cjSize < ulPixHeight * cjRow) + { + DbgPrint("Buffer too small (%ld), %ld,%ld\n", + cjSize, ulPixWidth, ulPixHeight); + return FD_ERROR; + } + + /* Fill GLYPHBITS structure */ + pgb->ptlOrigin.x = pface->wA; + pgb->ptlOrigin.y = - pface->wAscent; + pgb->sizlBitmap.cx = ulPixWidth; + pgb->sizlBitmap.cy = ulPixHeight; + + /* Copy the bitmap bits */ + pjGlyphBits = (PBYTE)pface->pFontInfo + ulGlyphOffset; + ulWidthBytes = pface->wWidthBytes; + for (y = 0; y < ulPixHeight; y++) + { + for (x = 0; x < cjRow; x++) + { + j = pjGlyphBits[x * ulPixHeight + y]; + pgb->aj[y * cjRow + x] = j; + } + } + + DbgPrint("iFace=%ld, ulGlyphOffset=%lx, ulPixHeight=%ld, cjRow=%ld\n", + pfo->iFace, ulGlyphOffset, ulPixHeight, cjRow); + DbgBreakPoint(); + } + + /* Return the size of the bitmap buffer */ + return ulPixHeight * cjRow; + } + + case QFD_MAXEXTENTS: /* 3 */ + { + if (pv) + { + if (cjSize < sizeof(FD_DEVICEMETRICS)) + { + /* Not enough space, fail */ + return FD_ERROR; + } + + /* Fill the PFD_DEVICEMETRICS structure */ + FillFDDM((PFD_DEVICEMETRICS)pv, pface->pFontInfo); + } + + /* Return the size of the structure */ + return sizeof(FD_DEVICEMETRICS); + } + + /* we support nothing else */ + default: + return FD_ERROR; + + } + + return FD_ERROR; +} Propchange: trunk/reactos/drivers/video/font/bmfd/glyph.c ------------------------------------------------------------------------------ svn:eol-style = native Added: trunk/reactos/drivers/video/font/directory.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/font/directo…
============================================================================== --- trunk/reactos/drivers/video/font/directory.rbuild (added) +++ trunk/reactos/drivers/video/font/directory.rbuild [iso-8859-1] Tue Mar 3 05:42:00 2009 @@ -1,0 +1,8 @@ +<?xml version="1.0"?> +<!DOCTYPE group SYSTEM "../../tools/rbuild/project.dtd"> +<group xmlns:xi="
http://www.w3.org/2001/XInclude
"> + <directory name="bmfd"> + <xi:include href="bmfd/bmfd.rbuild" /> + </directory> +</group> + Propchange: trunk/reactos/drivers/video/font/directory.rbuild ------------------------------------------------------------------------------ svn:eol-style = native
15 years, 9 months
1
0
0
0
[jmorlan] 39848: Speed up batch file execution by reading a line at a time instead of a byte at a time.
by jmorlan@svn.reactos.org
Author: jmorlan Date: Mon Mar 2 23:00:26 2009 New Revision: 39848 URL:
http://svn.reactos.org/svn/reactos?rev=39848&view=rev
Log: Speed up batch file execution by reading a line at a time instead of a byte at a time. Modified: trunk/reactos/base/shell/cmd/misc.c Modified: trunk/reactos/base/shell/cmd/misc.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/cmd/misc.c?rev=…
============================================================================== --- trunk/reactos/base/shell/cmd/misc.c [iso-8859-1] (original) +++ trunk/reactos/base/shell/cmd/misc.c [iso-8859-1] Mon Mar 2 23:00:26 2009 @@ -503,7 +503,6 @@ BOOL FileGetString (HANDLE hFile, LPTSTR lpBuffer, INT nBufferLength) { LPSTR lpString; - CHAR ch; DWORD dwRead; INT len = 0; #ifdef _UNICODE @@ -511,18 +510,20 @@ #else lpString = lpBuffer; #endif - while ((--nBufferLength > 0) && - ReadFile(hFile, &ch, 1, &dwRead, NULL) && dwRead) - { - lpString[len++] = ch; - if (ch == '\n') - { - /* break at new line*/ - break; - } - } - - if (!dwRead && !len) + + if (ReadFile(hFile, lpString, nBufferLength - 1, &dwRead, NULL)) + { + /* break at new line*/ + CHAR *end = memchr(lpString, '\n', dwRead); + len = dwRead; + if (end) + { + len = (end - lpString) + 1; + SetFilePointer(hFile, len - dwRead, NULL, FILE_CURRENT); + } + } + + if (!len) { #ifdef _UNICODE cmd_free(lpString);
15 years, 9 months
1
0
0
0
[fireball] 39847: - Add privileges check to SystemTimeAdjustmentInformation SSI routine. Spotted by Dmitry Chapyshev.
by fireball@svn.reactos.org
Author: fireball Date: Mon Mar 2 22:57:27 2009 New Revision: 39847 URL:
http://svn.reactos.org/svn/reactos?rev=39847&view=rev
Log: - Add privileges check to SystemTimeAdjustmentInformation SSI routine. Spotted by Dmitry Chapyshev. Modified: trunk/reactos/ntoskrnl/ex/sysinfo.c Modified: trunk/reactos/ntoskrnl/ex/sysinfo.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ex/sysinfo.c?rev=…
============================================================================== --- trunk/reactos/ntoskrnl/ex/sysinfo.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/ex/sysinfo.c [iso-8859-1] Mon Mar 2 22:57:27 2009 @@ -1440,6 +1440,7 @@ SSI_DEF(SystemTimeAdjustmentInformation) { + KPROCESSOR_MODE PreviousMode = KeGetPreviousMode(); /*PSYSTEM_SET_TIME_ADJUST_INFORMATION TimeInfo = (PSYSTEM_SET_TIME_ADJUST_INFORMATION)Buffer;*/ @@ -1447,7 +1448,15 @@ if (sizeof(SYSTEM_SET_TIME_ADJUST_INFORMATION) != Size) return STATUS_INFO_LENGTH_MISMATCH; - /* TODO: Check privileges */ + /* Check who is calling */ + if (PreviousMode != KernelMode) + { + /* Check access rights */ + if (!SeSinglePrivilegeCheck(SeSystemtimePrivilege, PreviousMode)) + { + return STATUS_PRIVILEGE_NOT_HELD; + } + } /* TODO: Set time adjustment information */ DPRINT1("Setting of SystemTimeAdjustmentInformation is not implemented yet!\n");
15 years, 9 months
1
0
0
0
[jmorlan] 39846: Separate batch file contexts and FOR contexts into two different structs, since they don't actually have anything in common any more
by jmorlan@svn.reactos.org
Author: jmorlan Date: Mon Mar 2 22:08:25 2009 New Revision: 39846 URL:
http://svn.reactos.org/svn/reactos?rev=39846&view=rev
Log: Separate batch file contexts and FOR contexts into two different structs, since they don't actually have anything in common any more Modified: trunk/reactos/base/shell/cmd/batch.c trunk/reactos/base/shell/cmd/batch.h trunk/reactos/base/shell/cmd/call.c trunk/reactos/base/shell/cmd/cmd.c trunk/reactos/base/shell/cmd/cmd.h trunk/reactos/base/shell/cmd/for.c Modified: trunk/reactos/base/shell/cmd/batch.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/cmd/batch.c?rev…
============================================================================== --- trunk/reactos/base/shell/cmd/batch.c [iso-8859-1] (original) +++ trunk/reactos/base/shell/cmd/batch.c [iso-8859-1] Mon Mar 2 22:08:25 2009 @@ -225,8 +225,7 @@ } /* Kill any and all FOR contexts */ - while (bc && bc->forvar) - ExitBatch (NULL); + fc = NULL; if (bc == NULL || forcenew) { @@ -261,8 +260,6 @@ bc->bEcho = bEcho; /* Preserve echo across batch calls */ bc->shiftlevel = 0; - bc->forvar = _T('\0'); - bc->forvarcount = 0; bc->params = BatchParams (firstword, param); // // Allocate enough memory to hold the params and copy them over without modifications @@ -311,9 +308,6 @@ * If no batch file is current or no further executable lines are found * return NULL. * - * Here we also look out for FOR bcontext structures which trigger the - * FOR expansion code. - * * Set eflag to 0 if line is not to be echoed else 1 */ Modified: trunk/reactos/base/shell/cmd/batch.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/cmd/batch.h?rev…
============================================================================== --- trunk/reactos/base/shell/cmd/batch.h [iso-8859-1] (original) +++ trunk/reactos/base/shell/cmd/batch.h [iso-8859-1] Mon Mar 2 22:08:25 2009 @@ -17,16 +17,23 @@ INT shiftlevel; BOOL bEcho; /* Preserve echo flag across batch calls */ REDIRECTION *RedirList; - TCHAR forvar; - UINT forvarcount; - LPTSTR *forvalues; } BATCH_CONTEXT, *LPBATCH_CONTEXT; + +typedef struct tagFORCONTEXT +{ + struct tagFORCONTEXT *prev; + TCHAR firstvar; + UINT varcount; + LPTSTR *values; +} FOR_CONTEXT, *LPFOR_CONTEXT; /* The stack of current batch contexts. * NULL when no batch is active */ extern LPBATCH_CONTEXT bc; + +extern LPFOR_CONTEXT fc; extern BOOL bEcho; /* The echo flag */ Modified: trunk/reactos/base/shell/cmd/call.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/cmd/call.c?rev=…
============================================================================== --- trunk/reactos/base/shell/cmd/call.c [iso-8859-1] (original) +++ trunk/reactos/base/shell/cmd/call.c [iso-8859-1] Mon Mar 2 22:08:25 2009 @@ -83,8 +83,6 @@ bc->hBatchFile = INVALID_HANDLE_VALUE; bc->params = NULL; bc->shiftlevel = 0; - bc->forvar = 0; /* HBP004 */ - bc->forvarcount = 0; bc->RedirList = NULL; ParseCommandLine (param); Modified: trunk/reactos/base/shell/cmd/cmd.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/cmd/cmd.c?rev=3…
============================================================================== --- trunk/reactos/base/shell/cmd/cmd.c [iso-8859-1] (original) +++ trunk/reactos/base/shell/cmd/cmd.c [iso-8859-1] Mon Mar 2 22:08:25 2009 @@ -1273,13 +1273,13 @@ if (Src[0] == _T('%') && Src[1] != _T('\0')) { /* This might be a variable. Search the list of contexts for it */ - BATCH_CONTEXT *Ctx = bc; - while (Ctx && (UINT)(Src[1] - Ctx->forvar) >= Ctx->forvarcount) + FOR_CONTEXT *Ctx = fc; + while (Ctx && (UINT)(Src[1] - Ctx->firstvar) >= Ctx->varcount) Ctx = Ctx->prev; if (Ctx) { /* Found it */ - LPTSTR Value = Ctx->forvalues[Src[1] - Ctx->forvar]; + LPTSTR Value = Ctx->values[Src[1] - Ctx->firstvar]; if (Dest + _tcslen(Value) > DestEnd) return FALSE; Dest = _stpcpy(Dest, Value); Modified: trunk/reactos/base/shell/cmd/cmd.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/cmd/cmd.h?rev=3…
============================================================================== --- trunk/reactos/base/shell/cmd/cmd.h [iso-8859-1] (original) +++ trunk/reactos/base/shell/cmd/cmd.h [iso-8859-1] Mon Mar 2 22:08:25 2009 @@ -374,7 +374,7 @@ TCHAR Variable; LPTSTR Params; LPTSTR List; - struct tagBATCHCONTEXT *Context; + struct tagFORCONTEXT *Context; } For; }; } PARSED_COMMAND; Modified: trunk/reactos/base/shell/cmd/for.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/cmd/for.c?rev=3…
============================================================================== --- trunk/reactos/base/shell/cmd/for.c [iso-8859-1] (original) +++ trunk/reactos/base/shell/cmd/for.c [iso-8859-1] Mon Mar 2 22:08:25 2009 @@ -47,6 +47,10 @@ error_syntax(param); return 1; } + +/* The stack of current FOR contexts. + * NULL when no FOR command is active */ +LPFOR_CONTEXT fc = NULL; /* Get the next element of the FOR's list */ static BOOL GetNextElement(TCHAR **pStart, TCHAR **pEnd) @@ -81,8 +85,8 @@ /* Check if this FOR should be terminated early */ static BOOL Exiting(PARSED_COMMAND *Cmd) { - /* Someone might have removed our context by calling ExitBatch */ - return bCtrlBreak || bc != Cmd->For.Context; + /* Someone might have removed our context */ + return bCtrlBreak || fc != Cmd->For.Context; } /* Read the contents of a text file into memory, @@ -230,10 +234,10 @@ /* Count how many variables will be set: one for each token, * plus maybe one for the remainder */ - bc->forvarcount = RemainderVar; + fc->varcount = RemainderVar; for (i = 1; i < 32; i++) - bc->forvarcount += (Tokens >> i & 1); - bc->forvalues = Variables; + fc->varcount += (Tokens >> i & 1); + fc->values = Variables; if (*List == StringQuote || *List == CommandQuote) { @@ -443,34 +447,27 @@ { TCHAR Buffer[CMDLINE_LENGTH]; /* Buffer to hold the variable value */ LPTSTR BufferPtr = Buffer; - LPBATCH_CONTEXT lpNew; + LPFOR_CONTEXT lpNew; BOOL Success = TRUE; LPTSTR List = DoDelayedExpansion(Cmd->For.List); if (!List) return FALSE; - /* Create our pseudo-batch-context */ - lpNew = cmd_alloc(sizeof(BATCH_CONTEXT)); + /* Create our FOR context */ + lpNew = cmd_alloc(sizeof(FOR_CONTEXT)); if (!lpNew) + { + cmd_free(List); return FALSE; + } + lpNew->prev = fc; + lpNew->firstvar = Cmd->For.Variable; + lpNew->varcount = 1; + lpNew->values = &BufferPtr; + Cmd->For.Context = lpNew; - - lpNew->prev = bc; - bc = lpNew; - - bc->hBatchFile = INVALID_HANDLE_VALUE; - bc->raw_params = NULL; - bc->params = NULL; - bc->shiftlevel = 0; - bc->forvar = Cmd->For.Variable; - bc->forvarcount = 1; - bc->forvalues = &BufferPtr; - if (bc->prev) - bc->bEcho = bc->prev->bEcho; - else - bc->bEcho = bEcho; - bc->RedirList = NULL; + fc = lpNew; if (Cmd->For.Switches & FOR_F) { @@ -492,9 +489,10 @@ } /* Remove our context, unless someone already did that */ - if (bc == lpNew) - ExitBatch(NULL); - + if (fc == lpNew) + fc = lpNew->prev; + + cmd_free(lpNew); cmd_free(List); return Success; }
15 years, 9 months
1
0
0
0
[frik85] 39845: RosCMS update: * fixed annoying bug: metadata got lost in certain circumstances
by frik85@svn.reactos.org
Author: frik85 Date: Mon Mar 2 21:28:01 2009 New Revision: 39845 URL:
http://svn.reactos.org/svn/reactos?rev=39845&view=rev
Log: RosCMS update: * fixed annoying bug: metadata got lost in certain circumstances Modified:
trunk/web/reactos.org/htdocs/roscms/inc/data_export_text.php
Modified:
trunk/web/reactos.org/htdocs/roscms/inc/data_export_text.php
URL:
http://svn.reactos.org/svn/reactos/trunk/web/reactos.org/htdocs/roscms/inc/…
============================================================================== ---
trunk/web/reactos.org/htdocs/roscms/inc/data_export_text.php
[iso-8859-1] (original) +++
trunk/web/reactos.org/htdocs/roscms/inc/data_export_text.php
[iso-8859-1] Mon Mar 2 21:28:01 2009 @@ -227,7 +227,8 @@ require_once("inc/data_edit.php"); require_once("inc/data_edit_tag.php"); - + + global $RosCMS_GET_debug; global $roscms_intern_account_id; @@ -249,9 +250,13 @@ $RosCMS_intern_d_rev_number = ""; - echo "<p>!!!!!!!!!!!!!!!!!</p><hr /><p>asdadasdawddsda</p>"; - - echo "<p>DynNumber: ".$RosCMS_GET_d_value4."</p>"; + $tmpTransferTags = false; + $tmpTransferTagsId = 0; + $tmpTransferTagsRid = 0; + + + if ($RosCMS_GET_debug) echo "<p>!!!!!!!!!!!!!!!!!</p><hr /><p>asdadasdawddsda</p>"; + if ($RosCMS_GET_debug) echo "<p>DynNumber: ".$RosCMS_GET_d_value4."</p>"; @@ -283,22 +288,40 @@ LIMIT 1;"); $result_data_save_find_draft = mysql_fetch_array($query_data_save_find_draft); - //echo "<p>DraftEntry: ".$result_data_save_find_draft['rev_id'].", ".$result_data_save_find_draft['data_id'].", ".$result_data_save_find_draft['rev_version'].", ".$result_data_save_find_draft['tv_value']."</p>"; - - if (getTagValue($RosCMS_GET_d_id, $result_data_save_find_draft['rev_id'], "-1", "status") == "draft") { - //echo "<p>draft-lang: ".$RosCMS_GET_d_value3."|".$RosCMS_GET_d_value4."|".$result_data_save_find_draft['rev_language']."</p>"; + if ($RosCMS_GET_debug) echo "<p>DraftEntry: ".$result_data_save_find_draft['rev_id'].", ".$result_data_save_find_draft['data_id'].", ".$result_data_save_find_draft['rev_version'].", ".$result_data_save_find_draft['tv_value']."</p>"; + if ($RosCMS_GET_debug) echo "<p>TYPE: ".getTagValue($RosCMS_GET_d_id, $result_data_save_find_draft['rev_id'], "-1", "status")."</p>"; + + $cur_data_type = getTagValue($RosCMS_GET_d_id, $result_data_save_find_draft['rev_id'], "-1", "status"); + + if ($cur_data_type == "draft") { + if ($RosCMS_GET_debug) echo "<p>draft-lang: ".$RosCMS_GET_d_value3."|".$RosCMS_GET_d_value4."|".$result_data_save_find_draft['rev_language']."</p>"; $RosCMS_intern_save_rev_id = $result_data_save_find_draft['rev_id']; $RosCMS_intern_d_rev_lang = $result_data_save_find_draft['rev_language']; $RosCMS_intern_d_rev_usrid = $result_data_save_find_draft['rev_usrid']; $RosCMS_intern_d_rev_version = 0; } - else { // save changes as draft based on a new/stable entry - //echo "<p>else-lang: ".$RosCMS_GET_d_value3."|".$RosCMS_GET_d_value4."|".$RosCMS_GET_d_r_lang."</p>"; + else if ($cur_data_type == "new" || $cur_data_type == "stable") { // save changes as draft based on a new/stable entry + if ($RosCMS_GET_debug) echo "<p>new/stable-lang: ".$RosCMS_GET_d_value3."|".$RosCMS_GET_d_value4."|".$RosCMS_GET_d_r_lang."</p>"; + //$RosCMS_GET_d_value3 = "submit"; // save instead of update $RosCMS_intern_save_rev_id = ""; $RosCMS_intern_d_rev_version = 0; $RosCMS_intern_d_rev_lang = $RosCMS_GET_d_r_lang; $RosCMS_intern_d_rev_usrid = $roscms_intern_account_id; + + if ($result_data_save_find_draft['rev_id'] != "") + { + $tmpTransferTags = true; + $tmpTransferTagsId = $result_data_save_find_draft['data_id']; + $tmpTransferTagsRid = $result_data_save_find_draft['rev_id']; + } + } + else { + if ($RosCMS_GET_debug) echo "<p>else-lang: ".$RosCMS_GET_d_value3."|".$RosCMS_GET_d_value4."|".$RosCMS_GET_d_r_lang."</p>"; + $RosCMS_intern_save_rev_id = ""; + $RosCMS_intern_d_rev_version = 0; + $RosCMS_intern_d_rev_lang = $RosCMS_GET_d_r_lang; + $RosCMS_intern_d_rev_usrid = $roscms_intern_account_id; //die("Saving draft not possible !?!"); } @@ -307,7 +330,7 @@ if (($RosCMS_GET_d_value3 == "draft" && $RosCMS_intern_save_rev_id == "") || $RosCMS_GET_d_value3 == "submit") { // add - //echo "<p>ADD</p>"; + if ($RosCMS_GET_debug) echo "<p>ADD</p>"; /* if ($RosCMS_GET_d_value3 == "submit") { $query_data_save_find_submit = mysql_query("SELECT rev_id, data_id rev_version, rev_language, rev_usrid, rev_datetime @@ -379,15 +402,23 @@ );"); // echo "<p>CONTENT###\n<br />".$_POST["plm".$i]."</p>"; } - + + if ($tmpTransferTags == true) { + // data_tag + transfer_tags($tmpTransferTagsId, $tmpTransferTagsRid, $RosCMS_GET_d_id, $result_data_save_find_submit2['rev_id'], false); + if ($RosCMS_GET_debug) echo "\n<p>transfer_tags(".$tmpTransferTagsId.", ".$tmpTransferTagsRid.", ".$RosCMS_GET_d_id.", ".$result_data_save_find_submit2['rev_id'].", false)</p>"; + delete_tag($RosCMS_GET_d_id, $result_data_save_find_submit2['rev_id'], "-1", "status"); + } + if ($RosCMS_GET_d_value3 == "submit") { -// echo "<h4>submit_process: tag_add(".$RosCMS_GET_d_id.", ".$result_data_save_find_submit2['rev_id'].", 'status', 'new', '-1');</h4>"; + if ($RosCMS_GET_debug) echo "<h4>submit_process: tag_add(".$RosCMS_GET_d_id.", ".$result_data_save_find_submit2['rev_id'].", 'status', 'new', '-1');</h4>"; tag_add($RosCMS_GET_d_id, $result_data_save_find_submit2['rev_id'], 'status', 'new', '-1'); } else if ($RosCMS_GET_d_value3 == "draft") { -// echo "<h4>submit_process: tag_add(".$RosCMS_GET_d_id.", ".$result_data_save_find_submit2['rev_id'].", 'status', 'draft', '-1');</h4>"; + if ($RosCMS_GET_debug) echo "<h4>submit_process: tag_add(".$RosCMS_GET_d_id.", ".$result_data_save_find_submit2['rev_id'].", 'status', 'draft', '-1');</h4>"; tag_add($RosCMS_GET_d_id, $result_data_save_find_submit2['rev_id'], 'status', 'draft', '-1'); } + if ($RosCMS_GET_d_value4 != "no") { tag_add($RosCMS_GET_d_id, $result_data_save_find_submit2['rev_id'], 'number', $RosCMS_GET_d_value4, '-1');
15 years, 9 months
1
0
0
0
[dchapyshev] 39844: - Fix typo
by dchapyshev@svn.reactos.org
Author: dchapyshev Date: Mon Mar 2 19:21:24 2009 New Revision: 39844 URL:
http://svn.reactos.org/svn/reactos?rev=39844&view=rev
Log: - Fix typo Modified: trunk/reactos/ntoskrnl/ex/sysinfo.c Modified: trunk/reactos/ntoskrnl/ex/sysinfo.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ex/sysinfo.c?rev=…
============================================================================== --- trunk/reactos/ntoskrnl/ex/sysinfo.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/ex/sysinfo.c [iso-8859-1] Mon Mar 2 19:21:24 2009 @@ -1426,7 +1426,7 @@ /* Check if enough storage was provided */ if (sizeof(SYSTEM_QUERY_TIME_ADJUST_INFORMATION) > Size) { - * ReqSize = sizeof(SYSTEM_SET_TIME_ADJUST_INFORMATION); + * ReqSize = sizeof(SYSTEM_QUERY_TIME_ADJUST_INFORMATION); return STATUS_INFO_LENGTH_MISMATCH; }
15 years, 9 months
1
0
0
0
[dchapyshev] 39843: - Add check of returned value for EnumDisplaySettings
by dchapyshev@svn.reactos.org
Author: dchapyshev Date: Mon Mar 2 17:08:46 2009 New Revision: 39843 URL:
http://svn.reactos.org/svn/reactos?rev=39843&view=rev
Log: - Add check of returned value for EnumDisplaySettings Modified: trunk/reactos/base/applications/taskmgr/applpage.c Modified: trunk/reactos/base/applications/taskmgr/applpage.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/taskmgr/…
============================================================================== --- trunk/reactos/base/applications/taskmgr/applpage.c [iso-8859-1] (original) +++ trunk/reactos/base/applications/taskmgr/applpage.c [iso-8859-1] Mon Mar 2 17:08:46 2009 @@ -66,7 +66,9 @@ pDevMode.dmSize = sizeof(DEVMODE); pDevMode.dmDriverExtra = 0; - EnumDisplaySettings(NULL, ENUM_CURRENT_SETTINGS, &pDevMode); + + if (!EnumDisplaySettings(NULL, ENUM_CURRENT_SETTINGS, &pDevMode)) + return ILC_COLOR; switch (pDevMode.dmBitsPerPel) {
15 years, 9 months
1
0
0
0
[dchapyshev] 39842: - Add more known dlls - Add to Path variable a directory wbem
by dchapyshev@svn.reactos.org
Author: dchapyshev Date: Mon Mar 2 16:30:10 2009 New Revision: 39842 URL:
http://svn.reactos.org/svn/reactos?rev=39842&view=rev
Log: - Add more known dlls - Add to Path variable a directory wbem Modified: trunk/reactos/boot/bootdata/hivesys_arm.inf trunk/reactos/boot/bootdata/hivesys_i386.inf Modified: trunk/reactos/boot/bootdata/hivesys_arm.inf URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/boot/bootdata/hivesys_arm.…
============================================================================== --- trunk/reactos/boot/bootdata/hivesys_arm.inf [iso-8859-1] (original) +++ trunk/reactos/boot/bootdata/hivesys_arm.inf [iso-8859-1] Mon Mar 2 16:30:10 2009 @@ -751,7 +751,7 @@ ; System environment settings HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","ComSpec",0x00020000,"%SystemRoot%\system32\cmd.exe" HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","OS",0x00020000,"ReactOS" -HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","Path",0x00020000,"%SystemRoot%\bin;%SystemRoot%\system32;%SystemRoot%" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","Path",0x00020000,"%SystemRoot%\bin;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\system32\wbem" HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","windir",0x00020000,"%SystemRoot%" HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","TEMP",0x00020000,"%SystemDrive%\TEMP" HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","TMP",0x00020000,"%SystemDrive%\TEMP" @@ -762,7 +762,24 @@ ; Known DLLs HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","DllDirectory",0x00020000,"%SystemRoot%\system32" HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","advapi32",0x00000000,"advapi32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","comdlg32",0x00000000,"comdlg32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","gdi32",0x00000000,"gdi32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","imagehlp",0x00000000,"imagehlp.dll" HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","kernel32",0x00000000,"kernel32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","lz32",0x00000000,"lz32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","ole32",0x00000000,"ole32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","oleaut32",0x00000000,"oleaut32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","olecli32",0x00000000,"olecli32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","olesvr32",0x00000000,"olesvr32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","olethk32",0x00000000,"olethk32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","rpcrt4",0x00000000,"rpcrt4.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","shell32",0x00000000,"shell32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","url",0x00000000,"url.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","urlmon",0x00000000,"urlmon.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","user32",0x00000000,"user32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","version",0x00000000,"version.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","wininet",0x00000000,"wininet.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","wldap32",0x00000000,"wldap32.dll" ; Pagefile settings HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management","PagingFiles",0x00010000, \ Modified: trunk/reactos/boot/bootdata/hivesys_i386.inf URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/boot/bootdata/hivesys_i386…
============================================================================== --- trunk/reactos/boot/bootdata/hivesys_i386.inf [iso-8859-1] (original) +++ trunk/reactos/boot/bootdata/hivesys_i386.inf [iso-8859-1] Mon Mar 2 16:30:10 2009 @@ -752,7 +752,7 @@ ; System environment settings HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","ComSpec",0x00020000,"%SystemRoot%\system32\cmd.exe" HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","OS",0x00020000,"ReactOS" -HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","Path",0x00020000,"%SystemRoot%\bin;%SystemRoot%\system32;%SystemRoot%" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","Path",0x00020000,"%SystemRoot%\bin;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\system32\wbem" HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","windir",0x00020000,"%SystemRoot%" HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","TEMP",0x00020000,"%SystemDrive%\TEMP" HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","TMP",0x00020000,"%SystemDrive%\TEMP" @@ -763,7 +763,24 @@ ; Known DLLs HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","DllDirectory",0x00020000,"%SystemRoot%\system32" HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","advapi32",0x00000000,"advapi32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","comdlg32",0x00000000,"comdlg32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","gdi32",0x00000000,"gdi32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","imagehlp",0x00000000,"imagehlp.dll" HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","kernel32",0x00000000,"kernel32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","lz32",0x00000000,"lz32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","ole32",0x00000000,"ole32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","oleaut32",0x00000000,"oleaut32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","olecli32",0x00000000,"olecli32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","olesvr32",0x00000000,"olesvr32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","olethk32",0x00000000,"olethk32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","rpcrt4",0x00000000,"rpcrt4.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","shell32",0x00000000,"shell32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","url",0x00000000,"url.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","urlmon",0x00000000,"urlmon.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","user32",0x00000000,"user32.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","version",0x00000000,"version.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","wininet",0x00000000,"wininet.dll" +HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\KnownDlls","wldap32",0x00000000,"wldap32.dll" ; Pagefile settings HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management","PagingFiles",0x00010000, \
15 years, 9 months
1
0
0
0
← Newer
1
...
43
44
45
46
47
48
49
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
41
42
43
44
45
46
47
48
49
Results per page:
10
25
50
100
200