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
December 2023
----- 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
1 participants
418 discussions
Start a n
N
ew thread
Hans Leidekker : kernel32/tests: Fix ProcessMachineTypeInfo tests.
by Alexandre Julliard
15 Dec '23
15 Dec '23
Module: wine Branch: master Commit: 77b366251767a6bfa1f744257aa371bd6ed49254 URL:
https://gitlab.winehq.org/wine/wine/-/commit/77b366251767a6bfa1f744257aa371…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Fri Dec 15 12:46:31 2023 +0100 kernel32/tests: Fix ProcessMachineTypeInfo tests. --- dlls/kernel32/tests/process.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/dlls/kernel32/tests/process.c b/dlls/kernel32/tests/process.c index 5f5327245fc..e0f1d210e58 100644 --- a/dlls/kernel32/tests/process.c +++ b/dlls/kernel32/tests/process.c @@ -5296,15 +5296,24 @@ static void test_GetProcessInformation(void) return; } + SetLastError(0xdeadbeef); ret = pGetProcessInformation(GetCurrentProcess(), ProcessMachineTypeInfo, NULL, 0); + if (!ret && GetLastError() == ERROR_INVALID_PARAMETER) + { + win_skip("GetProcessInformation(ProcessMachineTypeInfo) is not supported.\n"); /* < win11 */ + return; + } ok(!ret, "Unexpected return value %d.\n", ret); ok(GetLastError() == ERROR_BAD_LENGTH, "Unexpected error %ld.\n", GetLastError()); + SetLastError(0xdeadbeef); ret = pGetProcessInformation(GetCurrentProcess(), ProcessMachineTypeInfo, &mi, 0); ok(!ret, "Unexpected return value %d.\n", ret); ok(GetLastError() == ERROR_BAD_LENGTH, "Unexpected error %ld.\n", GetLastError()); + SetLastError(0xdeadbeef); ret = pGetProcessInformation(GetCurrentProcess(), ProcessMachineTypeInfo, &mi, sizeof(mi) - 1); ok(!ret, "Unexpected return value %d.\n", ret); ok(GetLastError() == ERROR_BAD_LENGTH, "Unexpected error %ld.\n", GetLastError()); + SetLastError(0xdeadbeef); ret = pGetProcessInformation(GetCurrentProcess(), ProcessMachineTypeInfo, &mi, sizeof(mi) + 1); ok(!ret, "Unexpected return value %d.\n", ret); ok(GetLastError() == ERROR_BAD_LENGTH, "Unexpected error %ld.\n", GetLastError()); @@ -5321,7 +5330,6 @@ static void test_GetProcessInformation(void) if (machines[i].Process) { ok(mi.ProcessMachine == machines[i].Machine, "Unexpected process machine %#x.\n", mi.ProcessMachine); - ok(!mi.Res0, "Unexpected process machine %#x.\n", mi.ProcessMachine); ok(!!(mi.MachineAttributes & UserEnabled) == machines[i].UserMode, "Unexpected attributes %#x.\n", mi.MachineAttributes); ok(!!(mi.MachineAttributes & KernelEnabled) == machines[i].KernelMode, "Unexpected attributes %#x.\n",
1
0
0
0
Alexandre Julliard : oleaut32/tests: Run the 64-bit typelib tests also on 32-bit platforms.
by Alexandre Julliard
15 Dec '23
15 Dec '23
Module: wine Branch: master Commit: 206a7495abc14fd47dfd44c558002502799e97e2 URL:
https://gitlab.winehq.org/wine/wine/-/commit/206a7495abc14fd47dfd44c5580025…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Fri Dec 15 14:41:48 2023 +0100 oleaut32/tests: Run the 64-bit typelib tests also on 32-bit platforms. --- dlls/oleaut32/tests/typelib.c | 49 ++++++++++++++++++++++++------------------- 1 file changed, 27 insertions(+), 22 deletions(-) diff --git a/dlls/oleaut32/tests/typelib.c b/dlls/oleaut32/tests/typelib.c index 80e723b2349..d755729d9e9 100644 --- a/dlls/oleaut32/tests/typelib.c +++ b/dlls/oleaut32/tests/typelib.c @@ -94,6 +94,7 @@ static WCHAR wszGUID[] = {'G','U','I','D',0}; static WCHAR wszguid[] = {'g','u','i','d',0}; static const BOOL is_win64 = sizeof(void *) > sizeof(int); +static BOOL is_wow64; #ifdef __i386__ static const BOOL abi_supports_stdcall = TRUE; @@ -1613,17 +1614,25 @@ static void test_QueryPathOfRegTypeLib(DWORD arch) if (!do_typelib_reg_key(&uid, 3, 1, arch, base, FALSE)) return; if (!do_typelib_reg_key(&uid, 3, 37, arch, base, FALSE)) return; if (!do_typelib_reg_key(&uid, 5, 37, arch, base, FALSE)) return; - if (arch == 64 && !do_typelib_reg_key(&uid, 5, 37, 32, wrongW, FALSE)) return; + if (!do_typelib_reg_key(&uid, 5, 37, (arch == 32) ? 64 : 32, wrongW, FALSE)) return; for (i = 0; i < ARRAY_SIZE(td); i++) { + winetest_push_context( "win%lu: %u", arch, i ); ret = QueryPathOfRegTypeLib(&uid, td[i].maj, td[i].min, LOCALE_NEUTRAL, &path); - ok(ret == td[i].ret, "QueryPathOfRegTypeLib(%u.%u) returned %08lx\n", td[i].maj, td[i].min, ret); + ok(ret == td[i].ret || (ret == TYPE_E_LIBNOTREGISTERED && arch == 64 && !is_win64 && !is_wow64), + "QueryPathOfRegTypeLib(%u.%u) returned %08lx\n", td[i].maj, td[i].min, ret); if (ret == S_OK) { - ok(!lstrcmpW(td[i].path, path), "typelib %u.%u path doesn't match\n", td[i].maj, td[i].min); + if (i == 6 && arch == (is_win64 ? 32 : 64)) + ok( !lstrcmpW( path, L"wrong_5_37.dll" ), "typelib %u.%u path doesn't match: %s\n", + td[i].maj, td[i].min, debugstr_w(path)); + else + ok(!lstrcmpW(td[i].path, path), "typelib %u.%u path doesn't match: %s\n", + td[i].maj, td[i].min, debugstr_w(path)); SysFreeString(path); } + winetest_pop_context(); } do_typelib_reg_key(&uid, 0, 0, arch, NULL, TRUE); @@ -3716,7 +3725,8 @@ todo_wine { ok(typeattr->cVars == 0, "cVars = %d\n", typeattr->cVars); ok(typeattr->cImplTypes == 1, "cImplTypes = %d\n", typeattr->cImplTypes); ok(typeattr->cbSizeVft == 0xaab8 || typeattr->cbSizeVft == 0xaab0 || - typeattr->cbSizeVft == 0x5560, "cbSizeVft = 0x%x\n", typeattr->cbSizeVft); + typeattr->cbSizeVft == 0x555c || typeattr->cbSizeVft == 0x5560, + "cbSizeVft = 0x%x\n", typeattr->cbSizeVft); ok(typeattr->cbAlignment == alignment, "cbAlignment = %d\n", typeattr->cbAlignment); ok(typeattr->wTypeFlags == 0, "wTypeFlags = %d\n", typeattr->wTypeFlags); ok(typeattr->wMajorVerNum == 0, "wMajorVerNum = %d\n", typeattr->wMajorVerNum); @@ -7926,10 +7936,8 @@ static void testTDA(ITypeLib *tl, struct _TDATest *TDATest, }else if(TDATest->vt == VT_VARIANT){ if(create){ size = sizeof(VARIANT); -#ifdef _WIN64 if(ptr_size != sizeof(void*)) - size -= 8; /* 32-bit variant is 4 bytes smaller than 64-bit variant */ -#endif + size += (is_win64 ? -8 : 8); /* 32-bit variant is 8 bytes smaller than 64-bit variant */ }else size = sizeof(VARIANT); } @@ -8276,7 +8284,8 @@ static void test_stub(void) CoUninitialize(); } -static void test_dep(void) { +static void test_dep( SYSKIND sys ) +{ HRESULT hr; const WCHAR *refFilename; ITypeLib *preftLib; @@ -8295,7 +8304,7 @@ static void test_dep(void) { static const GUID libguid = {0xe0228f26,0x2946,0x478c,{0xb6,0x4a,0x93,0xfe,0xef,0xa5,0x05,0x32}}; static const GUID ifaceguid = {0x394376dd,0x3bb8,0x4804,{0x8c,0xcc,0x95,0x59,0x43,0x40,0x04,0xf3}}; - trace("Starting typelib dependency tests\n"); + winetest_push_context( "%s", sys == SYS_WIN32 ? "win32" : "win64" ); refFilename = create_test_typelib(4); hr = LoadTypeLibEx(refFilename, REGKIND_NONE, &preftLib); @@ -8307,13 +8316,8 @@ static void test_dep(void) { GetTempFileNameA(".", "tlb", 0, filename); MultiByteToWideChar(CP_ACP, 0, filename, -1, filenameW, MAX_PATH); - if(sizeof(void*) == 8) { - hr = CreateTypeLib2(SYS_WIN64, filenameW, &pctLib); - ok(hr == S_OK, "got %08lx\n", hr); - } else { - hr = CreateTypeLib2(SYS_WIN32, filenameW, &pctLib); - ok(hr == S_OK, "got %08lx\n", hr); - } + hr = CreateTypeLib2(sys, filenameW, &pctLib); + ok(hr == S_OK, "got %08lx\n", hr); hr = ICreateTypeLib2_SetGuid(pctLib, &libguid); ok(hr == S_OK, "got %08lx\n", hr); @@ -8391,6 +8395,7 @@ static void test_dep(void) { ITypeLib_Release(ptLib); DeleteFileW(filenameW); + winetest_pop_context(); } static void test_DeleteImplType(void) @@ -8572,6 +8577,7 @@ START_TEST(typelib) const WCHAR *filename; init_function_pointers(); + if (!is_win64) IsWow64Process( GetCurrentProcess(), &is_wow64 ); ref_count_test(wszStdOle2); test_TypeComp(); @@ -8579,13 +8585,13 @@ START_TEST(typelib) test_TypeInfo(); test_DispCallFunc(); test_QueryPathOfRegTypeLib(32); - if(sizeof(void*) == 8){ - test_QueryPathOfRegTypeLib(64); - test_CreateTypeLib(SYS_WIN64); - test_SetTypeDescAlias(SYS_WIN64); - } + test_QueryPathOfRegTypeLib(64); + test_CreateTypeLib(SYS_WIN64); + test_SetTypeDescAlias(SYS_WIN64); + test_dep(SYS_WIN64); test_CreateTypeLib(SYS_WIN32); test_SetTypeDescAlias(SYS_WIN32); + test_dep(SYS_WIN32); test_inheritance(); test_SetVarHelpContext(); test_SetFuncAndParamNames(); @@ -8607,7 +8613,6 @@ START_TEST(typelib) test_LoadRegTypeLib(); test_GetLibAttr(); test_stub(); - test_dep(); test_DeleteImplType(); test_DeleteFuncDesc(); }
1
0
0
0
Alexandre Julliard : oleaut32: Fix loading a 64-bit typelib in 32-bit mode.
by Alexandre Julliard
15 Dec '23
15 Dec '23
Module: wine Branch: master Commit: 613270d49fd3c25a17bbce37277a8b9a5713b692 URL:
https://gitlab.winehq.org/wine/wine/-/commit/613270d49fd3c25a17bbce37277a8b…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Fri Dec 15 14:51:01 2023 +0100 oleaut32: Fix loading a 64-bit typelib in 32-bit mode. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=55962
--- dlls/oleaut32/typelib.c | 38 ++++++++++++++++---------------------- 1 file changed, 16 insertions(+), 22 deletions(-) diff --git a/dlls/oleaut32/typelib.c b/dlls/oleaut32/typelib.c index 9fe4cb65f99..f412074bd21 100644 --- a/dlls/oleaut32/typelib.c +++ b/dlls/oleaut32/typelib.c @@ -73,6 +73,8 @@ WINE_DEFAULT_DEBUG_CHANNEL(ole); WINE_DECLARE_DEBUG_CHANNEL(typelib); +static const BOOL is_win64 = sizeof(void *) > sizeof(int); + typedef struct { WORD offset; @@ -392,13 +394,11 @@ static HRESULT query_typelib_path( REFGUID guid, WORD wMaj, WORD wMin, HRESULT WINAPI QueryPathOfRegTypeLib( REFGUID guid, WORD wMaj, WORD wMin, LCID lcid, LPBSTR path ) { BOOL redir = TRUE; -#ifdef _WIN64 - HRESULT hres = query_typelib_path( guid, wMaj, wMin, SYS_WIN64, lcid, path, TRUE ); + HRESULT hres = query_typelib_path( guid, wMaj, wMin, is_win64 ? SYS_WIN64 : SYS_WIN32, lcid, path, TRUE ); if(SUCCEEDED(hres)) return hres; redir = FALSE; -#endif - return query_typelib_path( guid, wMaj, wMin, SYS_WIN32, lcid, path, redir ); + return query_typelib_path( guid, wMaj, wMin, is_win64 ? SYS_WIN32 : SYS_WIN64, lcid, path, redir ); } /****************************************************************************** @@ -1978,10 +1978,8 @@ static HRESULT TLB_size_instance(ITypeInfoImpl *info, SYSKIND sys, break; case VT_VARIANT: *size = sizeof(VARIANT); -#ifdef _WIN64 - if(sys == SYS_WIN32) - *size -= 8; /* 32-bit VARIANT is 8 bytes smaller than 64-bit VARIANT */ -#endif + if(get_ptr_size(sys) != sizeof(void*)) + *size += is_win64 ? -8 : 8; /* 32-bit VARIANT is 8 bytes smaller than 64-bit VARIANT */ break; case VT_DECIMAL: *size = sizeof(DECIMAL); @@ -2433,7 +2431,7 @@ MSFT_DoFuncs(TLBContext* pcx, if (ptfd->funcdesc.funckind == FUNC_DISPATCH) ptfd->funcdesc.oVft = 0; else - ptfd->funcdesc.oVft = (pFuncRec->VtableOffset & ~1) * sizeof(void *) / pTI->pTypeLib->ptr_size; + ptfd->funcdesc.oVft = (unsigned short)(pFuncRec->VtableOffset & ~1) * sizeof(void *) / pTI->pTypeLib->ptr_size; ptfd->funcdesc.wFuncFlags = LOWORD(pFuncRec->Flags) ; /* nameoffset is sometimes -1 on the second half of a propget/propput @@ -2611,10 +2609,9 @@ static void MSFT_DoImplTypes(TLBContext *pcx, ITypeInfoImpl *pTI, int count, } } -#ifdef _WIN64 -/* when a 32-bit typelib is loaded in 64-bit mode, we need to resize pointers +/* when a typelib is loaded in a different 32/64-bit mode, we need to resize pointers * and some structures, and fix the alignment */ -static void TLB_fix_32on64_typeinfo(ITypeInfoImpl *info) +static void TLB_fix_typeinfo_ptr_size(ITypeInfoImpl *info) { if(info->typeattr.typekind == TKIND_ALIAS){ switch(info->tdescAlias->vt){ @@ -2630,11 +2627,12 @@ static void TLB_fix_32on64_typeinfo(ITypeInfoImpl *info) break; case VT_CARRAY: case VT_USERDEFINED: - TLB_size_instance(info, SYS_WIN64, info->tdescAlias, &info->typeattr.cbSizeInstance, &info->typeattr.cbAlignment); + TLB_size_instance(info, is_win64 ? SYS_WIN64 : SYS_WIN32, info->tdescAlias, + &info->typeattr.cbSizeInstance, &info->typeattr.cbAlignment); break; case VT_VARIANT: info->typeattr.cbSizeInstance = sizeof(VARIANT); - info->typeattr.cbAlignment = 8; + info->typeattr.cbAlignment = sizeof(void *); default: if(info->typeattr.cbSizeInstance < sizeof(void*)) info->typeattr.cbAlignment = info->typeattr.cbSizeInstance; @@ -2649,7 +2647,6 @@ static void TLB_fix_32on64_typeinfo(ITypeInfoImpl *info) info->typeattr.cbAlignment = sizeof(void*); } } -#endif /* * process a typeinfo record @@ -3636,12 +3633,11 @@ static ITypeLib2* ITypeLib2_Constructor_MSFT(LPVOID pLib, DWORD dwTLBLength) } } -#ifdef _WIN64 - if(pTypeLibImpl->syskind == SYS_WIN32){ + if (pTypeLibImpl->ptr_size != sizeof(void *)) + { for(i = 0; i < pTypeLibImpl->TypeInfoCount; ++i) - TLB_fix_32on64_typeinfo(pTypeLibImpl->typeinfos[i]); + TLB_fix_typeinfo_ptr_size(pTypeLibImpl->typeinfos[i]); } -#endif TRACE("(%p)\n", pTypeLibImpl); return &pTypeLibImpl->ITypeLib2_iface; @@ -4151,7 +4147,7 @@ static void SLTG_DoFuncs(char *pBlk, char *pFirstItem, ITypeInfoImpl *pTI, if (pFuncDesc->funcdesc.funckind == FUNC_DISPATCH) pFuncDesc->funcdesc.oVft = 0; else - pFuncDesc->funcdesc.oVft = (pFunc->vtblpos & ~1) * sizeof(void *) / pTI->pTypeLib->ptr_size; + pFuncDesc->funcdesc.oVft = (unsigned short)(pFunc->vtblpos & ~1) * sizeof(void *) / pTI->pTypeLib->ptr_size; if(pFunc->magic & SLTG_FUNCTION_FLAGS_PRESENT) pFuncDesc->funcdesc.wFuncFlags = pFunc->funcflags; @@ -10688,11 +10684,9 @@ static HRESULT WINAPI ICreateTypeInfo2_fnAddFuncDesc(ICreateTypeInfo2 *iface, !funcDesc->cParams) return TYPE_E_INCONSISTENTPROPFUNCS; -#ifdef _WIN64 if(This->pTypeLib->syskind == SYS_WIN64 && funcDesc->oVft % 8 != 0) return E_INVALIDARG; -#endif memset(&tmp_func_desc, 0, sizeof(tmp_func_desc)); TLBFuncDesc_Constructor(&tmp_func_desc);
1
0
0
0
Alexandre Julliard : Revert "oleaut32: Check that the 32/64 syskind matches when getting a typelib from the cache.".
by Alexandre Julliard
15 Dec '23
15 Dec '23
Module: wine Branch: master Commit: 4ffc313d9da37c4bc6e577e680f673ff72b18c7d URL:
https://gitlab.winehq.org/wine/wine/-/commit/4ffc313d9da37c4bc6e577e680f673…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Fri Dec 15 14:30:51 2023 +0100 Revert "oleaut32: Check that the 32/64 syskind matches when getting a typelib from the cache.". This reverts commit 43e5f9e4bfa65ccea633df244a7ec0c790ed8ffb. The proper fix is more complicated. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=55962
--- dlls/oleaut32/tests/typelib.c | 34 ++++++++++++++++++++++++++++++++-- dlls/oleaut32/typelib.c | 3 +-- 2 files changed, 33 insertions(+), 4 deletions(-)
1
0
0
0
Alexandre Julliard : oleaut32/tests: Use winetest contexts instead of traces in the typelib test.
by Alexandre Julliard
15 Dec '23
15 Dec '23
Module: wine Branch: master Commit: 7760c1dbb3271ef795920d7f415b16f49d883eef URL:
https://gitlab.winehq.org/wine/wine/-/commit/7760c1dbb3271ef795920d7f415b16…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Fri Dec 15 14:26:20 2023 +0100 oleaut32/tests: Use winetest contexts instead of traces in the typelib test. --- dlls/oleaut32/tests/typelib.c | 33 +++++++++++++++------------------ 1 file changed, 15 insertions(+), 18 deletions(-) diff --git a/dlls/oleaut32/tests/typelib.c b/dlls/oleaut32/tests/typelib.c index 59b2ea7c93e..b373b0a70b3 100644 --- a/dlls/oleaut32/tests/typelib.c +++ b/dlls/oleaut32/tests/typelib.c @@ -1988,12 +1988,12 @@ static void test_CreateTypeLib(SYSKIND sys) { switch(sys){ case SYS_WIN32: - trace("testing SYS_WIN32\n"); + winetest_push_context( "win32" ); ptr_size = 4; alignment = sizeof(void*); break; case SYS_WIN64: - trace("testing SYS_WIN64\n"); + winetest_push_context( "win64" ); ptr_size = 8; alignment = 4; break; @@ -2001,8 +2001,6 @@ static void test_CreateTypeLib(SYSKIND sys) { return; } - trace("CreateTypeLib tests\n"); - hres = LoadTypeLib(wszStdOle2, &stdole); ok(hres == S_OK, "got %08lx\n", hres); @@ -2153,10 +2151,6 @@ static void test_CreateTypeLib(SYSKIND sys) { hres = ICreateTypeInfo_AddRefTypeInfo(createti, unknown, &hreftype); ok(hres == S_OK, "got %08lx\n", hres); - if(hres != S_OK) { - skip("Skipping some tests\n"); - return; - } hres = ICreateTypeInfo_AddImplType(createti, 1, hreftype); ok(hres == TYPE_E_ELEMENTNOTFOUND, "got %08lx\n", hres); @@ -3939,6 +3933,7 @@ todo_wine { ok(ITypeLib_Release(tl)==0, "Object should be freed\n"); DeleteFileA(filename); + winetest_pop_context(); } #if 0 /* use this to generate more tests */ @@ -6342,7 +6337,7 @@ static void test_dump_typelib(const WCHAR *name) BSTR bstrIfName; DWORD help_ctx; - trace("Interface %s\n", ti->name); + winetest_push_context("Interface %s", ti->name); ole_check(ITypeLib_GetTypeInfo(typelib, iface, &typeinfo)); if (hRefType) { @@ -6411,7 +6406,7 @@ static void test_dump_typelib(const WCHAR *name) UINT cNames; int i; - trace("Function %s\n", fn_info->names[0]); + winetest_push_context("Function %s", fn_info->names[0]); ole_check(ITypeInfo_GetFuncDesc(typeinfo, func, &desc)); expect_int(desc->memid, fn_info->memid); expect_int(desc->funckind, fn_info->funckind); @@ -6496,6 +6491,7 @@ static void test_dump_typelib(const WCHAR *name) memset(&cust_data, 0, sizeof(cust_data)); ITypeInfo_ReleaseFuncDesc(typeinfo, desc); + winetest_pop_context(); } for (var = 0; var < typeattr->cVars; var++) @@ -6505,7 +6501,7 @@ static void test_dump_typelib(const WCHAR *name) BSTR varname; UINT cNames; - trace("Variable %s\n", var_info->name); + winetest_push_context("Variable %s", var_info->name); ole_check(ITypeInfo_GetVarDesc(typeinfo, var, &desc)); expect_int(desc->memid, var_info->memid); @@ -6547,6 +6543,7 @@ static void test_dump_typelib(const WCHAR *name) check_type(&desc->elemdescVar, &var_info->elemdescVar); ITypeInfo_ReleaseVarDesc(typeinfo, desc); + winetest_pop_context(); } if ((typeattr->typekind == TKIND_DISPATCH) && (typeattr->wTypeFlags & TYPEFLAG_FDUAL) && @@ -6564,6 +6561,7 @@ static void test_dump_typelib(const WCHAR *name) ITypeInfo2_Release(typeinfo2); ITypeInfo_Release(typeinfo); + winetest_pop_context(); } expect_eq(ITypeLib_GetTypeInfoCount(typelib), iface, UINT, "%d"); ITypeLib_ReleaseTLibAttr(typelib, libattr); @@ -6694,14 +6692,12 @@ static void test_register_typelib(BOOL system_registration) { TKIND_MODULE, 0 }, }; - trace("Starting %s typelib registration tests\n", - system_registration ? "system" : "user"); - if (!system_registration && (!pRegisterTypeLibForUser || !pUnRegisterTypeLibForUser)) { win_skip("User typelib registration functions are not available\n"); return; } + winetest_push_context( "%s", system_registration ? "system" : "user" ); if (pIsWow64Process) pIsWow64Process(GetCurrentProcess(), &is_wow64); @@ -6720,6 +6716,7 @@ static void test_register_typelib(BOOL system_registration) win_skip("Insufficient privileges to register typelib in the registry\n"); ITypeLib_Release(typelib); DeleteFileW(filename); + winetest_pop_context(); return; } ok(hr == S_OK, "got %08lx\n", hr); @@ -6850,6 +6847,7 @@ static void test_register_typelib(BOOL system_registration) ITypeLib_Release(typelib); DeleteFileW(filename); + winetest_pop_context(); } static void test_register_typelib_64(void) @@ -7953,11 +7951,11 @@ static void test_SetTypeDescAlias(SYSKIND kind) switch(kind){ case SYS_WIN32: - trace("testing SYS_WIN32\n"); + winetest_push_context("win32"); ptr_size = 4; break; case SYS_WIN64: - trace("testing SYS_WIN64\n"); + winetest_push_context("win64"); ptr_size = 8; break; default: @@ -8002,8 +8000,6 @@ static void test_SetTypeDescAlias(SYSKIND kind) ITypeLib_Release(tl); ok(0 == ICreateTypeLib2_Release(ctl), "typelib should have been released\n"); - trace("after save...\n"); - hr = LoadTypeLibEx(filenameW, REGKIND_NONE, &tl); ok(hr == S_OK, "got %08lx\n", hr); @@ -8025,6 +8021,7 @@ static void test_SetTypeDescAlias(SYSKIND kind) ok(0 == ITypeLib_Release(tl), "typelib should have been released\n"); DeleteFileA(filenameA); + winetest_pop_context(); } static void test_GetLibAttr(void)
1
0
0
0
Alexandre Julliard : user32: Support utf-8 in WM_CHAR W->A conversion.
by Alexandre Julliard
15 Dec '23
15 Dec '23
Module: wine Branch: master Commit: 4a929eaf9702b9c7bed215c5b6f9784c2f66339c URL:
https://gitlab.winehq.org/wine/wine/-/commit/4a929eaf9702b9c7bed215c5b6f978…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Fri Dec 15 13:15:56 2023 +0100 user32: Support utf-8 in WM_CHAR W->A conversion. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=55655
--- dlls/user32/message.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/dlls/user32/message.c b/dlls/user32/message.c index 86c6593e192..07dfbdb0f85 100644 --- a/dlls/user32/message.c +++ b/dlls/user32/message.c @@ -183,9 +183,9 @@ BOOL map_wparam_AtoW( UINT message, WPARAM *wparam, enum wm_char_mapping mapping */ static void map_wparam_WtoA( MSG *msg, BOOL remove ) { - BYTE ch[4]; + BYTE ch[4] = { 0 }; WCHAR wch[2]; - DWORD len; + DWORD i, len; DWORD cp; switch(msg->message) @@ -195,7 +195,6 @@ static void map_wparam_WtoA( MSG *msg, BOOL remove ) { cp = get_input_codepage(); wch[0] = LOWORD(msg->wParam); - ch[0] = ch[1] = 0; len = WideCharToMultiByte( cp, 0, wch, 1, (LPSTR)ch, 2, NULL, NULL ); if (len == 2) /* DBCS char */ { @@ -224,14 +223,12 @@ static void map_wparam_WtoA( MSG *msg, BOOL remove ) cp = get_input_codepage(); wch[0] = LOWORD(msg->wParam); wch[1] = HIWORD(msg->wParam); - ch[0] = ch[1] = 0; - WideCharToMultiByte( cp, 0, wch, 2, (LPSTR)ch, 4, NULL, NULL ); - msg->wParam = MAKEWPARAM( ch[0] | (ch[1] << 8), 0 ); + len = WideCharToMultiByte( cp, 0, wch, 2, (LPSTR)ch, 4, NULL, NULL ); + for (msg->wParam = i = 0; i < len; i++) msg->wParam |= ch[i] << (8 * i); break; case WM_IME_CHAR: cp = get_input_codepage(); wch[0] = LOWORD(msg->wParam); - ch[0] = ch[1] = 0; len = WideCharToMultiByte( cp, 0, wch, 1, (LPSTR)ch, 2, NULL, NULL ); if (len == 2) msg->wParam = MAKEWPARAM( (ch[0] << 8) | ch[1], HIWORD(msg->wParam) );
1
0
0
0
Alexandre Julliard : kernel32/tests: Don't bother checking for errors in cleanup path.
by Alexandre Julliard
15 Dec '23
15 Dec '23
Module: wine Branch: master Commit: bd693d67553fb1f1ea3ed9bab8c38886f066e2b3 URL:
https://gitlab.winehq.org/wine/wine/-/commit/bd693d67553fb1f1ea3ed9bab8c388…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Fri Dec 15 11:03:48 2023 +0100 kernel32/tests: Don't bother checking for errors in cleanup path. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=55578
--- dlls/kernel32/tests/loader.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/dlls/kernel32/tests/loader.c b/dlls/kernel32/tests/loader.c index ec6f2d5c6a7..8f418ef09a9 100644 --- a/dlls/kernel32/tests/loader.c +++ b/dlls/kernel32/tests/loader.c @@ -2072,9 +2072,7 @@ static void test_section_access(void) test_image_mapping(dll_name, td[i].scn_page_access, FALSE); - SetLastError(0xdeadbeef); - ret = DeleteFileA(dll_name); - ok(ret, "DeleteFile error %ld\n", GetLastError()); + DeleteFileA(dll_name); } }
1
0
0
0
Alexandre Julliard : server: Enforce a mapping size limit instead of relying on the Unix file system.
by Alexandre Julliard
15 Dec '23
15 Dec '23
Module: wine Branch: master Commit: 24f7869e9385a6b6a4f2e555163deefcda109dc4 URL:
https://gitlab.winehq.org/wine/wine/-/commit/24f7869e9385a6b6a4f2e555163dee…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Fri Dec 15 10:11:22 2023 +0100 server: Enforce a mapping size limit instead of relying on the Unix file system. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=55667
--- dlls/kernel32/tests/file.c | 13 ++++++++----- server/mapping.c | 2 +- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/dlls/kernel32/tests/file.c b/dlls/kernel32/tests/file.c index 0493f90e30d..17cfe24d50a 100644 --- a/dlls/kernel32/tests/file.c +++ b/dlls/kernel32/tests/file.c @@ -3105,6 +3105,7 @@ static void test_MapFile(void) { HANDLE handle; HANDLE hmap; + UINT err; ok(test_Mapfile_createtemp(&handle), "Couldn't create test file.\n"); @@ -3123,15 +3124,17 @@ static void test_MapFile(void) ok(test_Mapfile_createtemp(&handle), "Couldn't create test file.\n"); + SetLastError( 0xdeadbeef ); hmap = CreateFileMappingA( handle, NULL, PAGE_READWRITE, 0, 0, NULL ); + err = GetLastError(); ok( hmap == NULL, "mapped zero size file\n"); - ok( GetLastError() == ERROR_FILE_INVALID, "not ERROR_FILE_INVALID\n"); - - hmap = CreateFileMappingA( handle, NULL, PAGE_READWRITE, 0x80000, 0, NULL ); - ok( hmap == NULL, "mapping should fail\n"); + ok( err == ERROR_FILE_INVALID, "got %u\n", err ); - hmap = CreateFileMappingA( handle, NULL, PAGE_READWRITE, 0x80000, 0x10000, NULL ); + SetLastError( 0xdeadbeef ); + hmap = CreateFileMappingA( handle, NULL, PAGE_READWRITE, 0x8000000, 0x10000, NULL ); + err = GetLastError(); ok( hmap == NULL, "mapping should fail\n"); + ok( err == ERROR_NOT_ENOUGH_MEMORY || err == ERROR_INVALID_PARAMETER, "got %u\n", err ); /* On XP you can now map again, on Win 95 you cannot. */ diff --git a/server/mapping.c b/server/mapping.c index a101110c76c..f754078acf7 100644 --- a/server/mapping.c +++ b/server/mapping.c @@ -993,7 +993,7 @@ static struct mapping *create_mapping( struct object *root, const struct unicode } else if (st.st_size < mapping->size) { - if (!(file_access & FILE_WRITE_DATA)) + if (!(file_access & FILE_WRITE_DATA) || mapping->size >> 54 /* ntfs limit */) { set_error( STATUS_SECTION_TOO_BIG ); goto error;
1
0
0
0
Jactry Zeng : po: Update Simplified Chinese translation.
by Alexandre Julliard
15 Dec '23
15 Dec '23
Module: wine Branch: master Commit: 3504f138ecbbe49caa1fc5242fe7e13705b0a0c6 URL:
https://gitlab.winehq.org/wine/wine/-/commit/3504f138ecbbe49caa1fc5242fe7e1…
Author: Jactry Zeng <jzeng(a)codeweavers.com> Date: Fri Dec 15 07:35:24 2023 +0100 po: Update Simplified Chinese translation. --- po/zh_CN.po | 156 ++++++++++++++---------------------------------------------- 1 file changed, 37 insertions(+), 119 deletions(-) diff --git a/po/zh_CN.po b/po/zh_CN.po index 804b97dde59..7baea6a126b 100644 --- a/po/zh_CN.po +++ b/po/zh_CN.po @@ -5,7 +5,7 @@ msgstr "" "Project-Id-Version: Wine\n" "Report-Msgid-Bugs-To:
https://bugs.winehq.org\n
" "POT-Creation-Date: N/A\n" -"PO-Revision-Date: 2023-01-16 12:26+0800\n" +"PO-Revision-Date: 2023-12-15 07:05+0100\n" "Last-Translator: Jactry Zeng <jzeng(a)codeweavers.com>\n" "Language-Team: Chinese (PRC)\n" "Language: zh_CN\n" @@ -313,7 +313,7 @@ msgstr "已下载的文件校验值错误。放弃安装已损坏的文件。" #: dlls/appwiz.cpl/appwiz.rc:47 msgid "Please wait until the current uninstall/modify process is complete." -msgstr "" +msgstr "请等待当前的卸载/修改进程完成。" #: dlls/avifil32/avifil32.rc:42 msgid "Compress options" @@ -3664,16 +3664,12 @@ msgid "High" msgstr "高" #: dlls/ir50_32/ir50_32.rc:28 -#, fuzzy -#| msgid "Index" msgid "Indeo5" -msgstr "索引" +msgstr "Indeo5" #: dlls/ir50_32/ir50_32.rc:29 -#, fuzzy -#| msgid "Wine Video 1 video codec" msgid "Indeo Video Interactive version 5 video codec" -msgstr "Wine Video 1 视频编解码器" +msgstr "Indeo Video Interactive 版本 5 视频编解码器" #: dlls/joy.cpl/joy.rc:37 msgid "Joysticks" @@ -3971,10 +3967,8 @@ msgid "Syntax error in regular expression" msgstr "正则表达式中出现语法错误" #: dlls/jscript/jscript.rc:66 -#, fuzzy -#| msgid "Expected identifier" msgid "Unexpected quantifier" -msgstr "期望标识符" +msgstr "非期望量词" #: dlls/jscript/jscript.rc:67 msgid "Exception thrown and not caught" @@ -4035,10 +4029,8 @@ msgid "'this' is not a | object" msgstr "'this' 不是 | 对象" #: dlls/jscript/jscript.rc:81 -#, fuzzy -#| msgid "'this' is not a | object" msgid "'key' is not an object" -msgstr "'this' 不是 | 对象" +msgstr "'key' 不是一个对象" #: dlls/jscript/jscript.rc:82 msgid "Property cannot have both accessors and a value" @@ -12552,10 +12544,8 @@ msgid "Duplex:" msgstr "双面:" #: dlls/wineps.drv/wineps.rc:45 -#, fuzzy -#| msgid "&Tray:" msgid "Paper &Tray:" -msgstr "托盘(&T):" +msgstr "纸盒(&T):" #: dlls/wininet/wininet.rc:53 dlls/wininet/wininet.rc:73 msgid "Realm" @@ -14519,37 +14509,29 @@ msgid "&Run..." msgstr "运行(&R)..." #: programs/explorer/explorer.rc:36 -#, fuzzy -#| msgid "E&xit Windows" msgid "E&xit desktop" -msgstr "退出 Windows(&X)" +msgstr "退出桌面(&X)" #: programs/explorer/explorer.rc:37 -#, fuzzy -#| msgid "Are you sure you want to delete these values?" msgid "" "Are you sure you want to close all programs and exit the virtual desktop?" -msgstr "您确认要删除这些值吗?" +msgstr "您确认要关闭所有程序并退出虚拟桌面吗?" #: programs/findstr/findstr.rc:28 -#, fuzzy -#| msgid "Use c&onnection string" msgid "Usage: findstr /options string\n" -msgstr "使用连接字符串(&O)" +msgstr "用法: findstr /选项 字符串\n" #: programs/findstr/findstr.rc:29 -#, fuzzy -#| msgid "Invalid command line.\n" msgid "FINDSTR: Bad command line\n" -msgstr "命令行无效。\n" +msgstr "FINDSTR: 命令行无效\n" #: programs/findstr/findstr.rc:30 msgid "FINDSTR: Cannot open %s\n" -msgstr "" +msgstr "FINDSTR: 无法打开 %s\n" #: programs/findstr/findstr.rc:31 msgid "FINDSTR: /%c ignored\n" -msgstr "" +msgstr "FINDSTR: 已忽略 /%c\n" #: programs/fsutil/fsutil.mc:28 msgid "" @@ -14667,52 +14649,39 @@ msgstr "主 DNS 后缀" #: programs/klist/klist.rc:28 msgid "Usage: klist <tickets | tgt | purge | get [service principal name]>\n" -msgstr "" +msgstr "用法: klist <tickets | tgt | purge | get [服务主体名称]>\n" #: programs/klist/klist.rc:29 -#, fuzzy -#| msgid "Unknown error" msgid "Unknown error\n" -msgstr "未知错误" +msgstr "未知错误\n" #: programs/klist/klist.rc:30 -#, fuzzy -#| msgid "Start Menu" msgid "Start Time" -msgstr "开始菜单" +msgstr "开始时间" #: programs/klist/klist.rc:31 -#, fuzzy -#| msgctxt "maximum 31 characters" -#| msgid "FLE Standard Time" msgid "End Time" -msgstr "FLE 标准时间" +msgstr "结束时间" #: programs/klist/klist.rc:32 -#, fuzzy -#| msgid "Enter new time: " msgid "Renew Time" -msgstr "输入新的时间: " +msgstr "更新时间" #: programs/klist/klist.rc:33 msgid "Ticket Flags" -msgstr "" +msgstr "票证标志" #: programs/klist/klist.rc:34 msgid "Cached Tickets" -msgstr "" +msgstr "已缓存票证" #: programs/klist/klist.rc:36 -#, fuzzy -#| msgid "Encryption Type" msgid "KerbTicket Encryption Type" -msgstr "加密类型" +msgstr "KerbTicket 加密类型" #: programs/klist/klist.rc:37 -#, fuzzy -#| msgid "Current Connections" msgid "Current LogonId is" -msgstr "当前连接数" +msgstr "当前 LogonId 是" #: programs/msinfo32/msinfo32.rc:28 msgid "System Information" @@ -14850,7 +14819,7 @@ msgstr "下列服务正在运行:\n" #: programs/net/net.rc:44 msgid "A command was used with conflicting switches.\n" -msgstr "" +msgstr "命令使用了有冲突的选项。\n" #: programs/netstat/netstat.rc:30 msgid "Active Connections" @@ -16990,38 +16959,6 @@ msgid "regsvr32: Successfully uninstalled DLL '%1'\n" msgstr "regsvr32: 成功卸载 DLL \"%1\"\n" #: programs/start/start.rc:56 -#, fuzzy -#| msgid "" -#| "Start a program, or open a document in the program normally used for " -#| "files\n" -#| "with that suffix.\n" -#| "Usage:\n" -#| "start [options] program_filename [...]\n" -#| "start [options] document_filename\n" -#| "\n" -#| "Options:\n" -#| "\"title\" Specifies the title of the child windows.\n" -#| "/d directory Start the program in the specified directory.\n" -#| "/b Don't create a new console for the program.\n" -#| "/i Start the program with fresh environment variables.\n" -#| "/min Start the program minimized.\n" -#| "/max Start the program maximized.\n" -#| "/low Start the program in the idle priority class.\n" -#| "/normal Start the program in the normal priority class.\n" -#| "/high Start the program in the high priority class.\n" -#| "/realtime Start the program in the realtime priority class.\n" -#| "/abovenormal Start the program in the abovenormal priority class.\n" -#| "/belownormal Start the program in the belownormal priority class.\n" -#| "/node n Start the program on the specified NUMA node.\n" -#| "/affinity mask Start the program with the specified affinity mask.\n" -#| "/wait Wait for the started program to finish, then exit with " -#| "its\n" -#| "exit code.\n" -#| "/unix Use a Unix filename and start the file like Windows\n" -#| "Explorer.\n" -#| "/exec Exec the specified file (for internal Wine usage).\n" -#| "/ProgIDOpen Open a document using the specified progID.\n" -#| "/? Display this help and exit.\n" msgid "" "Start a program, or open a document in the program normally used for files\n" "with that suffix.\n" @@ -17073,6 +17010,7 @@ msgstr "" "/belownormal 以 belownormal 优先级运行程序。\n" "/node n 在指定的 NUMA 节点中运行程序。\n" "/affinity 掩码 以指定的关联掩码运行程序。\n" +"/machine 架构 强制使用一个特定的架构(x86、arm、amd64、arm64)。\n" "/wait 等待运行的程序结束,并以它的返回值退出。\n" "/unix 使用 Unix 文件名并像 Windows 文件管理器一样打开该文件。\n" "/exec 执行所指定的文件 (在 Wine 内部使用)。\n" @@ -17150,27 +17088,23 @@ msgid "Error: Process self-termination is not permitted.\n" msgstr "错误: 不允许结束本进程。\n" #: programs/taskkill/taskkill.rc:44 -#, fuzzy -#| msgid "Process with PID %1!u! was forcibly terminated.\n" msgid "" "The process with PID %1!u! (child process of PID %2!u!) has been " "terminated.\n" -msgstr "已经强行结束 PID 为 %1!u! 的进程。\n" +msgstr "已经强行结束 PID 为 %1!u!(PID %2!u! 的子进程)的进程。\n" #: programs/taskkill/taskkill.rc:45 msgid "" "Sent termination signal to process with PID %1!u!, child of PID %2!u!.\n" -msgstr "" +msgstr "已向 PID %2!u! 的子进程、PID 为 %1!u! 的进程发送结束信号。\n" #: include/wine/wine_common_ver.rc:138 -#, fuzzy -#| msgid "page tab list" msgid "Wine tasklist" -msgstr "标签页列表" +msgstr "Wine 任务列表" #: programs/tasklist/tasklist.rc:29 msgid "Usage: tasklist [/?]\n" -msgstr "" +msgstr "用法: tasklist [/?]\n" #: programs/tasklist/tasklist.rc:30 programs/taskmgr/taskmgr.rc:272 msgid "Image Name" @@ -17181,38 +17115,28 @@ msgid "PID" msgstr "PID" #: programs/tasklist/tasklist.rc:32 -#, fuzzy -#| msgid "Session ID" msgid "Session Name" -msgstr "会话 ID" +msgstr "会话名称" #: programs/tasklist/tasklist.rc:33 -#, fuzzy -#| msgid "Session ID" msgid "Session#" -msgstr "会话 ID" +msgstr "会话#" #: programs/tasklist/tasklist.rc:34 programs/taskmgr/taskmgr.rc:276 msgid "Mem Usage" msgstr "内存占用" #: programs/tasklist/tasklist.rc:35 -#, fuzzy -#| msgid "OK" msgid "K" -msgstr "确定" +msgstr "K" #: programs/tasklist/tasklist.rc:36 -#, fuzzy -#| msgid "reg: Invalid syntax. " msgid "ERROR: Invalid syntax\n" -msgstr "reg: 语法无效。" +msgstr "错误: 语法无效\n" #: programs/tasklist/tasklist.rc:37 -#, fuzzy -#| msgid "The filename cannot be resolved.\n" msgid "ERROR: The search filter cannot be recognized.\n" -msgstr "不能解析文件名。\n" +msgstr "错误: 无法识别搜索筛选器。\n" #: programs/taskmgr/taskmgr.rc:37 programs/taskmgr/taskmgr.rc:108 msgid "&New Task (Run...)" @@ -18330,10 +18254,8 @@ msgid "&Theme:" msgstr "主题(&T):" #: programs/winecfg/winecfg.rc:295 -#, fuzzy -#| msgid "&Theme:" msgid "&WinRT theme:" -msgstr "主题(&T):" +msgstr "WinRT 主题(&W):" #: programs/winecfg/winecfg.rc:297 msgid "&Install theme..." @@ -18352,10 +18274,8 @@ msgid "MIME types" msgstr "MIME 类型" #: programs/winecfg/winecfg.rc:311 -#, fuzzy -#| msgid "Manage file &associations" msgid "Manage file and protocol &associations" -msgstr "管理文件关联(&A)" +msgstr "管理文件和协议关联(&A)" #: programs/winecfg/winecfg.rc:314 msgid "Folders" @@ -18458,14 +18378,12 @@ msgid "Mono" msgstr "单声道" #: programs/winecfg/winecfg.rc:98 -#, fuzzy -#| msgid "Right" msgid "Light" -msgstr "右" +msgstr "浅色" #: programs/winecfg/winecfg.rc:99 msgid "Dark" -msgstr "" +msgstr "深色" #: programs/winecfg/winecfg.rc:53 msgid ""
1
0
0
0
Alexandros Frantzis : winewayland.drv: Consider implicit fullscreen clip for pointer locking.
by Alexandre Julliard
14 Dec '23
14 Dec '23
Module: wine Branch: master Commit: bd61e918595cf1b7ac464ee4765a822650462850 URL:
https://gitlab.winehq.org/wine/wine/-/commit/bd61e918595cf1b7ac464ee4765a82…
Author: Alexandros Frantzis <alexandros.frantzis(a)collabora.com> Date: Tue Dec 12 13:52:29 2023 +0200 winewayland.drv: Consider implicit fullscreen clip for pointer locking. If the foreground window is fullscreen on the whole virtual screen, allow the pointer to be locked (if the cursor is hidden), even if we don't have an explicit fullscreen clip. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=56022
--- dlls/winewayland.drv/wayland_pointer.c | 62 +++++++++++++++++++++++----------- 1 file changed, 42 insertions(+), 20 deletions(-) diff --git a/dlls/winewayland.drv/wayland_pointer.c b/dlls/winewayland.drv/wayland_pointer.c index ccd477b3c91..3a0656b6580 100644 --- a/dlls/winewayland.drv/wayland_pointer.c +++ b/dlls/winewayland.drv/wayland_pointer.c @@ -24,7 +24,6 @@ #include "config.h" -#include <assert.h> #include <linux/input.h> #undef SW_MAX /* Also defined in winuser.rh */ #include <math.h> @@ -723,23 +722,46 @@ static void wayland_surface_calc_confine(struct wayland_surface *surface, (int *)&confine->right, (int *)&confine->bottom); } +/********************************************************************** + * wayland_surface_client_covers_vscreen + * + * Whether a surface window client area covers the whole virtual screen. + */ +static BOOL wayland_surface_client_covers_vscreen(struct wayland_surface *surface) +{ + RECT vscreen_rect, rect; + + /* Get individual system metrics to get coords in thread dpi + * (NtUserGetVirtualScreenRect would return values in system dpi). */ + vscreen_rect.left = NtUserGetSystemMetrics(SM_XVIRTUALSCREEN); + vscreen_rect.top = NtUserGetSystemMetrics(SM_YVIRTUALSCREEN); + vscreen_rect.right = vscreen_rect.left + + NtUserGetSystemMetrics(SM_CXVIRTUALSCREEN); + vscreen_rect.bottom = vscreen_rect.top + + NtUserGetSystemMetrics(SM_CYVIRTUALSCREEN); + + /* FIXME: surface->window.client_rect is in window dpi, whereas + * vscreen_rect is in thread dpi. */ + intersect_rect(&rect, &surface->window.client_rect, &vscreen_rect); + + return EqualRect(&vscreen_rect, &rect); +} + /*********************************************************************** * wayland_pointer_update_constraint * * Enables/disables pointer confinement. - * - * Passing a NULL confine_rect disables all constraints. */ -static void wayland_pointer_update_constraint(RECT *confine_rect, - struct wl_surface *wl_surface) +static void wayland_pointer_update_constraint(struct wl_surface *wl_surface, + RECT *confine_rect, + BOOL covers_vscreen) { struct wayland_pointer *pointer = &process_wayland.pointer; BOOL needs_relative, needs_lock, needs_confine; - assert(!confine_rect || wl_surface); - - needs_lock = confine_rect && !pointer->cursor.wl_surface; - needs_confine = confine_rect && pointer->cursor.wl_surface; + needs_lock = wl_surface && (confine_rect || covers_vscreen) && + !pointer->cursor.wl_surface; + needs_confine = wl_surface && confine_rect && pointer->cursor.wl_surface; if (!needs_confine && pointer->zwp_confined_pointer_v1) { @@ -838,7 +860,7 @@ static void wayland_pointer_update_constraint(RECT *confine_rect, void wayland_pointer_clear_constraint(void) { - wayland_pointer_update_constraint(NULL, NULL); + wayland_pointer_update_constraint(NULL, NULL, FALSE); } /*********************************************************************** @@ -858,27 +880,27 @@ BOOL WAYLAND_ClipCursor(const RECT *clip, BOOL reset) { struct wayland_pointer *pointer = &process_wayland.pointer; struct wl_surface *wl_surface = NULL; + struct wayland_surface *surface = NULL; + BOOL covers_vscreen = FALSE; RECT confine_rect; TRACE("clip=%s reset=%d\n", wine_dbgstr_rect(clip), reset); - if (clip) + if ((surface = wayland_surface_lock_hwnd(NtUserGetForegroundWindow()))) { - struct wayland_surface *surface = NULL; - - if ((surface = wayland_surface_lock_hwnd(NtUserGetForegroundWindow()))) - { - wl_surface = surface->wl_surface; - wayland_surface_calc_confine(surface, clip, &confine_rect); - pthread_mutex_unlock(&surface->mutex); - } + wl_surface = surface->wl_surface; + if (clip) wayland_surface_calc_confine(surface, clip, &confine_rect); + covers_vscreen = wayland_surface_client_covers_vscreen(surface); + pthread_mutex_unlock(&surface->mutex); } /* Since we are running in the context of the foreground thread we know * that the wl_surface of the foreground HWND will not be invalidated, * so we can access it without having the surface lock. */ pthread_mutex_lock(&pointer->mutex); - wayland_pointer_update_constraint(wl_surface ? &confine_rect : NULL, wl_surface); + wayland_pointer_update_constraint(wl_surface, + (clip && wl_surface) ? &confine_rect : NULL, + covers_vscreen); pthread_mutex_unlock(&pointer->mutex); wl_display_flush(process_wayland.wl_display);
1
0
0
0
← Newer
1
...
4
5
6
7
8
9
10
...
42
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
Results per page:
10
25
50
100
200