winehq.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
2025
February
January
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
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
January 2006
----- 2025 -----
February 2025
January 2025
----- 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
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
4 participants
617 discussions
Start a n
N
ew thread
David Moore : gdi: Fix display of fonts using Symbol codepages and assorted other
by Alexandre Julliard
13 Jan '06
13 Jan '06
Module: wine Branch: refs/heads/master Commit: 1ef9a6db4e1c96efb1e44842bd152ee94c151817 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=1ef9a6db4e1c96efb1e4484…
Author: David Moore <davidm(a)sjsoft.com> Date: Fri Jan 13 14:25:16 2006 +0100 gdi: Fix display of fonts using Symbol codepages and assorted other codepages. --- dlls/gdi/freetype.c | 26 +++++++++++++++++++++++++- 1 files changed, 25 insertions(+), 1 deletions(-) diff --git a/dlls/gdi/freetype.c b/dlls/gdi/freetype.c index aff355d..3023ab3 100644 --- a/dlls/gdi/freetype.c +++ b/dlls/gdi/freetype.c @@ -2679,14 +2679,38 @@ static void FTVectorToPOINTFX(FT_Vector return; } +/*************************************************** + * According to the MSDN documentation on WideCharToMultiByte, + * certain codepages cannot set the default_used parameter. + * This returns TRUE if the codepage can set that parameter, false else + * so that calls to WideCharToMultiByte don't fail with ERROR_INVALID_PARAMETER + */ +static BOOL codepage_sets_default_used(UINT codepage) +{ + switch (codepage) + { + case CP_UTF7: + case CP_UTF8: + case CP_SYMBOL: + return FALSE; + default: + return TRUE; + } +} + static FT_UInt get_glyph_index(GdiFont font, UINT glyph) { if(font->ft_face->charmap->encoding == FT_ENCODING_NONE) { WCHAR wc = (WCHAR)glyph; BOOL default_used; + BOOL *default_used_pointer; FT_UInt ret; char buf; - if(!WideCharToMultiByte(font->codepage, 0, &wc, 1, &buf, sizeof(buf), NULL, &default_used) || default_used) + default_used_pointer = NULL; + default_used = FALSE; + if (codepage_sets_default_used(font->codepage)) + default_used_pointer = &default_used; + if(!WideCharToMultiByte(font->codepage, 0, &wc, 1, &buf, sizeof(buf), NULL, default_used_pointer) || default_used) ret = 0; else ret = pFT_Get_Char_Index(font->ft_face, (unsigned char)buf);
1
0
0
0
James Hawkins : advpack: Move file related functions to files.c.
by Alexandre Julliard
13 Jan '06
13 Jan '06
Module: wine Branch: refs/heads/master Commit: 05d079a3257a977c7c606183954ca22c60f19950 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=05d079a3257a977c7c60618…
Author: James Hawkins <truiken(a)gmail.com> Date: Fri Jan 13 14:16:29 2006 +0100 advpack: Move file related functions to files.c. --- dlls/advpack/advpack.c | 604 ------------------------------------------------ dlls/advpack/files.c | 607 ++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 607 insertions(+), 604 deletions(-)
1
0
0
0
James Hawkins : advpack: Add stubs for the file save/restore functions.
by Alexandre Julliard
13 Jan '06
13 Jan '06
Module: wine Branch: refs/heads/master Commit: a56e256323dc47964baad4ca279ae0e369af268b URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=a56e256323dc47964baad4c…
Author: James Hawkins <truiken(a)gmail.com> Date: Fri Jan 13 14:16:02 2006 +0100 advpack: Add stubs for the file save/restore functions. --- dlls/advpack/Makefile.in | 1 dlls/advpack/advpack.spec | 6 +- dlls/advpack/files.c | 118 +++++++++++++++++++++++++++++++++++++++++++++ include/advpub.h | 15 ++++++ 4 files changed, 137 insertions(+), 3 deletions(-) create mode 100644 dlls/advpack/files.c diff --git a/dlls/advpack/Makefile.in b/dlls/advpack/Makefile.in index cf236f5..a14468d 100644 --- a/dlls/advpack/Makefile.in +++ b/dlls/advpack/Makefile.in @@ -9,6 +9,7 @@ EXTRALIBS = $(LIBUNICODE) C_SRCS = \ advpack.c \ + files.c \ reg.c SUBDIRS = tests diff --git a/dlls/advpack/advpack.spec b/dlls/advpack/advpack.spec index f1e200f..2fe49fe 100644 --- a/dlls/advpack/advpack.spec +++ b/dlls/advpack/advpack.spec @@ -7,9 +7,9 @@ @ stdcall DoInfInstall(ptr) @ stdcall ExecuteCab(ptr ptr ptr) @ stdcall ExtractFiles(str str long ptr ptr long) -@ stub FileSaveMarkNotExist -@ stub FileSaveRestore -@ stub FileSaveRestoreOnINF +@ stdcall FileSaveMarkNotExist(str str str) +@ stdcall FileSaveRestore(ptr str str str long) +@ stdcall FileSaveRestoreOnINF(ptr str str str str str long) @ stdcall GetVersionFromFile(str ptr ptr long) @ stdcall GetVersionFromFileEx(str ptr ptr long) @ stdcall IsNTAdmin(long ptr) diff --git a/dlls/advpack/files.c b/dlls/advpack/files.c new file mode 100644 index 0000000..46ff983 --- /dev/null +++ b/dlls/advpack/files.c @@ -0,0 +1,118 @@ +/* + * Advpack file functions + * + * Copyright 2006 James Hawkins + * + * 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +#include <stdarg.h> + +#include "windef.h" +#include "winbase.h" +#include "winuser.h" +#include "advpub.h" +#include "wine/debug.h" + +WINE_DEFAULT_DEBUG_CHANNEL(advpack); + +/*********************************************************************** + * FileSaveMarkNotExist (ADVPACK.@) + * + * Marks the files in the file list as not existing so they won't be + * backed up during a save. + * + * PARAMS + * pszFileList [I] NULL-separated list of filenames. + * pszDir [I] Path of the backup directory. + * pszBaseName [I] Basename of the backup files. + * + * RETURNS + * Success: S_OK. + * Failure: E_FAIL. + * + * BUGS + * Unimplemented. + */ +HRESULT WINAPI FileSaveMarkNotExist(LPSTR pszFileList, LPSTR pszDir, LPSTR pszBaseName) +{ + FIXME("(%p, %p, %p) stub\n", pszFileList, pszDir, pszBaseName); + + return E_FAIL; +} + +/*********************************************************************** + * FileSaveRestore (ADVPACK.@) + * + * Saves or restores the files in the specified file list. + * + * PARAMS + * hDlg [I] Handle to the dialog used for the display. + * pszFileList [I] NULL-separated list of filenames. + * pszDir [I] Path of the backup directory. + * pszBaseName [I] Basename of the backup files. + * dwFlags [I] See advpub.h. + * + * RETURNS + * Success: S_OK. + * Failure: E_FAIL. + * + * NOTES + * If pszFileList is NULL on restore, all files will be restored. + * + * BUGS + * Unimplemented. + */ +HRESULT WINAPI FileSaveRestore(HWND hDlg, LPSTR pszFileList, LPSTR pszDir, + LPSTR pszBaseName, DWORD dwFlags) +{ + FIXME("(%p, %p, %p, %p, %ld) stub\n", hDlg, pszFileList, pszDir, + pszBaseName, dwFlags); + + return E_FAIL; +} + +/*********************************************************************** + * FileSaveRestoreOnINF (ADVPACK.@) + * + * + * PARAMS + * hWnd [I] Handle to the window used for the display. + * pszTitle [I] Title of the window. + * pszINF [I] Fully-qualified INF filename. + * pszSection [I] GenInstall INF section name. + * pszBackupDir [I] Directory to store the backup file. + * pszBaseBackupFile [I] Basename of the backup files. + * dwFlags [I] See advpub.h + * + * RETURNS + * Success: S_OK. + * Failure: E_FAIL. + * + * NOTES + * If pszSection is NULL, the default section will be used. + * + * BUGS + * Unimplemented. + */ +HRESULT WINAPI FileSaveRestoreOnINF(HWND hWnd, PCSTR pszTitle, PCSTR pszINF, + PCSTR pszSection, PCSTR pszBackupDir, + PCSTR pszBaseBackupFile, DWORD dwFlags) +{ + FIXME("(%p, %p, %p, %p, %p, %p, %ld) stub\n", hWnd, pszTitle, pszINF, + pszSection, pszBackupDir, pszBaseBackupFile, dwFlags); + + return E_FAIL; +} diff --git a/include/advpub.h b/include/advpub.h index 04c60fd..34893dc 100644 --- a/include/advpub.h +++ b/include/advpub.h @@ -86,6 +86,16 @@ typedef CSTRTABLE *LPCSTRTABLE; #define IE4_USEREFCNT 0x00000400 #define IE4_EXTRAINCREFCNT 0x00000800 +/* Flags for file save and restore functions */ +#define AFSR_RESTORE IE4_RESTORE +#define AFSR_BACKNEW IE4_BACKNEW +#define AFSR_NODELETENEW IE4_NODELETENEW +#define AFSR_NOMESSAGES IE4_NOMESSAGES +#define AFSR_NOPROGRESS IE4_NOPROGRESS +#define AFSR_UPDREFCNT IE4_UPDREFCNT +#define AFSR_USEREFCNT IE4_USEREFCNT +#define AFSR_EXTRAINCREFCNT IE4_EXTRAINCREFCNT + HRESULT WINAPI AdvInstallFile(HWND hwnd, LPCSTR lpszSourceDir, LPCSTR lpszSourceFile, LPCSTR lpszDestDir, LPCSTR lpszDestFile, DWORD dwFlags, DWORD dwReserved); @@ -93,6 +103,11 @@ HRESULT WINAPI DelNode(LPCSTR pszFileOrD HRESULT WINAPI DelNodeRunDLL32(HWND,HINSTANCE,LPSTR,INT); HRESULT WINAPI ExecuteCab( HWND hwnd, PCABINFO pCab, LPVOID pReserved ); HRESULT WINAPI ExtractFiles(LPCSTR,LPCSTR,DWORD,LPCSTR,LPVOID,DWORD); +HRESULT WINAPI FileSaveMarkNotExist(LPSTR pszFileList, LPSTR pszDir, LPSTR pszBaseName); +HRESULT WINAPI FileSaveRestore(HWND hDlg, LPSTR pszFileList, LPSTR pszDir, + LPSTR pszBaseName, DWORD dwFlags); +HRESULT WINAPI FileSaveRestoreOnINF(HWND hWnd, PCSTR pszTitle, PCSTR pszINF, + PCSTR pszSection, PCSTR pszBackupDir, PCSTR pszBaseBackupFile, DWORD dwFlags); HRESULT WINAPI GetVersionFromFile(LPSTR lpszFilename, LPDWORD pdwMSVer, LPDWORD pdwLSVer, BOOL bVersion); HRESULT WINAPI GetVersionFromFileEx(LPSTR lpszFilename, LPDWORD pdwMSVer, LPDWORD pdwLSVer, BOOL bVersion); BOOL WINAPI IsNTAdmin(DWORD,LPDWORD);
1
0
0
0
James Hawkins : advpack: Only output a FIXME if flags are set.
by Alexandre Julliard
13 Jan '06
13 Jan '06
Module: wine Branch: refs/heads/master Commit: 0b2d3f17b370b8ef872d651911cb82ffe24107cc URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=0b2d3f17b370b8ef872d651…
Author: James Hawkins <truiken(a)gmail.com> Date: Fri Jan 13 14:15:29 2006 +0100 advpack: Only output a FIXME if flags are set. --- dlls/advpack/advpack.c | 6 +++++- 1 files changed, 5 insertions(+), 1 deletions(-) diff --git a/dlls/advpack/advpack.c b/dlls/advpack/advpack.c index bcd3925..3998b13 100644 --- a/dlls/advpack/advpack.c +++ b/dlls/advpack/advpack.c @@ -617,8 +617,12 @@ HRESULT WINAPI DelNode( LPCSTR pszFileOr { CHAR fname[MAX_PATH]; HRESULT ret = E_FAIL; + + TRACE("(%s, 0x%08lx)\n", debugstr_a(pszFileOrDirName), dwFlags); + + if (dwFlags) + FIXME("Flags ignored!\n"); - FIXME("(%s, 0x%08lx): flags ignored\n", debugstr_a(pszFileOrDirName), dwFlags); if (pszFileOrDirName && *pszFileOrDirName) { lstrcpyA(fname, pszFileOrDirName);
1
0
0
0
Saulius Krasuckas : mscms: Fix some wine_todo for GetStandardColorSpaceProfile().
by Alexandre Julliard
13 Jan '06
13 Jan '06
Module: wine Branch: refs/heads/master Commit: f107125b3b65c4088fbb5333f33ce2d1910e003a URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=f107125b3b65c4088fbb533…
Author: Saulius Krasuckas <saulius.krasuckas(a)gmail.com> Date: Fri Jan 13 14:09:04 2006 +0100 mscms: Fix some wine_todo for GetStandardColorSpaceProfile(). --- dlls/mscms/profile.c | 25 +++++++++++++++++++++++-- dlls/mscms/tests/profile.c | 4 ---- 2 files changed, 23 insertions(+), 6 deletions(-) diff --git a/dlls/mscms/profile.c b/dlls/mscms/profile.c index 59c9996..8f0279f 100644 --- a/dlls/mscms/profile.c +++ b/dlls/mscms/profile.c @@ -346,7 +346,17 @@ BOOL WINAPI GetStandardColorSpaceProfile TRACE( "( 0x%08lx, %p, %p )\n", id, profile, size ); - if (machine || !size) return FALSE; + if (machine) + { + SetLastError(ERROR_NOT_SUPPORTED); + return FALSE; + } + + if (!size) + { + SetLastError(ERROR_INSUFFICIENT_BUFFER); + return FALSE; + } sizeW = *size * sizeof(WCHAR); @@ -401,7 +411,18 @@ BOOL WINAPI GetStandardColorSpaceProfile TRACE( "( 0x%08lx, %p, %p )\n", id, profile, size ); - if (machine || !size) return FALSE; + if (machine) + { + SetLastError(ERROR_NOT_SUPPORTED); + return FALSE; + } + + if (!size) + { + SetLastError(ERROR_INSUFFICIENT_BUFFER); + return FALSE; + } + GetColorDirectoryW( machine, rgbprofile, &len ); switch (id) diff --git a/dlls/mscms/tests/profile.c b/dlls/mscms/tests/profile.c index 14cfa5a..1f0f986 100644 --- a/dlls/mscms/tests/profile.c +++ b/dlls/mscms/tests/profile.c @@ -525,7 +525,6 @@ static void test_GetStandardColorSpacePr /* Parameter checks */ /* Single invalid parameter checks */ - todo_wine fail_GSCSPA(machine, SPACE_RGB, newprofile, &size, sizeP, (GLE == ERROR_NOT_SUPPORTED)); todo_wine fail_GSCSPA(NULL, (DWORD)-1, newprofile, &size, sizeP, (GLE == ERROR_FILE_NOT_FOUND)); @@ -537,7 +536,6 @@ static void test_GetStandardColorSpacePr fail_GSCSPA(NULL, SPACE_RGB, newprofile, &size, 0, (GLE == ERROR_MORE_DATA || GLE == ERROR_INSUFFICIENT_BUFFER)); /* Several invalid parameter checks */ - todo_wine fail_GSCSPA(machine, 0, newprofile, &size, 0, (GLE == ERROR_INVALID_PARAMETER || GLE == ERROR_NOT_SUPPORTED)); todo_wine fail_GSCSPA(NULL, 0, newprofile, NULL, 0, (GLE == ERROR_INVALID_PARAMETER)); @@ -604,7 +602,6 @@ static void test_GetStandardColorSpacePr /* Parameter checks */ /* Single invalid parameter checks */ - todo_wine fail_GSCSPW(machineW, SPACE_RGB, newprofile, &size, sizeP, (GLE == ERROR_NOT_SUPPORTED)); todo_wine fail_GSCSPW(NULL, (DWORD)-1, newprofile, &size, sizeP, (GLE == ERROR_FILE_NOT_FOUND)); @@ -616,7 +613,6 @@ static void test_GetStandardColorSpacePr fail_GSCSPW(NULL, SPACE_RGB, newprofile, &size, 0, (GLE == ERROR_MORE_DATA || GLE == ERROR_INSUFFICIENT_BUFFER)); /* Several invalid parameter checks */ - todo_wine fail_GSCSPW(machineW, 0, newprofile, &size, 0, (GLE == ERROR_INVALID_PARAMETER || GLE == ERROR_NOT_SUPPORTED)); todo_wine fail_GSCSPW(NULL, 0, newprofile, NULL, 0, (GLE == ERROR_INVALID_PARAMETER));
1
0
0
0
Saulius Krasuckas : mscms: Make two checks more strict in the case of success.
by Alexandre Julliard
13 Jan '06
13 Jan '06
Module: wine Branch: refs/heads/master Commit: 7a044cb365587a687fc89fb098047dbc2bc1ec91 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=7a044cb365587a687fc89fb…
Author: Saulius Krasuckas <saulius.krasuckas(a)gmail.com> Date: Fri Jan 13 14:08:45 2006 +0100 mscms: Make two checks more strict in the case of success. --- dlls/mscms/tests/profile.c | 10 ++++++---- 1 files changed, 6 insertions(+), 4 deletions(-) diff --git a/dlls/mscms/tests/profile.c b/dlls/mscms/tests/profile.c index 6e82fb3..14cfa5a 100644 --- a/dlls/mscms/tests/profile.c +++ b/dlls/mscms/tests/profile.c @@ -505,10 +505,11 @@ do { #define test_GSCSPA(pMachName, dwProfID, pProfName, pdwSz, dwSz, GLE_OK) \ do { \ size = dwSz; \ - SetLastError(0); \ + SetLastError(0xfaceabad); \ ret = pGetStandardColorSpaceProfileA(pMachName, dwProfID, pProfName, pdwSz);\ GLE = GetLastError(); \ - ok( (!ret && GLE_OK) || (ret && !lstrcmpiA( pProfName, "" )), \ + ok( (!ret && GLE_OK) || \ + (ret && !lstrcmpiA( pProfName, "" ) && GLE == 0xfaceabad), \ "GetStandardColorSpaceProfileA() returns %d (GLE=%ld)\n", ret, GLE ); \ } while (0) @@ -582,10 +583,11 @@ do { #define test_GSCSPW(pMachName, dwProfID, pProfName, pdwSz, dwSz, GLE_OK) \ do { \ size = dwSz; \ - SetLastError(0); \ + SetLastError(0xfaceabad); \ ret = pGetStandardColorSpaceProfileW(pMachName, dwProfID, pProfName, pdwSz);\ GLE = GetLastError(); \ - ok( (!ret && GLE_OK) || (ret && !lstrcmpiW( pProfName, emptyW )), \ + ok( (!ret && GLE_OK) || \ + (ret && !lstrcmpiW( pProfName, emptyW ) && GLE == 0xfaceabad), \ "GetStandardColorSpaceProfileA() returns %d (GLE=%ld)\n", ret, GLE ); \ } while (0)
1
0
0
0
Alexandre Julliard : ntdll: Add debug registers to the context of all exceptions.
by Alexandre Julliard
13 Jan '06
13 Jan '06
Module: wine Branch: refs/heads/master Commit: 2878d9921669aaceb840ce460be4026f039076ec URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=2878d9921669aaceb840ce4…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Fri Jan 13 13:58:14 2006 +0100 ntdll: Add debug registers to the context of all exceptions. Maintain a local cache of the debug registers to avoid server calls where possible. --- dlls/ntdll/ntdll_misc.h | 17 ++++++++++++++ dlls/ntdll/signal_i386.c | 47 ++++++++++++++++++++++++---------------- dlls/ntdll/thread.c | 33 ++++++++++++++++++++++++++-- include/wine/server_protocol.h | 3 ++- include/winternl.h | 2 +- server/protocol.def | 1 + server/thread.c | 1 + server/trace.c | 1 + 8 files changed, 81 insertions(+), 24 deletions(-) diff --git a/dlls/ntdll/ntdll_misc.h b/dlls/ntdll/ntdll_misc.h index ac9acae..c63b700 100644 --- a/dlls/ntdll/ntdll_misc.h +++ b/dlls/ntdll/ntdll_misc.h @@ -134,4 +134,21 @@ static inline struct ntdll_thread_data * return (struct ntdll_thread_data *)NtCurrentTeb()->SystemReserved2; } +/* thread registers, stored in NtCurrentTeb()->SpareBytes1 */ +struct ntdll_thread_regs +{ + DWORD dr0; /* debug registers */ + DWORD dr1; + DWORD dr2; + DWORD dr3; + DWORD dr6; + DWORD dr7; + DWORD spare[4]; /* change this if you add fields! */ +}; + +static inline struct ntdll_thread_regs *ntdll_get_thread_regs(void) +{ + return (struct ntdll_thread_regs *)NtCurrentTeb()->SpareBytes1; +} + #endif diff --git a/dlls/ntdll/signal_i386.c b/dlls/ntdll/signal_i386.c index be33458..1b2e8f0 100644 --- a/dlls/ntdll/signal_i386.c +++ b/dlls/ntdll/signal_i386.c @@ -740,7 +740,9 @@ inline static void restore_fpu( const CO */ inline static void save_context( CONTEXT *context, const SIGCONTEXT *sigcontext, WORD fs, WORD gs ) { - context->ContextFlags = CONTEXT_FULL; + struct ntdll_thread_regs * const regs = ntdll_get_thread_regs(); + + context->ContextFlags = CONTEXT_FULL | CONTEXT_DEBUG_REGISTERS; context->Eax = EAX_sig(sigcontext); context->Ebx = EBX_sig(sigcontext); context->Ecx = ECX_sig(sigcontext); @@ -757,6 +759,12 @@ inline static void save_context( CONTEXT context->SegFs = fs; context->SegGs = gs; context->SegSs = LOWORD(SS_sig(sigcontext)); + context->Dr0 = regs->dr0; + context->Dr1 = regs->dr1; + context->Dr2 = regs->dr2; + context->Dr3 = regs->dr3; + context->Dr6 = regs->dr6; + context->Dr7 = regs->dr7; } @@ -767,6 +775,14 @@ inline static void save_context( CONTEXT */ inline static void restore_context( const CONTEXT *context, SIGCONTEXT *sigcontext ) { + struct ntdll_thread_regs * const regs = ntdll_get_thread_regs(); + + regs->dr0 = context->Dr0; + regs->dr1 = context->Dr1; + regs->dr2 = context->Dr2; + regs->dr3 = context->Dr3; + regs->dr6 = context->Dr6; + regs->dr7 = context->Dr7; EAX_sig(sigcontext) = context->Eax; EBX_sig(sigcontext) = context->Ebx; ECX_sig(sigcontext) = context->Ecx; @@ -797,7 +813,7 @@ inline static void restore_context( cons /*********************************************************************** * set_cpu_context * - * Set the new CPU context. + * Set the new CPU context. Used by NtSetContextThread. */ void set_cpu_context( const CONTEXT *context ) { @@ -805,6 +821,16 @@ void set_cpu_context( const CONTEXT *con if (flags & CONTEXT_FLOATING_POINT) restore_fpu( context ); + if (flags & CONTEXT_DEBUG_REGISTERS) + { + struct ntdll_thread_regs * const regs = ntdll_get_thread_regs(); + regs->dr0 = context->Dr0; + regs->dr1 = context->Dr1; + regs->dr2 = context->Dr2; + regs->dr3 = context->Dr3; + regs->dr6 = context->Dr6; + regs->dr7 = context->Dr7; + } if (flags & CONTEXT_FULL) { if ((flags & CONTEXT_FULL) != (CONTEXT_FULL & ~CONTEXT_i386)) @@ -1027,8 +1053,6 @@ done: */ static void WINAPI raise_trap_exception( EXCEPTION_RECORD *rec, CONTEXT *context ) { - DWORD dr0, dr1, dr2, dr3, dr6, dr7; - if (rec->ExceptionCode == EXCEPTION_SINGLE_STEP) { if (context->EFlags & 0x100) @@ -1048,22 +1072,7 @@ static void WINAPI raise_trap_exception( } } - dr0 = context->Dr0; - dr1 = context->Dr1; - dr2 = context->Dr2; - dr3 = context->Dr3; - dr6 = context->Dr6; - dr7 = context->Dr7; - __regs_RtlRaiseException( rec, context ); - - context->ContextFlags = CONTEXT_FULL; - if (dr0 != context->Dr0 || dr1 != context->Dr1 || dr2 != context->Dr2 || - dr3 != context->Dr3 || dr6 != context->Dr6 || dr7 != context->Dr7) - { - /* the debug registers have changed, set the new values */ - context->ContextFlags |= CONTEXT_DEBUG_REGISTERS; - } NtSetContextThread( GetCurrentThread(), context ); } diff --git a/dlls/ntdll/thread.c b/dlls/ntdll/thread.c index 9a2e2bd..d189bf7 100644 --- a/dlls/ntdll/thread.c +++ b/dlls/ntdll/thread.c @@ -294,6 +294,9 @@ NTSTATUS WINAPI RtlCreateUserThread( HAN teb->ClientId.UniqueProcess = (HANDLE)GetCurrentProcessId(); teb->ClientId.UniqueThread = (HANDLE)tid; + /* inherit registers from parent thread */ + memcpy( teb->SpareBytes1, ntdll_get_thread_regs(), sizeof(teb->SpareBytes1) ); + thread_data = (struct ntdll_thread_data *)teb->SystemReserved2; thread_data->request_fd = request_pipe[1]; @@ -495,8 +498,14 @@ NTSTATUS WINAPI NtSetContextThread( HAND #ifdef __i386__ /* on i386 debug registers always require a server call */ - self = ((handle == GetCurrentThread()) && - !(context->ContextFlags & (CONTEXT_DEBUG_REGISTERS & ~CONTEXT_i386))); + self = (handle == GetCurrentThread()); + if (self && (context->ContextFlags & (CONTEXT_DEBUG_REGISTERS & ~CONTEXT_i386))) + { + struct ntdll_thread_regs * const regs = ntdll_get_thread_regs(); + self = (regs->dr0 == context->Dr0 && regs->dr1 == context->Dr1 && + regs->dr2 == context->Dr2 && regs->dr3 == context->Dr3 && + regs->dr6 == context->Dr6 && regs->dr7 == context->Dr7); + } #endif if (!self) @@ -781,6 +790,7 @@ NTSTATUS WINAPI NtGetContextThread( HAND NTSTATUS ret; CONTEXT ctx; DWORD dummy, i; + BOOL self = FALSE; SERVER_START_REQ( get_thread_context ) { @@ -789,6 +799,7 @@ NTSTATUS WINAPI NtGetContextThread( HAND req->suspend = 0; wine_server_set_reply( req, &ctx, sizeof(ctx) ); ret = wine_server_call( req ); + self = reply->self; } SERVER_END_REQ; @@ -814,7 +825,23 @@ NTSTATUS WINAPI NtGetContextThread( HAND } } - if (ret == STATUS_SUCCESS) copy_context( context, &ctx, context->ContextFlags ); + if (ret == STATUS_SUCCESS) + { + copy_context( context, &ctx, context->ContextFlags ); +#ifdef __i386__ + /* update the cached version of the debug registers */ + if (self && (context->ContextFlags & (CONTEXT_DEBUG_REGISTERS & ~CONTEXT_i386))) + { + struct ntdll_thread_regs * const regs = ntdll_get_thread_regs(); + regs->dr0 = context->Dr0; + regs->dr1 = context->Dr1; + regs->dr2 = context->Dr2; + regs->dr3 = context->Dr3; + regs->dr6 = context->Dr6; + regs->dr7 = context->Dr7; + } +#endif + } else if (ret == STATUS_PENDING) ret = STATUS_ACCESS_DENIED; return ret; } diff --git a/include/wine/server_protocol.h b/include/wine/server_protocol.h index 5f2ad9e..4ab1467 100644 --- a/include/wine/server_protocol.h +++ b/include/wine/server_protocol.h @@ -1990,6 +1990,7 @@ struct get_thread_context_request struct get_thread_context_reply { struct reply_header __header; + int self; /* VARARG(context,context); */ }; @@ -4348,6 +4349,6 @@ union generic_reply struct query_symlink_reply query_symlink_reply; }; -#define SERVER_PROTOCOL_VERSION 219 +#define SERVER_PROTOCOL_VERSION 220 #endif /* __WINE_WINE_SERVER_PROTOCOL_H */ diff --git a/include/winternl.h b/include/winternl.h index 67403bb..a5a2e83 100644 --- a/include/winternl.h +++ b/include/winternl.h @@ -282,7 +282,7 @@ typedef struct _TEB PVOID SystemReserved1[54]; /* 0cc used for kernel32 private data in Wine */ PVOID Spare1; /* 1a4 */ LONG ExceptionCode; /* 1a8 */ - BYTE SpareBytes1[40]; /* 1ac */ + BYTE SpareBytes1[40]; /* 1ac used for ntdll private data in Wine */ PVOID SystemReserved2[10]; /* 1d4 used for ntdll private data in Wine */ GDI_TEB_BATCH GdiTebBatch; /* 1fc */ ULONG gdiRgn; /* 6dc */ diff --git a/server/protocol.def b/server/protocol.def index 55aef19..d3878cb 100644 --- a/server/protocol.def +++ b/server/protocol.def @@ -1432,6 +1432,7 @@ enum char_info_mode unsigned int flags; /* context flags */ int suspend; /* if getting context during suspend */ @REPLY + int self; /* was it a handle to the current thread? */ VARARG(context,context); /* thread context */ @END diff --git a/server/thread.c b/server/thread.c index 3ffbf85..1c00ce7 100644 --- a/server/thread.c +++ b/server/thread.c @@ -1094,6 +1094,7 @@ DECL_HANDLER(get_thread_context) memset( data, 0, sizeof(CONTEXT) ); get_thread_context( thread, data, req->flags ); } + reply->self = (thread == current); release_object( thread ); } diff --git a/server/trace.c b/server/trace.c index 49ff25e..1aa964e 100644 --- a/server/trace.c +++ b/server/trace.c @@ -1895,6 +1895,7 @@ static void dump_get_thread_context_requ static void dump_get_thread_context_reply( const struct get_thread_context_reply *req ) { + fprintf( stderr, " self=%d,", req->self ); fprintf( stderr, " context=" ); dump_varargs_context( cur_size ); }
1
0
0
0
James Hawkins : advpack: Add initial tests for AdvInstallFile.
by Alexandre Julliard
13 Jan '06
13 Jan '06
Module: wine Branch: refs/heads/master Commit: d6bfc17ba345047b83068612f4c44587d481e73c URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=d6bfc17ba345047b8306861…
Author: James Hawkins <truiken(a)gmail.com> Date: Fri Jan 13 13:54:30 2006 +0100 advpack: Add initial tests for AdvInstallFile. --- dlls/advpack/tests/files.c | 51 ++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 51 insertions(+), 0 deletions(-) diff --git a/dlls/advpack/tests/files.c b/dlls/advpack/tests/files.c index 640ecb1..960e4e7 100644 --- a/dlls/advpack/tests/files.c +++ b/dlls/advpack/tests/files.c @@ -20,6 +20,7 @@ #include <stdio.h> #include <windows.h> +#include <advpub.h> #include <fci.h> #include "wine/test.h" @@ -30,6 +31,7 @@ /* function pointers */ HMODULE hAdvPack; static HRESULT (WINAPI *pExtractFiles)(LPCSTR, LPCSTR, DWORD, LPCSTR, LPVOID, DWORD); +static HRESULT (WINAPI *pAdvInstallFile)(HWND,LPCSTR,LPCSTR,LPCSTR,LPCSTR,DWORD,DWORD); CHAR CURR_DIR[MAX_PATH]; @@ -40,6 +42,7 @@ static void init_function_pointers() if (hAdvPack) { pExtractFiles = (void *)GetProcAddress(hAdvPack, "ExtractFiles"); + pAdvInstallFile = (void*)GetProcAddress(hAdvPack, "AdvInstallFile"); } } @@ -372,6 +375,53 @@ static void test_ExtractFiles() ok(!RemoveDirectoryA("dest\\testdir"), "Exepected dest\\testdir to not exist\n"); } +static void test_AdvInstallFile(void) +{ + HRESULT hr; + char CURR_DIR[MAX_PATH]; + char destFolder[MAX_PATH]; + + GetCurrentDirectoryA(MAX_PATH, CURR_DIR); + + lstrcpyA(destFolder, CURR_DIR); + lstrcatA(destFolder, "\\"); + lstrcatA(destFolder, "dest"); + + createTestFile("source.txt"); + + /* try invalid source directory */ + hr = pAdvInstallFile(NULL, NULL, "source.txt", destFolder, "destination.txt", 0, 0); + ok(hr == E_INVALIDARG, "Expected E_INVALIDARG, got %ld\n", hr); + ok(!DeleteFileA("dest\\destination.txt"), "Expected dest\\destination.txt to not exist\n"); + + /* try invalid source file */ + hr = pAdvInstallFile(NULL, CURR_DIR, NULL, destFolder, "destination.txt", 0, 0); + ok(hr == E_INVALIDARG, "Expected E_INVALIDARG, got %ld\n", hr); + ok(!DeleteFileA("dest\\destination.txt"), "Expected dest\\destination.txt to not exist\n"); + + /* try invalid destination directory */ + hr = pAdvInstallFile(NULL, CURR_DIR, "source.txt", NULL, "destination.txt", 0, 0); + ok(hr == E_INVALIDARG, "Expected E_INVALIDARG, got %ld\n", hr); + ok(!DeleteFileA("dest\\destination.txt"), "Expected dest\\destination.txt to not exist\n"); + + /* try copying to nonexistent destination directory */ + hr = pAdvInstallFile(NULL, CURR_DIR, "source.txt", destFolder, "destination.txt", 0, 0); + ok(hr == S_OK, "Expected S_OK, got %ld\n", hr); + ok(DeleteFileA("dest\\destination.txt"), "Expected dest\\destination.txt to exist\n"); + + /* native windows screws up if the source file doesn't exist */ + + /* test AIF_NOOVERWRITE behavior, asks the user to overwrite if AIF_QUIET is not specified */ + createTestFile("dest\\destination.txt"); + hr = pAdvInstallFile(NULL, CURR_DIR, "source.txt", destFolder, + "destination.txt", AIF_NOOVERWRITE | AIF_QUIET, 0); + ok(hr == S_OK, "Expected S_OK, got %ld\n", hr); + ok(DeleteFileA("dest\\destination.txt"), "Expected dest\\destination.txt to exist\n"); + ok(RemoveDirectoryA("dest"), "Expected dest to exist\n"); + + DeleteFileA("source.txt"); +} + START_TEST(files) { init_function_pointers(); @@ -379,6 +429,7 @@ START_TEST(files) create_cab_file(); test_ExtractFiles(); + test_AdvInstallFile(); delete_test_files(); }
1
0
0
0
James Hawkins : advpack: Implement AdvInstallFile.
by Alexandre Julliard
13 Jan '06
13 Jan '06
Module: wine Branch: refs/heads/master Commit: 3e8b588d3aead57a07c5f69abfca74d4aeccb640 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=3e8b588d3aead57a07c5f69…
Author: James Hawkins <truiken(a)gmail.com> Date: Fri Jan 13 13:54:23 2006 +0100 advpack: Implement AdvInstallFile. --- dlls/advpack/advpack.c | 102 ++++++++++++++++++++++++++++++++++++++++++++++-- 1 files changed, 97 insertions(+), 5 deletions(-) diff --git a/dlls/advpack/advpack.c b/dlls/advpack/advpack.c index 8fd87fd..bcd3925 100644 --- a/dlls/advpack/advpack.c +++ b/dlls/advpack/advpack.c @@ -36,6 +36,31 @@ WINE_DEFAULT_DEBUG_CHANNEL(advpack); typedef HRESULT (WINAPI *DLLREGISTER) (void); +/* FIXME: this is only for the local case, X:\ */ +#define ROOT_LENGTH 3 + +UINT CALLBACK pQuietQueueCallback(PVOID Context, UINT Notification, + UINT_PTR Param1, UINT_PTR Param2) +{ + return 1; +} + +UINT CALLBACK pQueueCallback(PVOID Context, UINT Notification, + UINT_PTR Param1, UINT_PTR Param2) +{ + /* only be verbose for error notifications */ + if (!Notification || + Notification == SPFILENOTIFY_RENAMEERROR || + Notification == SPFILENOTIFY_DELETEERROR || + Notification == SPFILENOTIFY_COPYERROR) + { + return SetupDefaultQueueCallbackA(Context, Notification, + Param1, Param2); + } + + return 1; +} + /*********************************************************************** * AdvInstallFile (ADVPACK.@) * @@ -57,18 +82,85 @@ typedef HRESULT (WINAPI *DLLREGISTER) (v * NOTES * If lpszDestFile is NULL, the destination filename is the same as * lpszSourceFIle. - * - * BUGS - * Unimplemented. */ HRESULT WINAPI AdvInstallFile(HWND hwnd, LPCSTR lpszSourceDir, LPCSTR lpszSourceFile, LPCSTR lpszDestDir, LPCSTR lpszDestFile, DWORD dwFlags, DWORD dwReserved) { - FIXME("(%p,%p,%p,%p,%p,%ld,%ld) stub\n", hwnd, debugstr_a(lpszSourceDir), + PSP_FILE_CALLBACK_A pFileCallback; + LPSTR szPath, szDestFilename; + char szRootPath[ROOT_LENGTH]; + DWORD dwLen, dwLastError; + HSPFILEQ fileQueue; + PVOID pContext; + + TRACE("(%p,%p,%p,%p,%p,%ld,%ld) stub\n", hwnd, debugstr_a(lpszSourceDir), debugstr_a(lpszSourceFile), debugstr_a(lpszDestDir), debugstr_a(lpszDestFile), dwFlags, dwReserved); - return E_FAIL; + + if (!lpszSourceDir || !lpszSourceFile || !lpszDestDir) + return E_INVALIDARG; + + fileQueue = SetupOpenFileQueue(); + if (fileQueue == INVALID_HANDLE_VALUE) + return HRESULT_FROM_WIN32(GetLastError()); + + pContext = NULL; + dwLastError = ERROR_SUCCESS; + + lstrcpynA(szRootPath, lpszSourceDir, ROOT_LENGTH); + szPath = (LPSTR)lpszSourceDir + ROOT_LENGTH; + + /* use lpszSourceFile as destination filename if lpszDestFile is NULL */ + if (lpszDestFile) + { + dwLen = lstrlenA(lpszDestFile); + szDestFilename = HeapAlloc(GetProcessHeap(), 0, dwLen); + lstrcpyA(szDestFilename, lpszDestFile); + } + else + { + dwLen = lstrlenA(lpszSourceFile); + szDestFilename = HeapAlloc(GetProcessHeap(), 0, dwLen); + lstrcpyA(szDestFilename, lpszSourceFile); + } + + /* add the file copy operation to the setup queue */ + if (!SetupQueueCopyA(fileQueue, szRootPath, szPath, lpszSourceFile, NULL, + NULL, lpszDestDir, szDestFilename, dwFlags)) + { + dwLastError = GetLastError(); + goto done; + } + + pContext = SetupInitDefaultQueueCallbackEx(hwnd, INVALID_HANDLE_VALUE, + 0, 0, NULL); + if (!pContext) + { + dwLastError = GetLastError(); + goto done; + } + + /* don't output anything for AIF_QUIET */ + if (dwFlags & AIF_QUIET) + pFileCallback = pQuietQueueCallback; + else + pFileCallback = pQueueCallback; + + /* perform the file copy */ + if (!SetupCommitFileQueueA(hwnd, fileQueue, pFileCallback, pContext)) + { + dwLastError = GetLastError(); + goto done; + } + +done: + SetupTermDefaultQueueCallback(pContext); + SetupCloseFileQueue(fileQueue); + + HeapFree(GetProcessHeap(), 0, szDestFilename); + + return HRESULT_FROM_WIN32(dwLastError); } /***********************************************************************
1
0
0
0
Phil Krylov : riched20: Select word on double click.
by Alexandre Julliard
13 Jan '06
13 Jan '06
Module: wine Branch: refs/heads/master Commit: 6e3a72549af5bbf01f0e6d5dcfeed0d5258f5aa8 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=6e3a72549af5bbf01f0e6d5…
Author: Phil Krylov <phil(a)newstar.rinet.ru> Date: Fri Jan 13 13:54:11 2006 +0100 riched20: Select word on double click. --- dlls/riched20/caret.c | 11 +++++++++++ dlls/riched20/editor.c | 8 ++++++-- dlls/riched20/editor.h | 1 + 3 files changed, 18 insertions(+), 2 deletions(-) diff --git a/dlls/riched20/caret.c b/dlls/riched20/caret.c index ca58c6d..f3d120e 100644 --- a/dlls/riched20/caret.c +++ b/dlls/riched20/caret.c @@ -578,6 +578,17 @@ ME_MoveCursorWords(ME_TextEditor *editor } +void +ME_SelectWord(ME_TextEditor *editor) +{ + if (!(editor->pCursors[0].pRun->member.run.nFlags & MERF_ENDPARA)) + ME_MoveCursorWords(editor, &editor->pCursors[0], -1); + ME_MoveCursorWords(editor, &editor->pCursors[1], +1); + ME_InvalidateSelection(editor); + ME_SendSelChange(editor); +} + + int ME_GetCursorOfs(ME_TextEditor *editor, int nCursor) { ME_Cursor *pCursor = &editor->pCursors[nCursor]; diff --git a/dlls/riched20/editor.c b/dlls/riched20/editor.c index ad6162f..4fd7d03 100644 --- a/dlls/riched20/editor.c +++ b/dlls/riched20/editor.c @@ -3,6 +3,7 @@ * * Copyright 2004 by Krzysztof Foltman * Copyright 2005 by Cihan Altinay + * Copyright 2005 by Phil Krylov * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -1837,6 +1838,9 @@ LRESULT WINAPI RichEditANSIWndProc(HWND if (GetCapture() == hWnd) ReleaseCapture(); break; + case WM_LBUTTONDBLCLK: + ME_SelectWord(editor); + break; case WM_PAINT: if (editor->bRedraw) { @@ -2167,7 +2171,7 @@ void ME_RegisterEditorClass(HINSTANCE hI WNDCLASSW wcW; WNDCLASSA wcA; - wcW.style = CS_HREDRAW | CS_VREDRAW | CS_GLOBALCLASS; + wcW.style = CS_DBLCLKS | CS_HREDRAW | CS_VREDRAW | CS_GLOBALCLASS; wcW.lpfnWndProc = RichEditANSIWndProc; wcW.cbClsExtra = 0; wcW.cbWndExtra = 4; @@ -2183,7 +2187,7 @@ void ME_RegisterEditorClass(HINSTANCE hI bResult = RegisterClassW(&wcW); assert(bResult); - wcA.style = CS_HREDRAW | CS_VREDRAW | CS_GLOBALCLASS; + wcA.style = CS_DBLCLKS | CS_HREDRAW | CS_VREDRAW | CS_GLOBALCLASS; wcA.lpfnWndProc = RichEditANSIWndProc; wcA.cbClsExtra = 0; wcA.cbWndExtra = 4; diff --git a/dlls/riched20/editor.h b/dlls/riched20/editor.h index 3ead3c0..95b0a5e 100644 --- a/dlls/riched20/editor.h +++ b/dlls/riched20/editor.h @@ -140,6 +140,7 @@ void ME_SetDefaultCharFormat(ME_TextEdit /* caret.c */ void ME_SetSelection(ME_TextEditor *editor, int from, int to); +void ME_SelectWord(ME_TextEditor *editor); void ME_HideCaret(ME_TextEditor *ed); void ME_ShowCaret(ME_TextEditor *ed); void ME_MoveCaret(ME_TextEditor *ed);
1
0
0
0
← Newer
1
...
35
36
37
38
39
40
41
...
62
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
50
51
52
53
54
55
56
57
58
59
60
61
62
Results per page:
10
25
50
100
200