shell32.ShellMessageBoxW redirects to shlwapi.ShellMessageBoxWrapW.
However the latter one (shlwapi) is exported by ordinal only.
Trying to use in shell32.spec file the following syntax:
182 varargs ShellMessageBoxW() shlwapi.ShellMessageBoxWrapW
will therefore fail at runtime, because Windows/ReactOS will fail to
snap shlwapi.ShellMessageBoxWrapW.
Using instead an export by orginal:
182 varargs ShellMessageBoxW() shlwapi.#388
actually fails as well, but at link time, by both MSVC' LINK and GNU's
dlltool.
This generates a .def file containing the line:
ShellMessageBoxW=shlwapi.#388 @182
It is not clear why it fails, because according to:
https://docs.microsoft.com/en-us/cpp/build/reference/exports?view=vs-2019
and
https://devblogs.microsoft.com/oldnewthing/20121116-00/?p=6073
this should be possible.
However one encounters the same errors as those described at:
https://groups.google.com/forum/#!topic/microsoft.public.vc.language/AVnx-EnYdsY
and
https://www.xspdf.com/questions/22333.shtml
...
So instead we use another trick, that appears to be already in use in
the shell32.spec. Since the shlwapi functions are imported because we
link to it, this means that ShellMessageBoxWrapW() is already available
through this import. So we can specify it in the .spec file as is,
without a full name prefixed with "shlwapi." .
Therefore the associated shell32.ShellMessageBoxW function will instead
link to the small ShellMessageBoxWrapW() import stub that is generated
automatically.
This makes ShellMessageBoxW use the correct implementation where the
text buffer size is dynamic, instead of having a too small hardcoded
size.
Fixes CORE-17271.
See also PR #3172 by Kyle Katarn, supplemented with some ideas from
Mark Jansen.
However we cannot straightforwardly implement ShellMessageBoxA around
ShellMessageBoxW, by converting some parameters from ANSI to UNICODE,
because there may be some variadic ANSI strings, associated with '%s'
printf-like formatters inside the format string, that would also need
to be converted; however there is no way for us to find these and perform
the conversion ourselves.
Therefore, we re-implement ShellMessageBoxA by doing a copy-paste ANSI
adaptation of the shlwapi.ShellMessageBoxWrapW function.
Note that, on Vista+ onwards, shlwapi implements both ShellMessageBoxA/W,
and shell32 directly forwards these exports to shlwapi, thus avoiding
these workarounds.
[PSDK] Explicily use WINAPIV for the variadic ShellMessageBoxA/W functions.
[INCLUDE/REACTOS] Add ShellMessageBoxWrapW in shlwapi_undoc.h .
The sorting in explorer broke by
SVN r73128 == git
24fcf531e7
Thanks to Doug Lyons for providing this patch.
I do intend to port it back into 0.4.14RC.
Those 2 did spam heavily when browsing folders with
many .zip files within. Mark Jansen confirmed that
this is good-path-logging and was just forgotten
to be disabled earlier.
- The user can enter the full path of a directory in "Copy To Folder" and "Move To Folder" features.
- Fix two bugs in SHBrowseForFolder function. One is disability of text box to enter a full path. Another one is disability to choose the root item in BFFM_SETSELECTION.
- Add ES_AUTOHSCROLL style to text box. This enables the user to enter a long text.
CORE-11132
- Add context menu item "Mo&ve to folder..." and implement the action.
- Implement the "Mo&ve to folder..." menu item of "Edit" menu of Explorer.
CORE-11132
- Add context menu item "Copy to &folder..." and implement the action.
- Implement the "Copy to &folder..." menu item of "Edit" menu of Explorer.
CORE-11132
Improve human readability of filesystem change notification.
- Rename the identifiers for human readabilities.
- Split the code into CFilePathList and CDirectoryWatcher classes.
- Encapsulation of code.
CORE-13950