Commit graph

1127 commits

Author SHA1 Message Date
Katayama Hirofumi MZ 5d5cc57869
[NTUSER] Implement NtUserSetImeHotKey (#4350)
- Modify NtUserGetImeHotKey and NtUserSetImeHotKey prototypes.
- Define enum SETIMEHOTKEY_ACTION in <undocuser.h>.
- Define IMEHOTKEY structure in ime.c.
- Add IntGetImeHotKeyLangId, IntAddImeHotKey, IntGetImeHotKeyById, IntGetImeHotKeyByKeyAndLang, IntDeleteImeHotKey, IntFreeImeHotKeys, and IntSetImeHotKey helper functions.
- Implement NtUserGetImeHotKey and NtUserSetImeHotKey functions.
- Cleanup the IME hotkeys at process exit.
CORE-11700
2022-02-09 11:27:44 +09:00
Hermès Bélusca-Maïto 2ae45e0985
[CONCFG:FONT] Implement support for the Windows 10 "__DefaultTTFont__" special FaceName value. (#4337)
This special value tells the console to default to whichever font
is deemed most appropriate for the current code page.

Add Doxygen documentation for FindCachedTTFont().
2022-02-08 15:59:10 +01:00
Hermès Bélusca-Maïto 0b6b0b0021
[CONCFG:FONT] Convert the TT_FONT_ENTRY structure to one similar to MS Terminal's _TT_FONT_LIST. (#4337)
See the definition of struct _TT_FONT_LIST
in https://github.com/microsoft/terminal/blob/main/dep/Console/winconp.h

Add Doxygen documentation.

[CONSOLE.CPL][CONSRV] "fonts cache" -> "font cache".
2022-02-08 15:59:08 +01:00
Hermès Bélusca-Maïto 5d3915d0fc
[CONCFG:FONT][CONSRV] Use a suitable font when changing console output CP; fail if none found. (#4337)
CORE-12451, CORE-17601, CORE-17803
Replaces PR #4281.

When changing the console output code page, check whether the current
font can support it. If not, try to find a suitable font for the new
code page. If none can be found:

- if we are creating a new console, forcefully switch to codepage 437
  (OEM USA) and retry finding a font, falling back to "Terminal" if
  none could be found;

- if we were just changing the current CP, just fail and keep the old
  code page and font.

Rework the console font selection/creation functions for this new job
(see CreateConsoleFontEx() and friends). Elements of implementation
based from https://github.com/microsoft/terminal ; see code for more
information.

Silence the noisy IsValidConsoleFont2() diagnostic messages.

Add Doxygen documentation.

[CONSOLE.CPL] Only add "Terminal" to the enumerated list of faces
+ add a TODO implementation comment.
2022-02-08 15:59:07 +01:00
Hermès Bélusca-Maïto 3e44a5d71c
[KERNEL32][CONSRV] Retrieve the best-suited language ID corresponding to the active console output code page. (#4301)
CORE-17601, CORE-17803
Replaces PR #4281.

Implement SrvGetConsoleLangId() (server-side) and set the new current
thread's locale after connecting to a console, or changing its output
code page.

Based on API tracing on Windows 2003, as well as on comments and code
gathered from: https://github.com/microsoft/terminal

Tests results are listed in PR #4301.
2022-02-08 15:58:02 +01:00
Katayama Hirofumi MZ 9db4437185
[NTUSER] Implement NtUserNotifyIMEStatus (#4345)
- Define "the special virtual keys for Japanese".
- Add UserSetImeConversionKeyState helper function.
- Implement NtUserNotifyIMEStatus function.
CORE-11700
2022-02-08 12:22:08 +09:00
Katayama Hirofumi MZ 61d4b5fd6c
[NTUSER] Cleanup the window lists (#4346)
Cleanup the window lists that are no longer needed at the thread / process termination.
CORE-11700
2022-02-08 12:21:05 +09:00
Katayama Hirofumi MZ 1bc9dda5e6
[NTUSER] Rewrite NtUserDestroyInputContext (#4342)
CORE-11700
2022-02-07 10:45:02 +09:00
Katayama Hirofumi MZ f2c3167db3
[NTUSER] Implement NtUserAssociateInputContext (#4334)
- Add IntReAllocatePoolWithTag function in window.c.
- Define WINDOWLIST structure in "window.h".
- Add IntBuildHwndList and IntFreeHwndList helper functions in window.c.
- Add IntAssociateInputContext and IntAssociateInputContextEx helper functions in ime.c.
- Implement NtUserAssociateInputContext function.
CORE-11700
2022-02-05 20:23:57 +09:00
Joachim Henze bf16435303 [WIN32SS] Remove an ambiguous assert entirely CORE-16738
It popped up very reliably when performing git-clone of the ros sources
while having the taskmgr open in the processes-tab.
Or when building 'ninja bootcd -j1' while having the taskmgr open in the processes-tab.

It is always possible to ignore it and then continue using ros for days without
noticing any side effects.
James Tabor judged the assert to have a "questionable logic".
Giannis who once added it, was also ok with commenting it.

His words:
This assertion isn't something fatal,
the worst thing that can happen from continuing on it would be
to make the thread get awake more times than it should.

It was commented out already on 2020-04-21 via
0.4.14-dev-1519-g 87f6c82d85
2022-02-05 01:06:15 +01:00
Hermès Bélusca-Maïto f79c02bd8a
[CONSRV] Introduce a CON_SET_OUTPUT_CP() macro to simplify setting the console's output CP + associated changes. Simplify ConDrvSetConsoleCP() as well. 2022-02-04 21:35:15 +01:00
Katayama Hirofumi MZ 0519ae0ac5
[NTUSER] Half-implement NtUserSetImeOwnerWindow (#4332)
- Add some code to NtUserSetImeOwnerWindow function.
- Add IntGetTopLevelWindow helper function.
CORE-11700
2022-02-03 13:39:15 +09:00
Katayama Hirofumi MZ 8c6dcdcf81
[USER32] Implement ImeWnd_OnImeSetContext (#4329)
- Modify NtUserSetImeOwnerWindow prototype.
- Add User32GetTopLevelWindow function.
- Add ImeWnd_OnImeSetContext function.
- Implement WM_IME_SETCONTEXT message handling of the IME window.
CORE-11700
2022-02-02 11:58:31 +09:00
Katayama Hirofumi MZ 470aa27610
[NTUSER] Move IMM-related code to ime.c (#4322)
Move the IMM-related code from ntstubs.c into ime.c.
CORE-11700
2022-02-02 11:56:40 +09:00
Katayama Hirofumi MZ 99614febad
[USER32] Add ImeWnd_OnImeSystem (#4327)
- Add WM_IME_SYSTEM message handling of the IME window.
- Modify immtable.h.
CORE-11700
2022-01-31 21:20:08 +09:00
Katayama Hirofumi MZ 173fca6ed6 [NTUSER] UserIsDBCSEnabled: Vietnamese doesn't use DBCS
CORE-11700
2022-01-31 09:33:19 +09:00
Katayama Hirofumi MZ fbab1914a6
[USER32] Don't delay-load-link to imm32.dll (#4328)
Reduce binary size.
- Don't directly call the IMM32 functions. Use IMM_FN instead.
- Modify CMakeLists.txt to unlink imm32.dll.
CORE-11700
2022-01-31 09:30:47 +09:00
Katayama Hirofumi MZ d735373e46 [USER32] Improve RegisterIMEClass function
CORE-11700
2022-01-31 04:21:45 +09:00
Katayama Hirofumi MZ c339105b0d
[NTUSER] Implement GetSystemMetrics.SM_DBCSENABLED (#4317)
- Add UserIsDBCSEnabled helper function.
- Support SM_DBCSENABLED value of GetSystemMetrics function.
CORE-11700
2022-01-30 11:23:22 +09:00
Katayama Hirofumi MZ df8c74e78b
[INCLUDE] Rename <ddk/imm.h> as <ddk/immdev.h> (#4321)
- Rename <ddk/imm.h> as <ddk/immdev.h>.
- Delete sdk/include/reactos/wine/imm.h (this header is confusing and nonsense).
- Changes related to it.
CORE-11700
2022-01-30 09:38:04 +09:00
Hermès Bélusca-Maïto 3b76aa5d19
[CONCFG] Rewrite the InitTTFontCache() registry enumeration loop. 2022-01-30 01:02:09 +01:00
Hermès Bélusca-Maïto f650cbdb68
[CONCFG] IsValidConsoleFont(): Validate font against charset corresponding to selected code page. 2022-01-30 01:02:04 +01:00
Hermès Bélusca-Maïto 1530a678a8
[CONCFG:FONT] Add SAL annotations. 2022-01-30 01:01:58 +01:00
Katayama Hirofumi MZ 3fc83b4361
[USER32] Implement ImeWnd_OnImeControl (#4320)
- Add IMC_GETCONVERSIONMODE, IMC_GETSENTENCEMODE, IMC_GETOPENSTATUS, IMC_GETSOFTKBDPOS, and IMC_SETSOFTKBDPOS macros into <ddk/imm.h>.
- Implement WM_IME_CONTROL message handling of the IME window.
CORE-11700
2022-01-29 10:35:48 +09:00
Katayama Hirofumi MZ 82136b3ee4
[USER32] Implement ImeWnd_OnImeNotify (#4318)
- Modify CMakeLists.txt to include <ddk/imm.h>
- Implement WM_IME_NOTIFY message handling of the IME window.
CORE-11700
2022-01-28 19:21:21 +09:00
Katayama Hirofumi MZ 23bb27037d
[USER32] Implement User32CreateImeUI (#4316)
Implementing Japanese input...
- Add User32CreateImeUIWindow, User32GetImeShowStatus, User32SendImeUIMessage, User32UpdateImcOfImeUI, User32SetImeWindowOfImc and User32NotifyOpenStatus helper functions.
- Add WM_IME_SELECT, WM_IME_COMPOSITION, WM_IME_STARTCOMPOSITION and WM_IME_ENDCOMPOSITION message handling of the IME window.
- Rename ImeWnd_OnDestroy as User32DestroyImeUIWindow.
- Rename CheckIMCForWindow as User32CanSetImeWindowToImc.
- Improve ImeWnd_OnCreate function.
CORE-11700
2022-01-27 21:19:37 +09:00
Katayama Hirofumi MZ fc62d268d2
[USER32] Implement WM_CREATE of IME window (#4314)
Implement handling of WM_CREATE and WM_DESTROY messages of the IME window.
CORE-11700
2022-01-27 07:30:11 +09:00
Katayama Hirofumi MZ 9c8167e90a
[NTUSER] Implement NtUserGetAppImeLevel and NtUserSetAppImeLevel (#4313)
- Add AtomImeLevel atom.
- Modify NtUserSetAppImeLevel prototype.
- Implement NtUserGetAppImeLevel and NtUserSetAppImeLevel functions.
CORE-11700
2022-01-27 07:29:19 +09:00
Hervé Poussineau 963e76fd60 [VIDEOPRT] Fix typo: DEViCEMAP -> DEVICEMAP 2022-01-26 19:30:32 +01:00
Hervé Poussineau 1add6de3e8 [VIDEOPRT] Change case of device registry path written to registry
Change it it two places, to handle when 'UseNewKey' is enabled or disabled.

This fixes the Spice guest agent, which searches 'System' case-sensitively in it.
2022-01-26 19:30:32 +01:00
Hervé Poussineau b80d806e05 [VIDEOPRT] Honour UseNewKey setting in registry
This changes:
- which device key is written to DEVICEMAP\Video
- which registry key is used in VideoPortSetRegistryParameters()

CORE-17896
2022-01-26 19:30:32 +01:00
Katayama Hirofumi MZ 1cad26ad08 [USER32] Fix uninitialized cbTotal
CORE-18025
2022-01-26 08:14:59 +09:00
Katayama Hirofumi MZ 5972c0c18b [USER32] Fix release build C4700 CORE-16287 2022-01-25 21:57:47 +09:00
Katayama Hirofumi MZ 0360abb796
[USER32] Follow-up of #4262 (a47590c) (#4312)
Display icons/cursors correctly without hungup. CORE-16287
2022-01-25 20:41:00 +09:00
Katayama Hirofumi MZ 41b87158ff
[NTUSER] Improve NtUserGetThreadState (#4300)
- Improve enum ThreadStateRoutines.
- Improve NtUserGetThreadState function.
- Improve CLIENTIMC structure.
- Improve imm32 code.
CORE-17732
2022-01-20 11:49:27 +09:00
Julio Carchi 292e6a429f
[NTUSER] Initialize correctly CaretWidth value. (#4297) CORE-13984 CORE-14359 CORE-16624
Fixes:
CORE-13984 LibreOffice Writer shows no blinking caret
CORE-14359 Apache Open Office 4.1.2 SWriter - no blinking Caret
CORE-16624 KVIRC, no blinking caret in configuration edit controls
2022-01-18 00:36:49 +01:00
Katayama Hirofumi MZ ce6da820a4
[NTUSER] Implement NtUserBuildHimcList (#4286)
- Add UserBuildHimcList helper function.
- Implement NtUserBuildHimcList function.
CORE-11700
2022-01-16 09:56:18 +09:00
Katayama Hirofumi MZ 2250ce80f3
[USER32] Adjust the threshold in CascadeWindows (#4283)
Improve the threshold of CascadeWindows function not to make the windows too small.
2022-01-16 09:54:44 +09:00
Hermès Bélusca-Maïto 1ffe431827
[CONSRV] Trivially implement TuiSetCodePage(). CORE-17601 2022-01-15 17:41:36 +01:00
Hermès Bélusca-Maïto 9f201d462d
[BLUE][CONSRV][USETUP] Completely remove support for CAB font extraction from driver, and move it to CONSRV, much like what was done for USETUP.
Addendum to aaa416d3 and 2391e31c.
2022-01-15 17:41:36 +01:00
Hermès Bélusca-Maïto ac2494994b
[CONSRV] Stub out support for terminal-level changing of output code page.
CORE-17601
2022-01-15 17:41:34 +01:00
Chan Chilung 171a920680
[TRANSLATION] Update Chinese Traditional (zh-TW) translation (#4154)
- Added translation for:
  - [W32TIME]
  - [MODE]
  - [TIMEOUT]
  - [MODEMUI]
  - [ARPING]
  - [FRAGINATOR]
  - and more
- Updated existing translation
- [WINNLS] Update cht (zh-TW) and zhh (zh-HK)
- [DOC] Update rules in Chinese translation notes.txt
- Wine translation sync

Some of the punctuation use in WIne has been converted to half-width,
so the punctuation will no longer synced.
2022-01-14 20:22:46 +03:00
Katayama Hirofumi MZ 2ea30b2ed3 [USERSRV][TRANSLATION] Improve Japanese (ja-JP.rc) 2022-01-13 14:09:03 +09:00
Katayama Hirofumi MZ 48827cf6c5 [NTUSER] Follow-up of #4277 (ea1353e)
According to ThFabba, NtUserSetThreadLayoutHandles returns zero.
CORE-11700
2022-01-13 10:41:03 +09:00
Katayama Hirofumi MZ ea1353e4be
[NTUSER] Implement NtUserSetThreadLayoutHandles (#4277)
- Modify NtUserSetThreadLayoutHandles prototype.
- Implement NtUserSetThreadLayoutHandles function.
CORE-11700
2022-01-12 14:48:20 +09:00
Katayama Hirofumi MZ 28959a2dfd [NTUSER] Follow-up of #4271 (36740ca)
- Delete the excessive comments.
- Delete the debugging leftover.
CORE-11700
2022-01-12 14:08:10 +09:00
Katayama Hirofumi MZ 1f44693657
[NTUSER] Implement NtUserSetImeInfoEx (#4276)
- Modify NtUserSetImeInfoEx prototype.
- Add UserSetImeInfoEx helper function.
- Implement NtUserSetImeInfoEx function.
CORE-11700
2022-01-12 12:07:31 +09:00
Katayama Hirofumi MZ 36740ca981
[NTUSER][IMM32] Implement NtUserGetImeInfoEx (#4271)
- Add UserGetImeInfoEx helper function.
- Implement NtUserGetImeInfoEx function by using UserGetImeInfoEx.
- Fix imm32.ImmGetImeInfoEx.
- Modify enum IMEINFOEXCLASS.
CORE-11700
2022-01-12 12:06:24 +09:00
Doug Lyons a47590c9cf
[USER32] Improve icon extraction to handle RIFF formats and Fix crash (#4262)
- Add handling for 'RIFF' formats (for animated cursors). This makes explorer able to display animated cursors.
- Fix crash in extracting icons/cursors.
CORE-16287
2022-01-12 08:03:44 +09:00
Hervé Poussineau 2538583dbe [VIDEOPRT] Query children only when device has been opened
HwGetVideoChildDescriptor callback must be called only after HwInitialize.

CORE-17979
2022-01-06 22:02:07 +01:00
Hervé Poussineau 983d9a1c2a [VBEMP] Disable reporting multiple monitors
It has never worked, and only leads to some infinite loops with some hardware or BIOS configurations.
2022-01-06 20:16:12 +01:00
Hervé Poussineau f03750de6a [VBEMP] Rename to vgapnp.sys
- rename driver vbemp.sys to vgapnp.sys
- rename service VBE to vga
- store settings in non hardware-profile registry key
2022-01-06 20:16:12 +01:00
Hervé Poussineau 073a1ea34c [VGAMP] Rename to vga.sys
- rename driver vgamp.sys to vga.sys
- rename service Vga to VgaSave
- store settings in non hardware-profile registry key
2022-01-06 20:16:12 +01:00
Hervé Poussineau 0d9386d0e0 [VGA_NEW] Disable it for now 2022-01-06 17:47:45 +01:00
Serge Gautherie 40b9ee0ae0
[VIDEOPRT] Match Zw*Key() DesiredAccess values (#4145)
Even if the kernel mode does not care, this makes it clear.
2022-01-06 04:04:09 +03:00
Katayama Hirofumi MZ 8e8f61989a
[NTUSER] Plan A: UserDereferenceObject in UserCreateInputContext (#4247)
- Call UserDereferenceObject function in UserCreateInputContext.
- Don't call UserDereferenceObject against input context at the other places.
CORE-11700
2022-01-05 08:15:32 +09:00
Stanislav Motylkov 27955da7ee
[WIN32K:NTUSER] Fix one more reference leak
Addendum to d5deacd9 and 2a2f8dbe. CORE-11700
2022-01-04 03:12:12 +03:00
Thomas Faber 2a2f8dbebd
[WIN32K:NTUSER] Fix reference leak 2022-01-03 13:25:09 -05:00
Thomas Faber 49bb853b24
[GDI32_VISTA] Move D3DKMT functions out of gdi32. CORE-17433 2022-01-01 12:42:04 -05:00
Katayama Hirofumi MZ 757bed81b1
[NTUSER] Fix KVM and VBox tests (#4235)
KVM and VBox tests was failing since d5deacd
- Check NULL at UserFreeInputContext and UserDestroyInputContext functions.
- Move UserMarkObjectDestroy into the UserDestroyInputContext function.
CORE-11700
2022-01-02 01:40:11 +09:00
Katayama Hirofumi MZ d5deacd903
[NTUSER] Implement NtUserCreateInputContext (#4230)
- Modify NtUserCreateInputContext prototype.
- Add UserCreateInputContext helper function.
- Implement NtUserCreateInputContext function by using UserCreateInputContext.
- Call UserCreateInputContext(0) in InitThreadCallback function to create the default input context.
CORE-11700
2022-01-01 20:59:00 +09:00
Katayama Hirofumi MZ ba3affe5f7
[NTUSER] Implement NtUserUpdateInputContext (#4228)
- Modify NtUserUpdateInputContext prototype.
- Implement NtUserUpdateInputContext function.
- Add enum UPDATE_INPUT_CONTEXT (UIC_*) to undocuser.h.
CORE-11700
2022-01-01 20:57:51 +09:00
Katayama Hirofumi MZ cdf3b5e85a
[NTUSER] Implement NtUserQueryInputContext (#4227)
Co-authored-by: Hermès BÉLUSCA - MAÏTO <hermes.belusca-maito@reactos.org>
- Modify NtUserQueryInputContext prototype.
- Implement NtUserQueryInputContext function.
- Add enum QUERY_INPUT_CONTEXT (QIC_*) to undocuser.h.
CORE-11700
2022-01-01 20:56:50 +09:00
Katayama Hirofumi MZ fcc222c28a
[NTUSER] Implement NtUserDisableThreadIme (#4216)
CORE-11700
2021-12-31 10:20:53 +09:00
Chan Chilung 81db5e1da8
[TRANSLATION] Add Hong Kong Chinese (zh-HK) translation - Part 1 (#3941)
Converted from Cantonese to HK-Style Written Chinese.

Also assign zh-HK translations to the ReactOS Chinese
translation team in the CODEOWNERS file.

Reviewed-by: He Yang <1160386205@qq.com>
Reviewed-by: Stanislav Motylkov <x86corez@gmail.com>
Reviewed-by: Hermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
2021-12-30 00:40:57 +03:00
Oleg Dubinskiy dc483bd700
[WIN32SS:ENG] EngCreateBitmap: mark created bitmaps as API bitmaps (#4146)
CORE-17561

Set the API_BITMAP flag for bitmaps created by EngCreateBitmap().

This avoids failure when created bitmap is passed to NtGdiSelectBitmap(), since it checks for this flag and fails if it isn't set.
Otherwise, if failure occurs, the bitmap is hot handled properly.
Setting this flag outside of that function is not an option at all, because it is a public (exported) function, and in many cases it's called directly by the caller (in case with MS DDraw stack, it can be called also by dxg.sys from dxgthk!EngCreateBitmap, which directly calls win32k!EngCreateBitmap).

In particular, it allows Windows XP/2003 DirectDraw stack (ddraw.dll & dxg.sys) to properly work in ReactOS (in software emulation mode), even on real hardware. So now, a lot of DirectX 1-7 apps and games (whose can work withoug hardware acceleation), are working properly with ddraw.dll + dxg.sys replacement! Also Justin Miller (DarkFire01) confirmed that even Direct3D software emulation now also works correctly on real hardware!
2021-12-29 16:51:23 +01:00
Katayama Hirofumi MZ 051561ed17
[NTUSER] Use call procedure handle if available (#4178)
Based on I_Kill_Bugs' patch.
- Use IsCallProcHandle to check if the procedure is a call procedure handle.
- If so, use the call procedure.
CORE-10499
2021-12-23 11:53:18 +09:00
Oleg Dubinskiy 8a6312abda
[WIN32SS][NTDDRAW] Improve DxEngGetDCState type 2 implementation (#4176)
- Use the REGION_Complexity() function to get the actual region complexity instead of just number of rectangles.
- Don't use prgnRao at all, because it is always uninitialized when passed to the function. So in condition between prgnRao and prgnVis, the 2nd one always succeeds.
- Update the comment accordingly.
- Additionally, add a DPRINT to the end of the function, which displays the returned value.

This allows to properly enable and use DirectDraw and Direct3D hardware acceleration with the following MS DirectX components: ddraw.dll, d3d8.dll, d3d9.dll and dxg.sys. As in VM, same on real hardware.
But note that now the bugcheck 0x50 (PAGE_FAULT_IN_NONPAGED_AREA) occurs when executing fullscreen DDraw apps, after switching display mode. It's unhidden by this fix.
Addendum to 855bf46.
CORE-17561
2021-12-20 21:27:13 +01:00
Serge Gautherie d375b7f6c5
[WIN32K:NTUSER] Make sure to hold User Global Lock before mapping desktop heap (#4144)
Addendum to 8c098ee8d.
CORE-17890
2021-12-19 23:34:35 +01:00
Doug Lyons 7d1b50394b
[WIN32SS] Do not remove message from the Msg Queue if it is not for us. (#4129)
CORE-8217
Patch from 'I_Kill_Bugs' contributor.
2021-12-19 16:03:22 +01:00
Katayama Hirofumi MZ f643fb301b [NTUSER] Fix SwitchToThisWindow
Taskbar task buttons were not working correctly due to this bug.
CORE-17911
2021-12-17 11:38:23 +09:00
Katayama Hirofumi MZ e3622ebe4e
[NTGDI] Strictly check pen style (#4164)
- Check the pen style and elegantly fail if the style was wrong.
CORE-13819
2021-12-16 10:47:57 +09:00
Katayama Hirofumi MZ 0b6f3eb8e4
[NTUSER][USER32] Use async way in TileWindows and CascadeWindows (#4167)
Processing asynchronously. CORE-17894
2021-12-16 09:52:02 +09:00
Katayama Hirofumi MZ 55a1c29341
[NTUSER][USER32] Simplify SwitchToThisWindow (#4153)
CORE-17894
2021-12-13 08:14:33 +09:00
Katayama Hirofumi MZ 8c9b6fdb5c
[USER32] Partially fix freezing of Task Switcher (#4148)
- Use SendMessageTimeout instead of SendMessage.
- Use SwitchToThisWindow instead of BringWindowToTop.
- Use ShowWindowAsync instead of ShowWindow.
- Use SWP_ASYNCWINDOWPOS for SetWindowPos.
CORE-17894
2021-12-10 13:37:43 +09:00
Hervé Poussineau 5dc56dd1d6 Revert "[VIDEOPRT] Fix updating of new registry path values"
This reverts commit ecf3416f49.

This commit was meant to fix CORE-17688. While its effectively fixed
the problem, it introduced another regression CORE-17719.

In the mean time, commit c05a45e17e fixed
things properly.

CORE-17719
2021-12-08 18:36:34 +01:00
Katayama Hirofumi MZ ee3659d5d5
[NTUSER][USER32] Simplify user32.IsHungAppWindow (#4150)
Check FNID_GHOST and MsqIsHung. CORE-17894
2021-12-09 00:39:57 +09:00
Katayama Hirofumi MZ 79c926c893
[NTUSER] Implement HSHELL_RUDEAPPACTIVATE notification (#4147)
- Add IntIsWindowFullscreen function to judge whether the window is fullscreen.
- Add IntCheckFullscreen function to notify HSHELL_RUDEAPPACTIVATE if fullscreen.
- Add IntCheckFullscreen call in UpdateShellHook function.
- Add IntCheckFullscreen call in co_WinPosSetWindowPos function.
CORE-16130
2021-12-08 18:26:22 +09:00
Katayama Hirofumi MZ 4a17d4b0c1 [NTGDI] Follow-up of #4137
Revert AddPenLinesBounds. Delete FIXME comments.
CORE-2527, CORE-8366
2021-12-07 08:08:46 +09:00
Katayama Hirofumi MZ 6358c4ac9f
[NTGDI] Support the wide pen (#4137)
- Extend PATH_WidenPath function as PATH_WidenPathEx with the path argument.
- Use PATH_WidenPathEx and PATH_FillPathEx functions to implement wide pen drawing in PATH_StrokePath function.
- Add the code to IntGdiLineTo, IntRectangle, IntGdiPolygon, and IntGdiPolyline in order to stroke the path when the effective wide pen.
FIXME: Boundary rectangle.
CORE-2527, CORE-8366
2021-12-06 20:44:06 +09:00
Katayama Hirofumi MZ f606fecb0d
[NTUSER] Fix where linking newly created window is done (#4127)
Co-authored-by: I_Kill_Bugs <>
CORE-12052
2021-12-04 11:52:38 +09:00
Hermès Bélusca-Maïto 957e566a23
[APITESTS][NTVDM][SPOOLSV] Add the missing ENABLE_EXPORTS property as these EXE targets have function exports.
This became a requirement, following a previous CMake update.
Otherwise the built EXEs would not export their intended functions.

Addendum to commit d8e92b5a (see PR #1335)
CORE-15406

[LOADCONFIG] The GCC rant had nothing to do with GCC, but everything with CMake...

[SPOOLSV] Add the missing exported stubs.
2021-12-04 01:17:32 +01:00
Oleg Dubinskiy c05a45e17e
[WIN32K:ENG] Pass correct display name to EngpFindGraphicsDevice (#4128)
It actually should look like '\\.\DISPLAY<n>' (since it comes from user mode),
which the function expects, and not '\\Device\\Video<n>', like done in the
kernel mode. Otherwise, passing wrong name causes a mismatch.

Fix the problem with video device access (failure with status 0xc0000022 when
trying to open it). Hence, it also fixes the following debug log spam:
'err: Could not open device \Device\Video0, 0xc0000022'.

Addendum to 77e891b8. CORE-17719 CORE-17786
2021-12-01 18:28:45 +03:00
James Tabor 9cff384c22 [User32] Add Back Break with Error Message
Add back missing break. See CORE-17856.
2021-11-27 11:35:42 -06:00
James Tabor a89844f740 [User32] Fix Copy Paste
Pointed out by otya. See CORE-17856.
2021-11-24 09:36:50 -06:00
Denis Malikov db810d8e44
[WIN32SS:NTUSER] Fix window state after restoring snapped window (#4119)
InternalPos.NormalRect is a key data for detecting whether a window was snapped.
Keeping it after restore affecting next snap actions.

CORE-16477
2021-11-23 23:34:03 +01:00
Doug Lyons b538b9abb8
[WIN32K] Fix 'use after free' in NtGdiStretchDIBitsInternal (#4122)
CORE-17861
2021-11-22 02:57:36 +01:00
Thomas Faber 0af3689c2e
[REACTOS] Fix traces with missing arguments.
Courtesy of VS Code Analysis warning C6064:
Missing integer argument to 'DbgPrint' that corresponds to conversion specifier 'N'.
2021-11-21 12:57:35 -05:00
Julio Carchi 9c4397afdf
[USER32] GetQueueStatus() should not return 0 when passing QS_ALLINPUT flag that includes QS_RAWINPUT (#4115)
GTK applications call GetQueueStatus(QS_ALLINPUT), where QS_ALLINPUT
specifies the QS_RAWINPUT flag as well, when these are compiled for
Windows XP+, and they expect the call to succeed on this platform.

On one side, ReactOS does not currently support this flag at all, but
since it claims to be XP/2003-compatible, applications may implicitly
expect the flag to be supported by GetQueueStatus() and the function
*NOT* failing when this flag is set.
(Later GTK apps don't care and just call GetQueueStatus(QS_ALLINPUT)
that includes QS_RAWINPUT, and therefore would fail as well on e.g.
Windows 2000...)

Otherwise, an observable effect is that some versions of libgdk-win32-2.0.0.dll
enter into an infinite loop when calling GetQueueStatus(QS_ALLINPUT),
since this call always failed on ReactOS.

On the other side, however, we should honour our winetests that handle
the presence of the QS_RAWINPUT flag and behave differently accordingly.
But since we do not support QS_RAWINPUT yet, we should keep their old
behaviour where QS_RAWINPUT is unused.

Thus, in order to accomodate both sides, we don't fail the GetQueueStatus()
call, but just set the ERROR_INVALID_FLAGS last error and continue it.


This fixes CORE-15686, CORE-17551 and probably CORE-11850.
Fixes also all user32:TrackMouseEvent tests.

Co-authored-by: Hermès BÉLUSCA - MAÏTO <hermes.belusca-maito@reactos.org>
2021-11-20 00:45:35 +01:00
Hermès Bélusca-Maïto 7c8c9e1aba
[WINSPOOL] QS_SENDMESSAGE|QS_ALLEVENTS == QS_ALLINPUT, so use the latter instead. 2021-11-19 21:13:26 +01:00
Joachim Henze f028ca5b08 [WIN32K] Fix a weird control character in dibobj.c CreateDIBPalette() CORE-17848 2021-11-15 03:05:20 +01:00
Katayama Hirofumi MZ 3d78601f39
[WIN32SS][NTUSER] Implement NtUserDestroyInputContext (#4063)
CORE-11700
2021-11-01 15:20:42 +09:00
Thomas Faber 3a323c3de0
[WIN32K] Fix uninitialized bResult in IntExtTextOutW.
Powered by clang-cl.
2021-10-29 22:06:49 -04:00
Thomas Faber 4bc95812fd
[WIN32K] Mark default as unreachable.
Powered by clang-cl.
2021-10-29 22:06:49 -04:00
Thomas Faber 3235e35dee
[WIN32K] Remove unnecessary if in NtUserGetGUIThreadInfo.
This condition is already checked above.
Powered by clang-cl.
2021-10-29 22:06:49 -04:00
Thomas Faber 42657493ef
[WIN32K] Fix uninitialized hNewMenu use in MENU_DoNextMenu.
See also: Wine's implementation.
Powered by clang-cl.
2021-10-29 22:06:46 -04:00
Hervé Poussineau cd48bc7af8 [LIVECD] Add more registry entries for vbemp/vgamp
CORE-17579
2021-10-25 21:44:45 +02:00
Katayama Hirofumi MZ 6417b2323d
[NTUSER][USER32] Workaround tracking menu on CORE-17338 (#4048)
This prevents the tracking menu from erroneously closing itself right after it was opened in some cases.
Fixes CORE-17338 which got unhidden by 0.4.15-dev-1126-g 58b0558f94
And fixes CORE-15760 which got unhidden by SVN r74972 == git 19dd22d422

Since both symptoms look very similar but the unhiding revisions did differ,
that could mean we do have some kind of race condition here.
I guess this fix is more like a workaround. I do intend to port it back nevertheless.
2021-10-23 22:29:39 +02:00
Hermès Bélusca-Maïto 5891ab2bfd
[WIN32SS:NTUSER] Make sure to hold User Global Lock before manipulating desktops. (#4053) 2021-10-22 21:44:56 +02:00
Hermès Bélusca-Maïto 6b7b0f0c7e
[WIN32SS:NTUSER] Few formatting fixes. 2021-10-22 21:44:52 +02:00
Katayama Hirofumi MZ a37d9a4e14
[IMM32] Rewrite ImmInstallIMEW (#4044)
- Add Imm32StrToUInt and Imm32UIntToStr helper functions.
- Add Imm32LoadImeVerInfo, Imm32GetRegImes, Imm32WriteRegIme, Imm32GetNextHKL, Imm32CopyFile helper functions.
- Add REG_IME structure for registered IMEs.
- Rewrite ImmInstallIMEW function.
- Improve ImmLoadLayout and Imm32LoadImeInfo functions.
CORE-11700
2021-10-21 10:28:04 +09:00
James Tabor 83f86b8fdb [User32] Fix incorrect check.
Use Lo Word instead of Intersource check.
Fix wine user32 tests.
2021-10-19 15:29:51 -05:00
James Tabor e98684ed8b [GDI32] Fix rectangle flag issues.
Fix CORE-17815. Remove dumb dumb code breakers.
2021-10-16 11:16:43 -05:00
Hervé Poussineau ea8cbbd4ca [VIDEOPRT] Correctly return failure in IRP_MJ_CREATE when HwInitialize fails
CORE-17789
2021-10-14 23:39:31 +02:00
Hervé Poussineau 807af6a4d1 [VIDEOPRT] Correctly return failure when adapter can't be found
This was wrong in both call chains (PNP case or legacy case)
HwFindAdapter returns a VP_STATUS, while we were expecting a NTSTATUS.

CORE-17789
2021-10-14 23:39:31 +02:00
Hervé Poussineau 87b74f2901 [VIDEOPRT] Correctly report legacy resources in IRP_MN_FILTER_RESOURCE_REQUIREMENTS
It was broken since first commit 25eae4b916 (r54237)

CORE-17789
2021-10-14 23:39:31 +02:00
Hervé Poussineau 951dc66c66 [VGAMP] Correctly check and report legacy resources (VGA I/O ports and memory)
As we are a non PNP driver, the call chain will be
DriverEntry -> VidePortInitialize -> VideoPortFindAdapter -> HwFindAdapter.

If legacy resources are available, we will fail VGAFindAdapter,
so DriverEntry will fail, so vgamp.sys driver won't be used.

CORE-17789
2021-10-14 23:39:30 +02:00
Hervé Poussineau 6dd94572e5 [VBEMP] Correctly report legacy resources (VGA I/O ports and memory)
CORE-17789
2021-10-14 23:39:30 +02:00
Hervé Poussineau 3379de3924 [VBEMP] Fail HwInitialize (ie IRP_MJ_CREATE) when /NOVESA switch is present
In that case, we want a simple VGA driver to drive the graphic adapter.

CORE-17789
2021-10-14 23:39:30 +02:00
James Tabor 63e7d6c29e [Win32K] Fix typo
Fix a GERRRR typo.
2021-10-14 09:59:53 -05:00
Chan Chilung 463784c5f1
[TRANSLATION] Chinese Traditional (zh-TW) translation update (#3954)
Also sync LOCALMON/UI translation with Wine.
2021-10-10 15:00:44 +03:00
Katayama Hirofumi MZ 66ef31494e
[IMM32] Implement ImmActivateLayout (#3987)
- Add IME_STATE and IME_SUBSTATE structures.
- Modify INPUTCONTEXTDX structure.
- Implement ImmActivateLayout function.
- Improve ImmDestroyContext function by using newly-defined Imm32FreeImeStates.
- Add Imm32FetchImeState, Imm32FetchImeSubState, Imm32LoadImeStateSentence, Imm32SaveImeStateSentence, and Imm32SelectLayout helper functions.
- Modify NtUserSetThreadLayoutHandles prototype.
CORE-11700
2021-10-04 07:33:15 +09:00
Katayama Hirofumi MZ 33affbfecb
[IMM32] Rewrite ImmGetImeMenuItemsA/W (#3983)
- Rewrite ImmGetImeMenuItemsA and ImmGetImeMenuItemsW functions.
- Add Imm32GetImeMenuItemsAW, Imm32IsImcAnsi, Imm32ImeMenuAnsiToWide and Imm32ImeMenuWideToAnsi helper functions.
- Make IME module's ImeGetImeMenuItems function optional.
CORE-11700
2021-10-01 03:04:00 +09:00
Katayama Hirofumi MZ 9adc538c9c
[IMM32] Rewrite ImmSetActiveContext (#3982)
- Re-implement ImmSetActiveContext function.
- Modify NtUserNotifyIMEStatus prototype.
- Improve ImmSetConversionStatus and ImmSetOpenStatus functions.
CORE-11700
2021-10-01 03:02:56 +09:00
Hervé Poussineau 92d0dd3633 [VIDEOPRT] Create and setup new registry key only for non-legacy drivers
CORE-17734
2021-09-29 22:56:35 +02:00
James Tabor b5fae844de [NtGDI] Fix brush attribute transfer. 2021-09-28 19:08:45 -05:00
James Tabor 72f115d6ed [NtGDI] Set owner after changing object type. 2021-09-27 23:49:35 -05:00
James Tabor d9f8b8b033 [NtGDI] Fix leaking of bitmaps while testing INFO DC's.
Soon to be commit test for metafiles.

ret = MaskBlt(hdc, 0, 0, 3, 4, dib_hdc, 0, 0, mask_bitmap, 0, 0, SRCCOPY);
2021-09-27 23:11:33 -05:00
James Tabor 8767aada75 [GDI32] Fix IV msvc build. 2021-09-27 19:08:43 -05:00
James Tabor be4540821a [GDI32] Fix III msvc build. 2021-09-27 18:19:49 -05:00
Hermès Bélusca-Maïto e6306db0c3
[GDI32] Fix build errors~~ 2021-09-28 00:48:24 +02:00
James Tabor d4b2c97b67 [GDI32] Fix msvc build errors. 2021-09-27 17:30:40 -05:00
James Tabor fc16259faf [GDI32] Update Wine Metafile Code
Sync/Port: Metafile code from wine.

Patches by Jacek Caban, Daniel Lehman, Zhiyi Zhang. Gabriel Ivancescu, Michael Stefaniuc, Francois Gouget, Nikolay Sivov Dmitry Timoshkov, Andrew EiKum, Piotr Caban and Alexandre Julliard.

This commit is dedicated to George Bisoc!
2021-09-27 16:18:20 -05:00
Katayama Hirofumi MZ b3382d8d24
[IMM32] Rewrite ImmLockIMC (#3975)
- Add Imm32InitContext and Imm32LockIMCEx helper functions.
- Re-implement ImmLockIMC function.
- Modify CLIENTIMC and INPUTCONTEXTDX structures.
CORE-11700
2021-09-27 09:32:24 +09:00
Hermès Bélusca-Maïto 31c4c2efe9
[USER32] GetUserObjectSecurity/SetUserObjectSecurity: Just use UserSetLastNTError() in failure path. 2021-09-26 19:04:08 +02:00
James Tabor 970344bd16 [Win32SS|GDI] Implement seldom used API and update types for local DC's.
Two working in house application require these API. Known as FolCOL and Reach.
2021-09-25 11:57:26 -05:00
Arjav Garg a602bc3550
[NTUSER] Fix UserSendKeyboardInput() KEYEVENTF_SCANCODE use case (CORE-17144) 2021-09-25 09:56:12 -04:00
Katayama Hirofumi MZ ca3fa7197d
[IMM32] Use Imm32IsImmMode and Imm32IsCiceroMode macros (#3971)
- Define Imm32IsImmMode, Imm32IsCiceroMode and Imm32Is16BitMode macros in "precomp.h".
- Improve Imm32InquireIme and Imm32CleanupContext functions.
- Add IME_SYSINFO_WINLOGON and IME_SYSINFO_WOW16 macros (from DDK) in psdk/imm.h.
- Modify CtfImeInquireExW and CtfImeSelectEx prototype.
CORE-11700
2021-09-24 22:06:29 +09:00
Joachim Henze 222acf5a3e [NTUSER] Scrollbar.c, Avoid potential out-of-bounds-accesses in co_IntSetScrollInfo() CORE-17777
This is an addendum to
0.4.15-dev-3174-g dda9c3979e CORE-17769 and
0.4.15-dev-3147-g 3bf7e3ac13 CORE-17754 CORE-17755

We have not seen this happening in real-life yet, but some code-fragments within co_IntSetScrollInfo()
e.g. line 628 if (nBar == SB_CTL) do clearly indicate that nBar can be 2 (SB_CTL).
Some lines below we definitely must not access those 4 static arrays out of bounds then via nBar as access index!

Ftr with a bit of grepping I also found some calls like NtUserSetScrollInfo(Wnd, SB_CTL, &Info, FALSE);
e.g: in win32ss/user/user32/controls/scrollbar.c so I am pretty sure nBar == 2 can happen in practice within co_IntSetScrollInfo().

I question whether any of those reads/writes to those static arrays (or the comparisons) would make any sense on index 2,
so we should aim to eliminate them altogether in the future.
2021-09-20 03:05:05 +02:00
Joachim Henze dda9c3979e [NTUSER] Scrollbar.c, improve co_IntSetScrollInfo() CORE-17769
Fixes CORE-17769 'Rapps Listview manual resize may erroneously not draw the triangles sometimes'
This could happen for both: themed and unthemed.

CORE-17769 was a regression introduced by 0.4.14-dev-1134-g 00adb1a3f9

We don't really like the added state in form of the static variables,
but the patch works good from a pure testing-perspective.

Many Thanks to the patches author: Doug Lyons
2021-09-19 22:35:37 +02:00
Hermès Bélusca-Maïto 271556e6f8
[WIN32SS] Disable by default the dumping function. Addendum to 69f90508. 2021-09-19 00:46:56 +02:00
Hermès Bélusca-Maïto 69f905081c
[WIN32SS:NTUSER] Move the keyboard layout debugging code to a separate dump function.
And fix its obvious bugs, e.g. not checking for possible NULL pointers
for the optional keyboard layout sub-tables...
2021-09-19 00:18:04 +02:00
Katayama Hirofumi MZ df6fff78bb
[IMM32] Rewrite ImmAssociateContextEx (#3961)
- Rewrite ImmAssociateContextEx function.
- Modify NtUserAssociateInputContext prototype.
CORE-11700
2021-09-16 19:29:49 +09:00
Katayama Hirofumi MZ afb6c8a129
[IMM32] Rewrite ImmEscapeA/W (#3959)
- Rewrite ImmEscapeA and ImmEscapeW functions.
- Delete useless legacy code.
CORE-11700
2021-09-16 19:27:43 +09:00
Victor Perevertkin d74eb54b06
[WIN32SS:GDI] Add a sanity assert 2021-09-14 17:58:23 +03:00
Hermès Bélusca-Maïto 9393fc320e
[FORMATTING] Remove trailing whitespace. Addendum to 34593d93.
Excluded: 3rd-party code (incl. wine) and most of the win32ss.
2021-09-13 03:52:22 +02:00
Doug Lyons 3bf7e3ac13
[NTUSER] Improve Themed Scrollbars by Minimizing Updates (#3953)
This fixes regressions CORE-17754 and CORE-17755 which regressed by
0.4.15-dev-3086-g 236649c626
2021-09-12 22:54:46 +02:00
Süleyman Poyraz 53221834c5
[TRANSLATION] Add and improve Turkish (tr-TR) translation (#3561)
Reviewed-by: Can Taşan <ctasan99@hotmail.com>
Reviewed-by: Ercan Ersoy <ercanersoy@ercanersoy.net>
Signed-off-by: Süleyman Poyraz <zaryob.dev@gmail.com>
2021-09-12 00:34:11 +03:00
Hermès Bélusca-Maïto 4cbc61fd02
[WIN32SS:NTUSER][USER32] NtUserProcessConnect() should return pointers in user client-space. (#3937)
- Do the kernel/server --> user/client-space pointers conversion within
  NtUserProcessConnect(), instead of having the callers of this function
  doing this job.
  This makes the behaviour Windows-compatible.

  NOTE: the gHandleEntries pointer is ReactOS-specific!

- Drop the g_ulSharedDelta global, just use instead gSharedInfo.ulSharedDelta.

- Add extra documentation aspects for NtUserProcessConnect() that are
  not yet implemented in ReactOS.
2021-09-09 16:15:12 +02:00
Hermès Bélusca-Maïto a407cb8f10
[WIN32SS:NTUSER] Update the definition of SHAREDINFO and fix the definition of FNID_LAST. (#3937) 2021-09-09 16:15:11 +02:00
James Tabor a022dc8eaf [GDI32] Fix Meta file packing recursion issues.
TextOut was looping back adding additional EMR packet to the meta file.
2021-09-06 18:37:24 -05:00
James Tabor 03516733ef [GDI32] Do not fail on path with bitmap fonts.
Patch by Dmitry Timoshkov : ExtTextOut on a path with bitmap font
selected shouldn't fail.
This just leads to empty path generated.
2021-09-06 17:53:35 -05:00
Doug Lyons 236649c626
[UXTHEME][NTUSER] Fix flashing of scrollbar when scrolling (#3868)
Based on a patch by I_Kill_Bugs.
2021-09-03 22:34:26 +03:00
Katayama Hirofumi MZ 4689c8ead8 [USER32][INCLUDE] Move GetImmFileName declaration from user32.h to user32p.h
From: win32ss/user/user32/include/user32.h
To: win32ss/user/user32/include/user32p.h

CORE-11700
2021-08-31 13:42:54 +09:00
Katayama Hirofumi MZ a8d2cd4b9d
[IMM32] Rewrite ImmGetContext (#3923)
- Add ValidateHwndNoErr and Imm32GetContextEx helper functions.
- Rewrite ImmGetContext function by using the helper functions.
CORE-11700
2021-08-24 06:50:39 +09:00
Katayama Hirofumi MZ 2ab858c125
[USER32][IMM32] Improve User32InitializeImmEntryTable (#3918)
- Improve User32InitializeImmEntryTable function and related.
- Complete win32ss/user/user32/include/immtable.h table.
- Delete a hack in user32.DllMain and apply my magical tricks. This will fix some access violations in IMM32.
- Add some stubs into IMM32.
CORE-11700
2021-08-23 16:25:21 +09:00
Katayama Hirofumi MZ 10c9aa067f
[NTUSER] Improve NtUserQueryWindow (#3915)
- Improve NtUserQueryWindow function.
- Add IMC structure.
- Modify THREADINFO structure.
CORE-11700
2021-08-21 07:31:10 +09:00
Katayama Hirofumi MZ 1d0587fc27
[IMM32] Rewrite ImmProcessKey (#3917)
- Rewrite ImmProcessKey function.
- Modify win32ss/include/imetable.h.
- Modify ImmProcessKey prototype.
CORE-1170
2021-08-21 07:22:43 +09:00
Katayama Hirofumi MZ c59c185d1c
[INCLUDE] Move WM_IME_SYSTEM from ntuser.h to undocuser.h (#3920)
CORE-11700
2021-08-19 08:18:20 +09:00
Katayama Hirofumi MZ 1f792413f0 [NTUSER][INCLUDE] s/TransMsg[1]/TransMsg[ANYSIZE_ARRAY]/
CORE-11700
2021-08-18 19:59:35 +09:00
Katayama Hirofumi MZ d83be2e6b6 [NTUSER][INCLUDE] Trivial formatting of TRANSMSG and TRANSMSGLIST
CORE-11700
2021-08-18 19:56:47 +09:00
Katayama Hirofumi MZ f4bc74edc3
[IMM32] ImmGenerateMessage and ImmTranslateMessage (#3914)
- Rewrite `ImmGenerateMessage` and `ImmTranslateMessage` functions.
- Rename `INPUTCONTEXTDX.bHasVKey` as `bNeedsTrans`.
- Move `TRANSMSG` structure into `ntuser.h`.
- Add `TRANSMSGLIST` structure into `ntuser.h`.
- Add `UNDETERMINESTRUCT` structure to `ddk/imm.h`.
- Modify `NtUserGetAppImeLevel` prototype.
CORE-11700
2021-08-18 08:42:12 +09:00
Katayama Hirofumi MZ 77911014f3
[IMM32] Rewrite ImmIsUIMessageA/W (#3907)
- Rewrite ImmIsUIMessageA and ImmIsUIMessageW functions.
- Modify HIMC and HIMCC handle types for strictness. Add typecasts.
- Add WM_IME_SYSTEM macro.
- Modify imm32.spec.
CORE-11700
2021-08-16 15:33:51 +09:00
Katayama Hirofumi MZ cc097ec485
[IMM32] Rewrite ImmEnumRegisterWordA/W (#3906)
- Rewrite ImmEnumRegisterWordA and ImmEnumRegisterWordW functions.
- Modify win32ss/include/imetable.h.
CORE-11700
2021-08-16 15:31:39 +09:00
Katayama Hirofumi MZ 19d24143e9
[IMM32] Rewrite ImmGetRegisterWordStyleA/W (#3901)
- Rewrite ImmGetRegisterWordStyleA and ImmGetRegisterWordStyleW functions.
- Modify win32ss/include/imetable.h.
CORE-11700
2021-08-14 10:39:20 +09:00
Katayama Hirofumi MZ 1e62771c78
[IMM32] Rewrite ImmRegisterWordA (#3881)
- Rewrite ImmRegisterWordA function.
- Modify imetable.h.
CORE-11700
2021-08-10 08:08:23 +09:00
Doug Lyons ad8d8b6628
[GDI32] Revise IntTMWFixUp Raster Font List (#3808)
CORE-17662
CORE-17723
2021-08-09 13:07:04 +02:00
Jérôme Gardou c4801ab696 [WIN32K] Do not release twice the lock on error path 2021-08-06 15:18:21 +02:00
Jérôme Gardou 0bc00267df [WIN32K] Init User part after GDI one.
But Initialize user lock first thing to avoid hitting newly introduced ASSERTS

This partly reverts commit 515d83a883.
2021-08-06 10:15:02 +02:00
Katayama Hirofumi MZ 692a30a84a
[IMM32] ImmCreateContext, ImmDestroyContext, DllMain etc. (#3867)
- Rewrite ImmCreateContext, ImmDestroyContext, and DllMain functions.
- Add g_hImm32Inst, g_bClientRegd, and g_SharedInfo global variables. Delete g_dwImm32Flags (that was g_psi->dwSRVIFlags).
- Implement ImmLoadIME and ImmRegisterClient functions.
- Modify CLIENTIMC and IMEDPI structures. Move CLIENTIMC definition into ntuser.h.
- Add file win32ss/include/imetable.h.
- Rename SRVINFO_METRICS macro as SRVINFO_CICERO_ENABLED.
CORE-11700
2021-08-04 09:41:59 +09:00
Jérôme Gardou bd6fb80867 [WIN32K:NTUSER] In debug builds, enable free & tail checking when creating heaps
Actually catches bugs
2021-08-03 23:13:19 +02:00
Jérôme Gardou b783b16cef [WIN32K:USER] Fix potential use after free when painting child windows 2021-08-03 23:13:19 +02:00
Jérôme Gardou d958dc9bc2 [WIN32K:NTUSER] Assert global user lock is held exclusively when using global & desktop heaps
They're explicitly not serialized because we count on this.
2021-08-03 23:13:19 +02:00
Jérôme Gardou 8c098ee8d2 [WIN32K:NTUSER] Make sure to hold User Global Lock before unmapping desktop heap 2021-08-03 23:13:19 +02:00
Jérôme Gardou 6ec0420dc6 [WIN32K:NTUSER] Allocate & free timers under global user lock 2021-08-03 23:13:19 +02:00
Jérôme Gardou 515d83a883 [WIN32K] On init, start by initializing NtUser stuff
Allocate gpsi (Global Server Info) after initializing & grabbing Userlock
2021-08-03 23:13:19 +02:00
Katayama Hirofumi MZ d7f13aa696
[IMM32] Improve ImmSimulateHotKey (#3858)
- Improve ImmSimulateHotKey function.
- Modify IMEDPI structure.
CORE-11700
2021-07-31 15:56:11 +09:00
Katayama Hirofumi MZ 89cb8a38b3
[IMM32] Rewrite ImmEnumInputContext (#3859)
- Rewrite ImmEnumInputContext function.
- Modify NtUserBuildHimcList.
CORE-11700
2021-07-31 15:45:07 +09:00
Timo Kreuzer ecf3416f49 [VIDEOPRT] Fix updating of new registry path values
CORE-17688
When a new driver is installed for the same device (like VBoxVideo), it uses the same hardware enum registry key and thus reuses the same DisplayId and the same display registry key. Therefore we need to update the setting in that key, even when the key already exists.

This seems to work good and not cause any issues, but testing indicated that on Windows some values are only updated, when the driver has changed. If neccessary, this can be achieved by updating and querying the ActiveService value in the device enum key (e.g. HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\PCI\VEN_80EE&DEV_BEEF&SUSYS_00000000&REV_00\3&267a616a&0&10\Control: ActiveService). If that doesn't match the current device name (from DriverExtension->RegistryPath) the values should be copied over.
2021-07-27 14:44:14 +02:00
Timo Kreuzer 204626f793 [WIN32K] Fix uninitialized variable 2021-07-27 14:44:14 +02:00
Katayama Hirofumi MZ ecb0c0963d
[IMM32] Imm(Lock|Unlock)ImeDpi and ImmSetOpenStatus (#3830)
- Add IMEDPI structure to ntuser.h.
- Implement ImmLockImeDpi/ImmUnlockImeDpi functions.
- Rewrite ImmSetOpenStatus function.
- Modify some NTUSER function prototypes.
- Modify imm32.spec.
CORE-11700
2021-07-25 11:57:57 +09:00
Katayama Hirofumi MZ 97847f2078
[IMM32] Improve ImmGetImeInfoEx (#3833)
- Rewrite ImmGetImeInfoEx function.
- Implement CtfImmIsTextFrameServiceDisabled function.
- Modify imm32.spec.
CORE-11700
2021-07-25 11:56:17 +09:00
Timo Kreuzer 5d8e834897 [REACTOS] Fix a number of MSVC warnings 2021-07-23 22:03:48 +02:00
Timo Kreuzer 77e891b8ab [WIN32K] Check if a graphics device already exists before trying to add it
This avoids DPRINTs alleging a failure to open a device.
Also improve another DPRINT.
2021-07-15 08:32:46 +02:00
Timo Kreuzer 39d8a822d2 [WIN32K] Fix detection of multiple display devices on VBox 2021-07-15 08:32:46 +02:00
Katayama Hirofumi MZ 92393a7517
[IMM32] Add some candidate handlings (#3799)
- Implement ImmGetCandidateListA and ImmGetCandidateListW, by using newly added ImmGetCandidateListAW function.
- Implement ImmLockClientImc and ImmUnlockClientImc functions.
- Modify imm32.spec.
- Remove #ifdef's.
CORE-11700
2021-07-11 09:48:15 +09:00
Hervé Poussineau 8379c87b0b [VIDEOPRT] Write correct MaxObjectNumber to registry
VideoPortMaxObjectNumber variable will be updated later in the function, if everything went fine.
2021-07-10 19:03:37 +02:00
Hervé Poussineau 0f6b9664cd [WIN32K] HACK: create a DC on all display devices and display wallpaper 2021-07-10 16:27:44 +02:00
Timo Kreuzer 49c16e661a [VIDEOPRT] Do not attach secondary devices to the device stack
This fixes display on the primary screen.
2021-07-10 16:27:44 +02:00
Hervé Poussineau e9b5b22a8c [VIDEOPRT] Implement VideoPortCreateSecondaryDisplay 2021-07-10 16:27:44 +02:00
Timo Kreuzer 545352c655 [VIDEOPRT] Fix adapter id 2021-07-10 16:27:44 +02:00
Timo Kreuzer af314557c0 [VIDEOPRT] Use new registry path 2021-07-10 16:27:44 +02:00
Timo Kreuzer 066337dc84 [VIDEOPRT] Refactor device map key creation 2021-07-10 16:27:44 +02:00
Hervé Poussineau 6739fb1bc3 [WIN32K] Move detection of available display devices a new fonction EngpUpdateGraphicsDeviceList
- rewrite InitVideo() to call this new function
- also call it at the start of UserEnumDisplayDevices, to detect new potential devices
2021-07-10 16:27:44 +02:00
Hervé Poussineau b5966977ac [VBEMP] Remove too verbose log, when debug is enabled in videoprt 2021-07-10 16:27:44 +02:00
Katayama Hirofumi MZ 211de1257e
[IMM32] Rewrite ImmIsIME (Retry) (#3803)
- Rewrite ImmIsIME function.
- Fix enum IMEINFOEXCLASS.
CORE-11700
2021-07-08 14:23:25 +09:00
Serge Gautherie 64a72787f2
[VIDEOPRT] Fix 'Irp->IoStatus.Information' copypasta (#3777)
Addendum to 25eae4b (r54237).
CORE-17651
2021-07-06 12:32:23 +03:00
Hervé Poussineau 93f986463a [VBEMP][VGAMP] Correctly fill VdmPhysicalVideoMemoryAddress/VdmPhysicalVideoMemoryLength
These variables must be filled by miniport if miniport is VGA-compatible.
2021-07-05 23:46:16 +02:00
Hervé Poussineau 8d24de7805 [BOOTDATA][VBEMP] Merge duplicated registry settings to vbemp_reg.inf 2021-07-05 23:44:35 +02:00
Hervé Poussineau 9b5d029c7a [FRAMEBUF] Early return if we got 0 available mode from video driver
This prevents allocating 0 bytes of memory a few lines later.
2021-07-05 23:44:35 +02:00
Doug Lyons 847b037fe9
[WIN32K] Revert NtGdiStretchDIBitsInternal to Previous Logic (#3774)
Fixes gdi32:dib / gdi32:bitmap tests and SIMS graphics.
JIRA issue: CORE-16236
2021-07-03 00:34:43 +02:00
Jérôme Gardou 813d9cd2cc [WIN32K:NTUSER] Do not pass NULL keyboard layout to IntToUnicodeEx
There's an ASSERT on that
2021-06-29 11:49:20 +02:00
Joachim Henze 4130f0b1c5 [WIN32K] CreateDIBPalette addendum to #3758 CORE-17626
Fix compilation on older GCC4.7.2 toolchain
to not warn about universal zero initializer.
See
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=53119
https://stackoverflow.com/questions/13746033/how-to-repair-warning-missing-braces-around-initializer
2021-06-23 21:37:53 +02:00
Joachim Henze c596fd3ef6 [WIN32K] CreateDIBPalette SEH Simplification #3758 CORE-17626
Enter an SEH2_TRY one time and do all testing within it instead of entering the SEH_TRY multiple times.

The commit is an addendum to 0.4.15-dev-2734-g 514147776a

Thanks to patches author Doug-Lyons

This is 1:1 the final approved content of #3758, but I committed
by hand and closed the PR to avoid squash+rebase.
2021-06-23 19:59:42 +02:00
Doug Lyons c7954134d0
[WIN32K] Revert incorrect part of R50928 for RealizePalette. (#3678)
Revert incorrect code for Realize Palette
Revert part of SVN R50928 that causes Durak card suites to have wrong colors.
SVN r50928 == git 5de8339cd1

JIRA issue: CORE-13748 <= Durak Example
JIRA issue: CORE-16510 <= GDIProg Example

The patch also fixes 2 crashes on each bot, although
it was not targeted for that explicitly:
KVM: https://reactos.org/testman/compare.php?ids=77304,77308 LGTM
VBox: https://reactos.org/testman/compare.php?ids=77305,77309 LGTM
2021-06-19 18:25:03 +02:00
Joachim Henze 514147776a [NTGDI] Fix potential BSOD 0x1E CORE-17626
in CreateDIBPalette() when passing invalid arguments to CreateDIBSection.
This could be triggered by using the broken test-application "GDIProg".

After this patch not only the BSOD is fixed but also the app does
properly start up, like it is the case on 2k3sp2.

Thanks to the patches author Doug Lyons.
2021-06-19 17:41:49 +02:00
Adam Słaboń 9764fde2d9 [WIN32K] Add x64/arm exports
Checked against Windows XP x64 and Windows 8 ARM.
2021-06-12 14:11:14 +02:00
Jérôme Gardou e70df4c633 [WIN32K:ENG] In EngLockDriverObj, properly return NULL when locking failed
CORE-15958
2021-06-09 18:27:12 +02:00
Eric Kohl 4db8b82aeb [VIDEOPRT] Fix monitor ID decoding issues 2021-06-06 21:27:00 +02:00
Hervé Poussineau 08e9000496 [VBE] Check if DDC is supported before trying to read EDID
Also set Edx to 0 when reading Edid, as per specification.

CORE-16695
2021-06-05 23:38:05 +02:00
Hervé Poussineau fa54704158 [VIDEOPRT] Report monitor name instead of the generic 'Monitor' string 2021-06-05 23:38:05 +02:00
Hervé Poussineau 2ae6bd7453 [VIDEOPRT] Give to each device its own entry in HKLM\SYSTEM\CurrentControlSet\Services
This is required if you have two graphic cards using the same driver.
2021-06-05 23:38:05 +02:00
Katayama Hirofumi MZ 59d4c11203
[WIN32SS][NTUSER] ShowWindow.SW_MINIMIZE should show window (#3700)
- user32!ShowWindow.SW_MINIMIZE should show the window.
- Fix the return value of ShowWindow function on invalid parameter.
CORE-15669
2021-06-01 11:11:23 +09:00
Katayama Hirofumi MZ 32b0cf6fc6
[WIN32SS][NTUSER] Improve HSHELL_WINDOWCREATED condition (#3697)
Modify the condition of generating HSHELL_WINDOWCREATED, especially on WS_CHILD window style. CORE-15669
2021-05-31 13:08:06 +09:00
Timo Kreuzer d07203ecb7 [WIN32K][USER32] Change mechanism for storing dialog info pointer
DLGWINDOWEXTRA is 30 (both on win32 and win64). This has storage for the following entries: DWLP_MSGRESULT (0), DWLP_DLGPROC (8), DWLP_USER (16)
We used to store the dialog info pointer using SetWindowLongPtr (DWLP_ROS_DIALOGINFO == DWLP_USER+sizeof(ULONG_PTR) == 24), which was fine on win32, but failed on win64, since there wasn't enough space left (24 + 8 = 32 > 30).
Rewrite the way the DLGINFO pointer is stored, by adding an additional field to the WND structure and set it using NtUserxSetDialogPointer (which is what it is for).
Also fix too small cbWndExtra for the button class.
2021-05-28 08:26:36 +02:00
Timo Kreuzer 50c9dab6c9 [WIN32K] Fix wrong calculation in DIB_32BPP_BitBltSrcCopy
Using an unsigned integer will cause the calculations to be unsigned, which on x64 leads to wrong results, when adding it to a pointer.
2021-05-27 15:53:24 +02:00
Mark Jansen 1c97b84600
[WIN32SS] Skip . and .. when enumerating fonts 2021-05-22 16:31:31 +02:00
Stanislav Motylkov ffa7cfc1ff
[INF] Remove remnants of XboxVmp driver which has its own INF file 2021-05-18 20:22:22 +03:00
Dmitry Borisov f7d825e620 [PC98VID] Fix MSVC 2015 build for PC-98 target
Addendum to 3adf450867

Also isolate the constant structures into page section
and restore the previous sections for start IO and entrypoint routines.
2021-05-18 19:30:29 +03:00
Stanislav Motylkov 0bd8a2110b
[WIN32SS] Always build all video miniport drivers
But include registry changes and INF files depending on SARCH variable.
This commit is expected to uncover pc98vid build error on MSVC 2015.

Addendum to 8c475e4. CORE-17529
2021-05-18 19:24:57 +03:00
Stanislav Motylkov 81987761d9
[PC98VID] Use unique target name but rename as vga.sys
This allows building pc98vid driver without conflict with vga_new.
2021-05-18 19:24:35 +03:00
Serge Gautherie 255807f768 [LOCALSPL] InitializePrinterDrivers(): Fix LocalGetPrinterDriverDirectory) call
Fix Clang-Cl
'...\printerdrivers.c(97,98): warning: variable 'cbBuf' is uninitialized when used here [-Wuninitialized]'

Addendum to 62c4b82.
CORE-14306
2021-05-18 10:49:20 +02:00
Jérôme Gardou 3adf450867 [REACTOS] Addendum to 5c7ce4475e - Fix MSVC 2015 build
Put data into PAGEDATA or INITDATA sections
Keep section declaration for prototypes

CORE-17540
2021-05-12 11:04:29 +02:00
Hermès Bélusca-Maïto f9aca9f7d2
[CONSRV] wcwidth.c: Fix out-of-range comparisons Clang warnings for wchar_t's, that are only 2 bytes long on NT. (#3619)
CORE-17545

win32ss/user/winsrv/consrv/frontends/wcwidth.c:203:30: warning: result of comparison of constant 262141 with expression of type 'wchar_t' (aka 'unsigned short') is always true [-Wtautological-constant-out-of-range-compare]
      (ucs >= 0x30000 && ucs <= 0x3fffd)));
                         ~~~ ^  ~~~~~~~
win32ss/user/winsrv/consrv/frontends/wcwidth.c:203:12: warning: result of comparison of constant 196608 with expression of type 'wchar_t' (aka 'unsigned short') is always false [-Wtautological-constant-out-of-range-compare]
      (ucs >= 0x30000 && ucs <= 0x3fffd)));
       ~~~ ^  ~~~~~~~
win32ss/user/winsrv/consrv/frontends/wcwidth.c:202:30: warning: result of comparison of constant 196605 with expression of type 'wchar_t' (aka 'unsigned short') is always true [-Wtautological-constant-out-of-range-compare]
      (ucs >= 0x20000 && ucs <= 0x2fffd) ||
                         ~~~ ^  ~~~~~~~
win32ss/user/winsrv/consrv/frontends/wcwidth.c:202:12: warning: result of comparison of constant 131072 with expression of type 'wchar_t' (aka 'unsigned short') is always false [-Wtautological-constant-out-of-range-compare]
      (ucs >= 0x20000 && ucs <= 0x2fffd) ||
       ~~~ ^  ~~~~~~~
2021-05-05 17:24:13 +02:00
Hermès Bélusca-Maïto 9a93d2fe3a
[CONSRV] Fix uninitialized variables warnings detected by Clang. (#3619)
CORE-17545

Fix 3 warnings:

win32ss/user/winsrv/consrv/alias.c:648:16: warning: variable 'Status' is used uninitialized whenever 'while' loop exits because its condition is false [-Wsometimes-uninitialized]
        while (CurEntry)
               ^~~~~~~~
win32ss/user/winsrv/consrv/alias.c:693:12: note: uninitialized use occurs here
    return Status;
           ^~~~~~

win32ss/user/winsrv/consrv/alias.c:715:9: warning: variable 'Status' is used uninitialized whenever 'if' condition is false [-Wsometimes-uninitialized]
    if (Header)
        ^~~~~~
win32ss/user/winsrv/consrv/alias.c:727:12: note: uninitialized use occurs here
    return Status;
           ^~~~~~

win32ss/user/winsrv/consrv/alias.c:771:16: warning: variable 'Status' is used uninitialized whenever 'while' loop exits because its condition is false [-Wsometimes-uninitialized]
        while (RootHeader)
               ^~~~~~~~~~
win32ss/user/winsrv/consrv/alias.c:807:12: note: uninitialized use occurs here
    return Status;
2021-05-05 17:24:12 +02:00
Oleg Dubinskiy 58daf942fe
[GDI32] Fix wrong ordering of parameters in NtGdiDdGetDC call (#3637)
It allows to properly pass the surface handle (and palette entry pointer) from MS ddraw into win32k.
Otherwise, they are passing into the wrong parameters of actual NtGdi* function, and due to this,
since they're detected as invalid, they become NULL, and that function does not work correctly.

See https://docs.microsoft.com/en-us/windows/win32/devnotes/-dxgkernel-ntgdiddgetdc for the reference
(and confirmed by our headers).

Required by MS DirectDraw stack (ddraw.dll & dxg.sys).
CORE-17561
2021-05-03 18:11:18 +02:00
Jérôme Gardou e470b58376 [REACTOS] Explicitly link against pseh & include pseh headers in a few places 2021-04-28 13:10:23 +02:00
George Bișoc ffea5152e6
[WIN32SS][NTUSER] Fix an integer underflow within scrollbar info setting
Thanks goes to I_Kill_Bugs for the patch (and partly to Kyle Katarn for the PR) and Hermes for tweaking the patch code. Had to make a commit myself as the PR author's account is deleted.

Signed-off by: I_Kill_Bugs (original patch author)
Signed-off by: Kyle Katarn <contact@kcsoftwares.com>
Signed-off by: Hermès BÉLUSCA - MAÏTO <hermes.belusca-maito@reactos.org>
2021-04-25 15:56:39 +02:00
Tibor Lajos Füzi ea04edce2d [TRANSLATION] Add/update Hungarian translation for solitaire, spider solitaire, rapps, usetup, cpl/timedate, shell32, user32 2021-04-14 16:16:24 +02:00
Eric Kohl 8c475e4709 [CMAKE] Build xboxvmp in Xbox-builds only
This prevents the creation of a fake Xbox GPU device on non-Xbox builds.

CORE-17529
2021-04-10 20:15:36 +02:00
Jérôme Gardou 12dfa8ce39 [WIN32K] Fix getting long value from float object
Most importantly, do not shift 32-bit integers by 32 or more.
2021-03-31 18:35:31 +02:00
Jérôme Gardou 405ce53211 [WIN32K] More cleanup & improvements
Use FLOATOBJs to perform device<->world transformations, avoiding use of XFORMOBJ all the time
Remove unused macros & functions
2021-03-31 18:35:31 +02:00
Jérôme Gardou 3bad3c49e1 [WIN32K] Use INTERNAL_LPTODP in IntLPtoDP
Instead of initializing a XFORMOBJ and whatnot
2021-03-31 18:35:31 +02:00
Jérôme Gardou 26b5596a11 [WIN32K] Rewrite PATH_Ellipse & PATH_RoundRect using integer arithmetics 2021-03-31 18:35:31 +02:00
Jérôme Gardou f9c068685f [WIN32K] Reduce use of FPU in path implementation with use of FLOATOBJs 2021-03-31 18:35:31 +02:00
Jérôme Gardou 40f7e86347 [WIN32K] Fix brain-fail of mine
Copying e.g. (2;2);(6;6) to (0;0);(4;4) also needs to have an intermediate buffer.
2021-03-31 16:55:30 +02:00
Jérôme Gardou 30886e74f2 [WIN32K] Fix case when buffers overlap in 1BPP -> 1BPP DIB copy
Logic by Doug Lyons
CORE-17520
2021-03-31 16:39:57 +02:00
Jérôme Gardou 068687e0fd [WIN32K] Fix off-by-one errors
Spotted by Doug Lyons
CORE-17520
2021-03-31 16:39:57 +02:00
Jérôme Gardou 0c13ff2a4b [WIN32K] Rewrite DIB1BPP -> DIB1BPP copy
Simpler is sometimes better.
Fixes some crashes & memory corruptions happening because of all those broken loops.
2021-03-22 22:40:33 +01:00
Chan Chilung 6a31fe6ca7
[TRANSLATION][INF] Update Chinese Traditional (zh-TW) translation (#3468)
- Add / improve Chinese Traditional Translations for INFs.

- Name changing (removed Aobi in my name)

Add Chinese Traditional translation for:
- cmdutils/at
- cmdutils/comp
- hotplug.cpl
- rosapps' sysutils/ctm

Chinese Traditional (zh-TW) translation update for:
- cmdutils/find
- cmdutils/help
- cmdutils/label
- cmdutils/whoami
- mspaint
- shutdown
- taskmgr
- diskpart
- format
- appwiz.cpl
- input.cpl
- powercfg.cpl
- shimgvw
- user32
2021-03-09 16:51:37 +01:00
George Bișoc b00ecdcab9
Replace my E-mail with the ReactOS org one (#3475)
From now on for ReactOS related contributions only the organization e-mail shall be used and also reverse the order of my real full name.
2021-02-22 18:26:55 +03:00
Doug Lyons ce7836c6d3
[WIN32K] Add StretchBlt function ability to flip images (#3458)
Modify dib\dibxxbpp.c programs to understand flipped images. See Videos at CORE-16642

1. Mirroring Horizontally works.
2. Mirroring Vertically works.
3. Rotation 180° works.

CORE-16642, CORE-14408, CORE-16634
2021-02-21 08:28:36 +09:00
Serge Gautherie cb5d610a73
[CONSRV] SetConWndConsoleLeaderCID(): Check must be before dereferencing (#3451)
Addendum to f12e601.
2021-02-10 18:55:19 +01:00
Jérôme Gardou e46c2dd1b3 [VIDEOPRT] Mark low memory range as NOACCESS when we don't need to access it.
This allows to accomplish great things, such as crashing when dereferencing NULL pointer.
2021-02-10 17:48:30 +01:00
Jérôme Gardou f12e6016b6 [CONSRV] Set 0 as a console leader PID/TID when unsetting it.
Instead of whatever is behind the NULL pointer.
2021-02-10 17:48:30 +01:00
Victor Perevertkin 46ca069e42
[XDK] Remove UNREFERENCE_LOCAL_VARIABLE macro
Change UNREFERENCED_PARAMETER to (VOID)P to support const parameters
2021-01-19 00:15:02 +03:00
Joachim Henze 232c45fcd7 [WIN32SS][COMCTL32] Commit Flip_Fix_9.patch
flip_fix_9.patch fixes:
CORE-16984 " 'SPINA Thrulg' / 'SPINA Thyr' / 'Sim Thyr' have images flipped"
CORE-17194 "StretchDIBits test" isn't work correctly"
           "Output of 'Project 3 Test'"
CORE-14701 "DVDStyler 3.0.4 transparent toolbars"
CORE-14701 "DVDStyler 3.0.4 erroneously black around icons of welcome-dlg"
CORE-14671 "'Peazip' shows icons in buttons and menubar vertically flipped"
           "Double Commander shoes icons flipped in buttons, menubar, listview and the treeview"
CORE-13273 "Welcome to Lazarus" icon shows flipped
CORE-13026 "'CudaText app' icon shows flipped"

Not all of those are duplicates, although they appear to be at first glance.
It affects different controls and some of those tickets do have different 'guilty revs' than others.

The patch does consist of 3 parts:

1.) win32ss/gdi/ntgdi/dibobj.c
This one is the most clean part of it, that addresses most of the flipping issues now.

2.) The hack in comctl32.h redefining the version:
We used that in the past to appease some, but not all of the issues listed above.
But it does hide additional issues, e.g. in DvDStyler, therefore we seem to still need that appeasement even today.
Most likely it would make sense to aim to avoid this part in the future.
part 2.) was committed as first appeasement on its own already into
0.4.14-RC-24-g 198b61e
0.4.13-RC-7-g 67211fa
0.4.12-RC-5-g 8449527
0.4.11-RC-16-g b906163
0.4.10-RC-7-g f1e80fe
0.4.9-RC-34-g 9d758ae

3.) toolbar.c change
That part fixes at least the toolbar case for DvDStyler
without relying on the comctl32.h hack any longer,
but it was still not enough to completely get rid of part 2.) yet.

Many thanks to all contributors: 'I_kill_Bugs', Doug Lyons and also 'Julenuri' for testing.

The patch gave nice testbot results:
KVM:  https://reactos.org/testman/compare.php?ids=75704,75714
VBox: https://reactos.org/testman/compare.php?ids=75705,75715

and we also created a summary of manual test-results:
https://jira.reactos.org/browse/CORE-17415?focusedCommentId=126668&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-126668

If you read this comment via git blame and your goal is to get rid of the hack in comctl32.h, I would highly recommend
to redo the tests of that testing table, and if that is asked too much, then please test at least the following cases:
CORE-14701 "DVDStyler 3.0.4 transparent toolbars"
CORE-14701 "DVDStyler 3.0.4 erroneously black around icons of welcome-dlg"
           "DVDStyler 3.0.4 erroneously black/transparent within comboboxes of properties of VMGM menu"
and try to add what might be needed to fix them, and double-check again:
           "DoubleCommander optionsDlg the most complex testcase, contains flip-prone icons in treeview, listview, menubar, buttons, statics". Only some of its flipped icons were impacted by the comctl32.h change before.
2021-01-05 20:30:40 +01:00
Jérôme Gardou c8d07514c8 [CMAKE] Fix GCC -fstack-protector usage 2021-01-05 13:38:57 +01:00
Jérôme Gardou b96e88894a [CMAKE] Turn import libs into regular C static libs
Embed msvcrtex into libmsvcrt

Idea taken from Thomas Faber
2020-12-28 12:13:30 +01:00
Hermès Bélusca-Maïto 89f36bcfc8
[CONSRV] Less hardcoded magic values. 2020-12-27 00:52:01 +01:00
Dmitry Borisov bc90cbbb88
[WIN32K:NTUSER] Fix gradient caption bars with low color depth (#3338)
This fixes a problem when the window title bar is dithered down
to the 16- or 256-color palette. See also commit 0705f30.
2020-12-20 23:12:30 +03:00
Victor Perevertkin 971cf12c9a
[VBE] Enable the driver start in the registry 2020-12-19 21:00:06 +03:00
Joachim Henze 449a341786 [WIN32SS] Trim EOL white-space
Addendum to 0.4.15-dev-1457-g 870aa1254f
2020-12-19 17:51:37 +01:00
Joachim Henze 870aa1254f [WIN32SS] Fix BSOD 0x1E nullptr deref via Git-bash CORE-16586
Thanks to the patches author Doug Lyons!
2020-12-19 17:47:33 +01:00
Jérôme Gardou 484e959c29 [USER32] Properly save EBX in the wndproc wrapper 2020-12-09 10:00:35 +01:00
Timo Kreuzer 00cfa8aac2 [WIN32K] Fix an ASSERT to ignore the upper 32 bits of a passed in GDI handle 2020-11-07 18:34:10 +01:00
Hermès Bélusca-Maïto 3c722e35b1
[CMD][SERVMAN][SHELL32][WINSPOOL][ROSAPPS][NTOS:PNP] Fix my build. 2020-11-06 01:06:11 +01:00
Dmitry Borisov 4dc3125450
[PC98VID] Fix build for PC-98 target (#3352)
- Some prototypes are not needed anymore.

Addendum to 5c7ce4475e.
2020-11-05 00:26:37 +03:00
Victor Perevertkin 5c7ce4475e
[REACTOS] Cleanup INIT and some PAGE section allocations
- Change INIT_FUNCTION and INIT_SECTION to CODE_SEG("INIT") and DATA_SEG("INIT") respectively
- Remove INIT_FUNCTION from function prototypes
- Remove alloc_text pragma calls as they are not needed anymore
2020-11-02 21:45:31 +03:00
Timo Kreuzer cef57d3c44 [GDI32] Fix up GdiFixUpHandle 2020-10-31 14:24:09 +01:00