Commit graph

414 commits

Author SHA1 Message Date
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
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 0f6b9664cd [WIN32K] HACK: create a DC on all display devices and display wallpaper 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
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
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
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
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
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
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 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
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
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
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
Doug Lyons 8081ba9332
[WIN32SS] Repaint the whole window frame on some style bits set (#3199)
This fixes the ReactOS Calculator buttons disappearing in CORE-16827
2020-10-24 22:35:45 +03:00
Katayama Hirofumi MZ 58b0558f94
[NTUSER] Fix Shell Hook HSHELL_WINDOWCREATED (#3294)
Fix Shell Hook and reduce failures of shell32_apitest ShellHook testcase. Fix the condition of notifying shell hook HSHELL_WINDOWCREATED in ntuser/winpos.c. CORE-17330
2020-10-13 16:37:52 +09:00
Katayama Hirofumi MZ f341e60fbe [USER32] Mute 'Imm Api Table Init 2' spam
CORE-11700
2020-09-26 11:13:43 +09:00
Katayama Hirofumi MZ 33fe4333f4
[USER32] Load IMM table (#3215)
Implement the IMM function table in module user32.dll. CORE-11700
File immtable.h is located at win32ss/user/user32/include, that is a list of the DEFINE_IMM_ENTRY macro calls.
2020-09-23 21:42:54 +09:00
Serge Gautherie 889b077b23
[REACTOS] *.spec: Fix some function/parameter types (#3154) 2020-09-20 19:21:11 +02:00
Katayama Hirofumi MZ ab115e30fe
[IMM32][INCLUDE] Add immtable.h and modify imm32.spec (#3207)
- Add immtable.h header into win32ss/user/user32/misc/.
- Modify imm32.spec file.
CORE-11700
2020-09-19 22:47:40 +09:00
Serge Gautherie 345ad55319
[BROWSEUI][USER32] Explicitly use MAKEINTRESOURCEW() for consistency (#3192) 2020-09-15 14:56:51 +03:00
Serge Gautherie a04831677e
[PROGMAN][CRT][USER32] Do not use LoadLibraryEx() NT6+ flags (#3152)
CORE-12004
2020-09-13 23:42:09 +02:00
Kyle Katarn f07ace6aa2
[RAPPS][CONSRV] French translation update (#3160)
Co-authored-by: Hermès BÉLUSCA - MAÏTO <hermes.belusca-maito@reactos.org>
2020-09-13 23:12:52 +02:00
Katayama Hirofumi MZ 8396cf8696 [CONSRV] Improve Japanese (ja-JP) translation 2020-09-13 16:50:15 +09:00
chirsz cd2eaf1e51
[CONSRV] Improve zh-CN translation (#3157)
The new word is more in line with PRC people's usage habits, and it
is actually used in the Simplified Chinese translation of Windows.
2020-09-12 18:23:05 +02:00
Kyle Katarn 9f428f5522
[NTUSER] Demote ERR to TRACE, also some minor corrections (#3132) 2020-09-05 17:59:10 +03:00
Katayama Hirofumi MZ dce62240f1
[NTUSER] Improve SPI_SETWORKAREA setting (#3061)
CORE-12018, CORE-7237
2020-08-20 11:31:57 +09:00
Katayama Hirofumi MZ 81f28d454a
[NTUSER] Set ERROR_INVALID_WINDOW_HANDLE when PostMessage failed (#3059)
Set the last error code ERROR_INVALID_WINDOW_HANDLE when user32!PostMessage failed with destroyed window.
CORE-12124
2020-08-18 05:32:44 +09:00
Aobi Chan CL 860b45aca1
[USERINIT][WINLOGON][USER32][USERSRV] Update Traditional Chinese (Taiwan) translation (#3018) 2020-08-16 15:13:55 +03:00
Omer Itzic S a6946307fc
[USERSRV] Update Hebrew translation (#3010)
Co-authored-by: Baruch Rutman <peterooch@gmail.com>
2020-08-15 22:57:07 +03:00
Katayama Hirofumi MZ 4b038ec8b7
[IMM32][NTUSER] Add ImmGetImeInfoEx (#3035)
- Add the definition of imm32!ImmGetImeInfoEx function.
- Add IMEINFOEXCLASS and IS_IME_HKL into "ntuser.h".
- Modify NtUserGetImeInfoEx function prototype.
CORE-11700
2020-08-12 06:03:29 +09:00
Katayama Hirofumi MZ 047da7e632
[NTUSER] Add more QUERY_WINDOW_* values (#3034)
Add QUERY_WINDOW_* constant values for NtUserQueryWindow funciton. CORE-11700
2020-08-12 06:01:22 +09:00
Katayama Hirofumi MZ ec9d277d59
[IMM32][NTUSER] Implement ImmGetHotKey (#3025)
CORE-11700
- Implement imm32!ImmGetHotKey function.
- Modify NtUserGetImeHotKey function.
- Add LPHKL typedef into <imm.h> header.
2020-08-09 22:41:11 +09:00
Nguyen Trung Khanh ff50b0db2e
[NTUSER] Fix stack memory disclosure in NtUserBuildPropList (#3023)
Fix structure alignment cause to stack memory disclosure in NtUserBuildPropList.
2020-08-08 14:05:22 +09:00
Jose Carlos Jesus 62e52c7237
[USER32][NTUSER] Fix wrong return from LB_GETLISTBOXINFO (#2168)
And is now consistent with comctl32 and Wine too...
2020-07-04 15:11:10 +02:00
Nguyen Trung Khanh a279b1d2c6
[WIN32K:NTUSER] Zero allocated memory in IntCbAllocateMemory.
This avoids disclosing pool contents to user mode when not all members
of the respective structure are initialized or when there is padding.

In co_IntCallWindowProc, also zero the stack buffer since this can
be passed to user mode as well, and contains padding.
2020-06-24 09:15:27 +02:00
James Tabor f6d2b34ad0 [NtUser] Fix MSVC_x64 Build
Attempt to fix.
2020-06-18 11:55:13 -05:00
James Tabor 06e01c8968 [NtUser] Fix Crash in Win32k
Use strict thread and desktop verifying. See CORE-15092 and CORE-17133.
2020-06-18 11:06:31 -05:00