Alexandre Julliard
610db32153
kernelbase: Cache the sortid for each locale.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-16 20:46:49 +02:00
Alexandre Julliard
093f6cbb8c
kernelbase: Move get_language_sort() to avoid forward declarations.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-16 20:46:49 +02:00
Rémi Bernon
074177b8b0
ntdll: Rewrite RtlWalkHeap and enumerate large blocks.
...
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-13 22:11:41 +02:00
Nikolay Sivov
1336f5966f
kernelbase/tests: Close mapping in MapViewOfFile3 test.
...
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=52970
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-12 12:34:17 +02:00
Nikolay Sivov
1e2bc2f50e
kernel32: Implement UnmapViewOfFileEx().
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-06 19:17:01 +02:00
Francois Gouget
48d538ba82
kernelbase/tests: Loosen up the Sleep() test lower bound.
...
It looks like Windows tries to work around the timer granularity by
sometimes returning early such that the total may be a bit less than
requested.
Signed-off-by: Francois Gouget <fgouget@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-06 19:16:48 +02:00
Nikolay Sivov
757f9e9751
kernelbase: Implement UnmapViewOfFile2().
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-05 18:35:38 +02:00
Nikolay Sivov
9c40a80100
kernelbase: Implement MapViewOfFile3().
...
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-04 21:27:25 +02:00
Alexandre Julliard
dc37b66d17
kernelbase: Reimplement GetTimeFormatA().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-04 08:56:25 +02:00
Alexandre Julliard
fc26407e8e
kernelbase: Reimplement GetDateFormatA().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-04 08:55:45 +02:00
Alexandre Julliard
1b127e24dc
kernelbase: Reimplement GetTimeFormatW/Ex() using get_locale_info().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-04 08:55:19 +02:00
Alexandre Julliard
6ccdd7f8f5
kernelbase: Reimplement GetDateFormatW/Ex() using get_locale_info().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-04 08:51:43 +02:00
Alexandre Julliard
9afc20949a
kernelbase: Reimplement GetCurrencyFormatW/Ex() using get_locale_info().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-03 12:26:28 +02:00
Alexandre Julliard
56099a3124
kernelbase: Reimplement GetNumberFormatW/Ex() using get_locale_info().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-03 12:26:28 +02:00
Alexandre Julliard
ea1eae646d
kernelbase: Implement ResolveLocaleName().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-02 14:12:10 +02:00
Alexandre Julliard
d6effa7282
kernelbase: Add support for storing LOCALE_SINTLSYMBOL in the registry.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-27 14:51:39 +02:00
Alexandre Julliard
b3e0d8db5d
kernelbase: Really skip alternate sorts in EnumUILanguagesW().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-26 22:21:04 +02:00
Alexandre Julliard
f3b77b8027
kernelbase: Use the digit table from locale.nls in FoldStringW().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-25 11:53:53 +02:00
Alexandre Julliard
ccbb341a8c
kernelbase: Use the mapping tables from locale.nls in LCMapStringEx().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-25 11:53:46 +02:00
Rémi Bernon
c0584779f8
kernelbase: Allocate global memory handle table dynamically.
...
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=52763
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-20 17:51:04 +02:00
Alexandre Julliard
e81327358a
kernelbase: Move codepage initialization to ntdll.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-13 16:08:30 +02:00
Alexandre Julliard
d53bc38d34
ntdll: Initialize the system locale on the Unix side.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-13 16:03:14 +02:00
Zebediah Figura
351fa352f6
kernelbase: Set user_lcid to the user locale, not the system locale.
...
Fixes: fffbe3fcae
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-13 10:42:59 +02:00
Eric Pouech
eff83cd4e0
kernelbase: Provide a pseudo console environment for initial CUI processes not tied to a Unix tty.
...
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=52771
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=52761
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=52743
Signed-off-by: Eric Pouech <eric.pouech@gmail.com>
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-12 21:39:42 +02:00
Jacek Caban
b4d91adb16
kernelbase: Add support for CREATE_NO_WINDOW flag in CreateProcess.
...
Based on patches by Eric Pouech and Torge Matthies.
Signed-off-by: Eric Pouech <eric.pouech@gmail.com>
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-12 21:39:42 +02:00
Paul Gofman
02faaea93b
kernelbase: Reset last error on success in CopyFileExW().
...
Signed-off-by: Paul Gofman <pgofman@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-11 21:15:56 +02:00
Alexandre Julliard
1790546d03
kernelbase: Support UTF-8 as default Ansi codepage in WideCharToMultiByte().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-11 17:34:48 +02:00
Alexandre Julliard
2cc54d4b85
kernelbase: Support UTF-8 as default Ansi codepage in MultiByteToWideChar().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-11 17:34:48 +02:00
Alexandre Julliard
8993e15cfa
kernelbase: Support UTF-7/8 codepages in get_codepage_table().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-11 17:34:48 +02:00
Alexandre Julliard
fd2ecee06f
kernelbase: Avoid redundant locale lookups in GetLocaleInfoA().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-11 17:34:48 +02:00
Alexandre Julliard
23834ee3b8
kernelbase: Use RtlMultiByteToUnicodeN in IsChar* functions.
...
In case the Ansi codepage was set to UTF-8.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-11 17:34:48 +02:00
Alexandre Julliard
4d68497fac
kernelbase: Reimplement Internal_EnumDateFormats() using the locale.nls data.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-07 22:44:39 +02:00
Alexandre Julliard
25595a0abe
kernelbase: Reimplement Internal_EnumTimeFormats() using the locale.nls data.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-07 22:44:39 +02:00
Alexandre Julliard
8576c3e131
kernelbase: Reimplement Internal_EnumCalendarInfo() using the locale.nls data.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-07 22:44:39 +02:00
Alexandre Julliard
6517f6c239
kernelbase: Implement NlsValidateLocale().
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-07 22:44:39 +02:00
Alexandre Julliard
812ebc67a4
kernelbase: Fix IsValidLocale() and GetLocaleInfo() with special LOCALE_* identifiers.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-07 22:44:39 +02:00
Alexandre Julliard
a074d0c3a8
kernelbase: Reimplement GetCalendarInfoEx/W using the locale.nls data.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-05 16:59:09 +02:00
Rémi Bernon
dee510bd32
kernelbase: Use the same HLOCAL flags / lock layout as native.
...
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-04 18:40:26 +02:00
Rémi Bernon
4f596c04be
kernelbase: Remove unnecessary handler from LocalUnlock.
...
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-04 18:40:26 +02:00
Rémi Bernon
e358731f96
kernelbase: Remove unnecessary handler from LocalLock.
...
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-04 18:40:26 +02:00
Rémi Bernon
2fcb072f03
kernelbase: Use the same HLOCAL entry pointer alignment as native.
...
This changes the GlobalUnlock todo_wine as we previously considered the
invalid mem handle as a valid pointer, and we now instead check handle
validity.
Returning TRUE in for an invalid handle doesn't seem very important, and
a corner case, and it breaks compatibility and imm32 tests.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-04 18:40:26 +02:00
Alexandre Julliard
c30626505b
kernelbase: Check the locale name instead of the LCID to detect changes.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-01 20:30:57 +02:00
Alexandre Julliard
c0ff1a221b
kernelbase: Set system/user locales by name if they have no LCID.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-01 20:30:57 +02:00
Rémi Bernon
3c9d2cbaea
kernelbase: Allocate HLOCAL / HGLOBAL from a static handle table.
...
Sharing the table pointers through KernelBaseGetGlobalData to check for
handle validity in kernel32, and as native does it.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-31 22:02:51 +02:00
Rémi Bernon
981283a50b
kernelbase: Implement internal KernelBaseGetGlobalData.
...
And call it from kernel32 to get access to kernelbase global data.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-31 22:02:51 +02:00
Rémi Bernon
82bab8366d
kernelbase: Check pointer validity in unsafe_ptr_from_HLOCAL.
...
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-31 21:25:44 +02:00
Rémi Bernon
458f49dee1
kernelbase: Check handle validity in unsafe_mem_from_HLOCAL.
...
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-31 21:25:39 +02:00
Alexandre Julliard
689e63485c
kernel32: Move the error message table to kernelbase.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-31 10:57:07 +02:00
Alexandre Julliard
6d06171485
kernel32: Move the language group resources to kernelbase.
...
And enable translating them through the po files.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-31 10:57:07 +02:00
Alexandre Julliard
86baeafc76
kernelbase: Reimplement the Geo ID functions using the locale.nls data.
...
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-03-31 07:46:13 +02:00