Commit graph

33 commits

Author SHA1 Message Date
Oleg Dubinskiy eb96d377d1
[SHELL32] Allow custom shortcut overlay icon (#6419)
Use correct icon index in SIC_OverlayShortcutImage() to properly load
shortcut overlay icon from registry instead of always using default icon.
This allows to use custom shortcut icon set by user, in case it was
specified there.

As FIXME comment stated, the icon indexes were not implemented in the far
past, so this workaround was badly required. But now they are implemented,
so no need to always use default resource from shell32, enable the correct
code instead.

Also adapt this to CShellLink::CreateShortcutIcon() when the shortcut icon
is being changed in its properties dialog, as well as in CNewMenu class
when displaying menu items for creating a new folder or a shortcut.

Addendum to f9a5344254. CORE-14758
2024-03-04 16:30:43 +03:00
Katayama Hirofumi MZ 1d1472c78e
[APPWIZ][SHELL32] Improve 'Create Shortcut' dialog (#6550)
Now we can open special folder shortcut, thanks to #6546.
Let's allow users to create various shortcut files.
JIRA issue: CORE-5866
- Remove BIF_RETURNONLYFSDIRS flag because
  the system can open special folder shortcuts now.
- Add LPITEMIDLIST pidlTarget to CREATE_LINK_CONTEXT
  structure.
- Use pidlTarget if the target is a special folder.
- Fix CShellLink::DoOpen for arguments.
2024-02-28 15:22:44 +09:00
Katayama Hirofumi MZ d634ef54e4
[SHELL32] Opening Special Folder shortcut (#6546)
Fix opening special folder.
JIRA issue: CORE-19464
In CShellLink::DoOpen, if there is a PIDL, then use it and set SEE_MASK_IDLIST flag.
2024-02-28 12:17:04 +09:00
Joachim Henze 6f91b6c0fe [SHELL32] Tweak formatting and logging
Some style-improvements I wanted to apply before a planned backport.
E.g. The biggest source-file CDefView.cpp in [SHELL32] can be shrinked considerably by stripping some outdated
comments from 10 and more years ago, when this class was still non-OOP and named ShellView.
Less excessive line-lengths also here and there.

In case it is not obvious when reviewing: In the beginning of CDevView.cpp in the declaration-part I just
reduced the indentation-level by 4 spaces for a big block.

Some shell classes were touched during 0.4.15-dev'ing for fixes like the 'unkown'-typo in
0.4.15-dev-6323-g 3854a5d8e9 for example
or missing \n were added to dbgprints like in
0.4.15-dev-4492-g 03422451b3
Touched again here, because I want to port those improvements back,
but don't intend to increase the size in older releases.

The commit looks big, but does consist solely of trivialities.
There is no functional change in this commit, aside the logging ofc.
2024-02-20 02:08:56 +01:00
Whindmar Saksit ded91e310a
[SHELL32] Enable Apply button when shortcut show mode is changed (#5807)
Basically this happens when the combobox selection changes.
2023-10-20 13:02:14 +02:00
Whindmar Saksit ed9d2a06b0
[SHELL32] Handle HotKey and ShowCmd on the shortcut property page (#5638)
Co-authored-by: Stanislav Motylkov <x86corez@gmail.com>
Co-authored-by: Hermès BÉLUSCA - MAÏTO <hermes.belusca-maito@reactos.org>
Co-authored-by: Katayama Hirofumi MZ <katayama.hirofumi.mz@gmail.com>
2023-09-02 21:16:22 +03:00
Hervé Poussineau f3506ee626 [SHELL32] Prevent use after free
'buffer' is local to the function, while m_sPath is an instance class member.
Fix that by calling the IShellLink::Resolve() function, which will allocate
and fill the m_sPath variable.

CORE-15229
2022-09-23 23:07:26 +02:00
Hervé Poussineau 51dd0523c7 [SHELL32] Fill link path before initializing the dialog
This fixes the Target type, Target location and Target fields
in shortcut properties window.

CORE-15229
2022-09-12 08:14:03 +02:00
Serge Gautherie 03422451b3 [REACTOS] Add '\n' to debug logs
on TRACE, WARN, FIXME and ERR calls.

Plus a few nit picks.
2022-05-04 03:28:38 +03:00
Timo Kreuzer 5d8e834897 [REACTOS] Fix a number of MSVC warnings 2021-07-23 22:03:48 +02:00
Hermès Bélusca-Maïto e7a5850d65
Revert "[SHELL32] Don't check for link files being targets for other link files. Addendum to 3a822e4f."
This reverts commit 3249a00364.
2021-06-28 04:11:00 +02:00
Hermès Bélusca-Maïto 3249a00364 [SHELL32] Don't check for link files being targets for other link files. Addendum to 3a822e4f. 2021-06-28 02:19:30 +02:00
Katayama Hirofumi MZ 3a822e4f74
[SHELL32] Implement PathResolveW function (#3762)
- Implement PathResolveW function.
- Implement PathQualifyA/W functions using newly-defined PathQualifyExW function.
CORE-12665
2021-06-28 07:53:26 +09:00
Katayama Hirofumi MZ ade5413362
[SHELL32] Auto-completion on Properties for Shortcut (#3574)
Enable auto-completion on "Properties for Shortcut files". CORE-9281
2021-04-02 17:04:43 +09:00
Katayama Hirofumi MZ 1c706d7483
[SHELL32] Watch for common desktop and SHCNE_CREATE for IShellLink::Save (#2515)
- On desktop view, we have to watch both the common desktop and the private desktop.
- In Windows, IShellLink::Save (shortcut creation) sends SHCNE_CREATE or SHCNE_UPDATEITEM notification.
- Simplify CChangeNotify::ShouldNotify.
CORE-10391
2020-04-09 16:56:54 +09:00
Thomas Faber aee6cbc50a
[SHELL] Add SHOpenFolderAndSelectItems to shlobj.h. 2020-01-18 13:10:35 +01:00
Katayama Hirofumi MZ 8f129932dd
[SHELL32] Simply return S_OK if *pdwEffect is none (#2039)
IDropTarget::DragEnter must simply return S_OK if *pdwEffect == DROPEFFECT_NONE. CORE-11238
2019-11-15 18:02:06 +09:00
Katayama Hirofumi MZ c0f340bca5
[SHELL32] Implement 'Open file location' of shortcut files (#2028)
"Open file location" is a feature to open the location of the target of a shortcut file.
Ideally we should probably use SHOpenFolderAndSelectItems here, but that is not 100% implemented in ros yet... CORE-12770
2019-11-12 16:47:36 +09:00
Thomas Faber be1f95527a
[SHELL] IPersistIDList/IShellLink use P(C)IDLIST_ABSOLUTE. CORE-16385 2019-09-29 12:09:39 +02:00
Thomas Faber b2992e7a5e
[SHELL] IShellExtInit::Initialize uses PCIDLIST_ABSOLUTE. CORE-16385 2019-09-29 12:09:02 +02:00
Bișoc George c00bafaad9 [SHELL32] Print out the error code (#973)
When SearchPathW, GetFullPathNameW and PathFileExistsW fail, output the error code.
2018-11-16 23:09:15 +01:00
Hermès Bélusca-Maïto 2cbac3d049
[SHELL32] Finally fix the icon location path (un)expansion for shell links, and explain why I originally used SHExpandEnvironmentStringsW().
CORE-14009 CORE-14982
2018-10-08 00:50:38 +02:00
Eric Kohl 1e20a3e5b5 [SHELL32] Fix a potential buffer overrun.
Patch by Kudratov Olimjon.

CORE-8545
2018-10-07 22:56:16 +02:00
Hermès Bélusca-Maïto ae9ec94240
[SHELL32] Code formatting only. 2018-09-30 21:48:31 +02:00
Mark Jansen 19e9a44118
[SHELL32] Check the result from PathUnExpandEnvStringsW 2018-08-27 11:58:29 +02:00
Mark Jansen 608cb60e44
[SHELL32] Remove some mostly dead code from CShellLink 2018-08-27 11:58:24 +02:00
Katayama Hirofumi MZ 6eb6aa2895 [SHELL32] Fix CShellLink::GetIconLocation (#810)
Fixes a regression from PR #784.
CORE-14961, CORE-14009
2018-08-26 15:37:15 +02:00
Katayama Hirofumi MZ 73798d2e71 [SHELL32] Enable to change shortcut icon (#784)
CORE-11407
2018-08-21 13:49:32 +02:00
Katayama Hirofumi MZ 96c0ef4209 [SHELL32] Improve CShellLink a little (#651)
Improve the display and UI in the shortcut dialog.
CORE-11407
2018-07-08 16:45:40 +02:00
Katayama Hirofumi MZ 222534a5a2 [SHELL32] Fix and improve the PickIconDlg function (#574)
CORE-10972
2018-05-31 15:33:07 +02:00
Timo Kreuzer 0182dcd71b [PSDK][REACTOS] Fix definitions and usage of DWLP_MSGRESULT, DWLP_DLGPROC, and DWLP_USER
- Make sure the DWLP_* values are correct on _WIN64
- Don't use the DWL_* constants, they are not portable. Enforce this by removing them entirely from winuser.h
- Make sure Get/SetWindowLong*Ptr* is used and pointers are not truncated to LONG
2018-03-04 16:27:07 +01:00
Amine Khaldi a3797dba7a [SHELL32] Deduplicate MAX_PROPERTY_SHEET_PAGE and AddPropSheetPageCallback(). #179 2017-12-25 13:22:23 +01:00
Colin Finck c2c66aff7d Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys. 2017-10-03 07:45:34 +00:00
Renamed from reactos/dll/win32/shell32/CShellLink.cpp (Browse further)